1
0
forked from mirror/misskey
🌎 A completely free and open interplanetary microblogging platform 🚀
Go to file
Kisaragi 31e82fc29a
test(backend): kill many any in backend test (partial) (#14054)
* kill any on utils:api

* kill any on timeline test

* use optional chain to kill TS2532 on timeline test
変更前: 該当ノートが見つからなければundefinedに対するプロパティアクセスとしてテストがクラッシュ
変更後: 該当ノートが見つからなければoptional chainがundefinedとして評価されるが、strictEqualの右辺がnon-nullableなためアサーションに失敗しテストがクラッシュ

* kill `as any` for ApMfmService

* kill argument any for api-visibility

* kill argument any across a few tests

* do not return value that has yielded from `await`-ing `Promise<void>`

* force cast

* runtime non-null assertion to coerce

* rewrite `assert.notEqual(expr, null)` to `assert.ok(expr)`
こうすることでassertion type扱いになり、non-nullableになる

* change return type of `failedApiCall` to `void`
戻り値がどこにも使われていない

* split bindings for exports.ts
型が合わなくて文句を言ってくるので適切に分割

* runtime non-null assertion

* runtime non-null assertion

* 何故かうまく行かないので、とりあえずXORしてみる

* Revert "何故かうまく行かないので、とりあえずXORしてみる"

This reverts commit 48cf32c930.

* castAsErrorで安全ではないキャストを隠蔽

* 型アサーションの追加

* 型アサーションの追加

* 型アサーションの追加

* voidで値を返さない

* castAsError

* assert.ok => kill nullability

* もはや明示的な型の指定は必要ない

* castAsError

* castAsError

* 型アサーションの追加

* nullableを一旦抑止

* 変数を分離して型エラーを排除

* 不要なプロパティを削除する処理を隠蔽してanyを排除

* Repository type

* simple type

* assert.ok => kill nullability

* revert `as any` drop
reverts fe95c05b3f partialy

* test: fix invalid assertion
partially revert b99b7b5392

* test: 52d8a54fc7 により型が合うようになった部分の`as any`を除去

* format

* test: apply https://github.com/misskey-dev/misskey/pull/14054#discussion_r1672369526 (part 1)

* test: use non-null assertion to suppress too many error

* Update packages/backend/test/utils.ts

Co-authored-by: anatawa12 <anatawa12@icloud.com>

---------

Co-authored-by: anatawa12 <anatawa12@icloud.com>
2024-07-14 09:33:16 +09:00
.config feat: sentry integration (#13897) 2024-05-28 17:06:33 +09:00
.devcontainer chore(docker-compose): 推奨の名前にする (#14096) 2024-06-28 11:16:12 +09:00
.github リリースPRがないときにrelease-edit-with-push.ymlがfailして見栄えが悪いのを修正 (#14160) 2024-07-11 16:39:06 +09:00
.okteto
.vscode fix(dev): vscode-jest: Deprecated: Please use jest.runMode instead. 2024-03-14 17:42:30 +09:00
assets cleanup: trim trailing whitespace (#11136) 2023-07-08 07:08:16 +09:00
chart feat: sentry integration (#13897) 2024-05-28 17:06:33 +09:00
cypress test: do not use indexedDB in cypress environment due to chrome bug (#13709) 2024-04-14 08:08:26 +09:00
fluent-emojis@cae981eb4c feat: introduce fluent emoji 2022-12-26 16:04:56 +09:00
locales Feat: ユーザーのアイコン/バナーの変更可否をロールで設定可能に (#14078) 2024-07-14 09:31:05 +09:00
misskey-assets@0179793ec8 enhance(client): Sync widgets (#8512) 2022-12-27 14:55:11 +09:00
packages test(backend): kill many any in backend test (partial) (#14054) 2024-07-14 09:33:16 +09:00
scripts update deps (#14057) 2024-07-02 11:38:34 +09:00
.dockerignore chore(docker-compose): 推奨の名前にする (#14096) 2024-06-28 11:16:12 +09:00
.dockleignore fix: aptのキャッシュを削除しないようにする (#9803) 2023-02-05 14:15:59 +09:00
.editorconfig cleanup: trim trailing whitespace (#11136) 2023-07-08 07:08:16 +09:00
.gitattributes 改行コードをLFに統一 (#9926) 2023-02-14 13:13:34 +09:00
.gitignore chore(docker-compose): 推奨の名前にする (#14096) 2024-06-28 11:16:12 +09:00
.gitmodules feat: introduce fluent emoji 2022-12-26 16:04:56 +09:00
.node-version update deps (#13624) 2024-05-04 20:56:14 +09:00
.npmrc fix: .npmrcによりpackage.json記載のnodeバージョンに満たない場合はビルドに失敗するようにする (#12755) 2023-12-23 15:32:31 +09:00
.vsls.json
CHANGELOG.md Feat: ユーザーのアイコン/バナーの変更可否をロールで設定可能に (#14078) 2024-07-14 09:31:05 +09:00
CODE_OF_CONDUCT.md docs: Update Code of Conduct to version 2.1 (#12150) 2023-11-13 16:52:54 +09:00
codecov.yml Update codecov.yml 2023-02-26 14:17:29 +09:00
compose_example.yml chore(docker-compose): 推奨の名前にする (#14096) 2024-06-28 11:16:12 +09:00
compose.local-db.yml chore(docker-compose): 推奨の名前にする (#14096) 2024-06-28 11:16:12 +09:00
CONTRIBUTING.md Fix compose file name (#14153) 2024-07-09 12:42:02 +09:00
COPYING 2024 2024-01-01 00:30:56 +09:00
crowdin.yml
cypress.config.ts update cypress 2022-06-11 15:53:45 +09:00
Dockerfile build: install pnpm with corepack on docker build (#13926) 2024-06-22 19:45:08 +09:00
healthcheck.sh feat(backend): add /healthz endpoint (#13834) 2024-05-23 15:19:52 +09:00
LICENSE
package.json update deps (#14057) 2024-07-02 11:38:34 +09:00
pnpm-lock.yaml deps(frontend): AiScript VSCodeのバージョンを上げる (#14199) 2024-07-14 08:00:27 +09:00
pnpm-workspace.yaml refactor: extract bubble-game engine as independent package 2024-01-20 09:53:26 +09:00
Procfile
README.md Update README.md for Sentry 2024-05-31 20:42:02 +09:00
ROADMAP.md Update ROADMAP.md 2024-01-04 08:44:38 +09:00
SECURITY.md Update SECURITY.md 2023-12-25 16:50:41 +09:00

Misskey logo

🌎 Misskey is an open source, federated social media platform that's free forever! 🚀

Learn more


find an instance create an instance become a contributor join the community become a patron

Thanks

Sentry

Thanks to Sentry for providing the error tracking platform that helps us catch unexpected errors.

Chromatic

Thanks to Chromatic for providing the visual testing platform that helps us review UI changes and catch visual regressions.

Codecov

Thanks to Codecov for providing the code coverage platform that helps us improve our test coverage.

Crowdin

Thanks to Crowdin for providing the localization platform that helps us translate Misskey into many languages.

Docker

Thanks to Docker for providing the container platform that helps us run Misskey in production.