[No QA] Reduce unsafe type assertions in navigation tests#95646
Merged
blimpich merged 1 commit intoJul 8, 2026
Conversation
blimpich
approved these changes
Jul 8, 2026
40 tasks
88 tasks
Contributor
|
🚀 Deployed to staging by https://github.com/blimpich in version: 9.4.32-0 🚀
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Explanation of Change
Reduced
@typescript-eslint/no-unsafe-type-assertionviolations intests/unit/getOnboardingRouteFromScreenTest.ts,tests/navigation/isDynamicRouteScreenTests.ts, andtests/unit/Navigation/getCreateReportRouteTest.tsas part of the cleanup forExpensify/App issue #94739.
What changed:
normalizedConfigsremoval/restoration to test missing-config behavior.jest.mocked(...).are removed from the seatbelt TSV.
Expensify/App post-merge OSBotify automation tightens the baseline on
main.Why this approach is safe:
normalizedConfigsinfinally.Reviewer focus:
unsafe casts behind another helper.
target-rule rows for the edited files.
Safety checks:
SEATBELT_INCREASE.eslint-disablefor@typescript-eslint/no-unsafe-type-assertion.as unknown assubstitutions.@ts-expect-errorcomments.Fixed Issues
$ #94739
PROPOSAL:
Count change
Current baseline source:
config/eslint/eslint.seatbelt.tsvBefore:
tests/unit/getOnboardingRouteFromScreenTest.ts: 1 violationtests/navigation/isDynamicRouteScreenTests.ts: 1 violationtests/unit/Navigation/getCreateReportRouteTest.ts: 4 violationsAfter:
tests/unit/getOnboardingRouteFromScreenTest.ts: 0 violationstests/navigation/isDynamicRouteScreenTests.ts: 0 violationstests/unit/Navigation/getCreateReportRouteTest.ts: 0 violationsNet reduction:
@typescript-eslint/no-unsafe-type-assertionviolations.TSV evidence:
from
config/eslint/eslint.seatbelt.tsv.CI=true npm run lint -- --no-cache --show-warnings tests/unit/getOnboardingRouteFromScreenTest.ts tests/navigation/isDynamicRouteScreenTests.ts tests/unit/Navigation/getCreateReportRouteTest.tsconfig/eslint/eslint.seatbelt.tsvdiff is intentionally notincluded in this PR because Expensify/App post-merge OSBotify automation
tightens the baseline on
main.Tests
Run:
Verify lint passes and the generated target-rule rows for the edited files are
removed from
config/eslint/eslint.seatbelt.tsv, then restore it beforecommitting:
Run:
npm test -- --runTestsByPath tests/unit/getOnboardingRouteFromScreenTest.ts tests/navigation/isDynamicRouteScreenTests.ts tests/unit/Navigation/getCreateReportRouteTest.tsVerify the targeted test suites pass.
Run:
Verify TypeScript checks pass.
Offline tests
Not applicable. This is test-only cleanup and does not change network behavior.
QA Steps
No QA required. This PR only changes tests. The ESLint seatbelt baseline is tightened by Expensify/App post-merge OSBotify automation.
PR Author Checklist
For checklist items that are not applicable to this test-only cleanup, checked
means the item was considered and determined not applicable.
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)Avatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Not applicable. This is test-only cleanup.
Android: mWeb Chrome
Not applicable. This is test-only cleanup.
iOS: Native
Not applicable. This is test-only cleanup.
iOS: mWeb Safari
Not applicable. This is test-only cleanup.
MacOS: Chrome / Safari
Not applicable. This is test-only cleanup.
cc @blimpich