Skip to content

chore: replace MockK resource stubs with FakeResourceHelper#973

Merged
bmc08gt merged 2 commits into
code/cashfrom
chore/fake-resource-helper
Jun 24, 2026
Merged

chore: replace MockK resource stubs with FakeResourceHelper#973
bmc08gt merged 2 commits into
code/cashfrom
chore/fake-resource-helper

Conversation

@bmc08gt

@bmc08gt bmc08gt commented Jun 24, 2026

Copy link
Copy Markdown
Collaborator

Add FakeResourceHelper as a testFixtures class that auto-discovers R classes from the test classloader and resolves resource IDs to their field names via reflection. This eliminates all per-string MockK stubs across 8 test files while keeping assertions locale-independent.

Also removes getKinSuffix()/getOfKinSuffix() from ResourceHelper interface, inlining the getString calls in Currency.kt.

Add FakeResourceHelper as a testFixtures class that auto-discovers R
classes from the test classloader and resolves resource IDs to their
field names via reflection. This eliminates all per-string MockK stubs
across 8 test files while keeping assertions locale-independent.

Also removes getKinSuffix()/getOfKinSuffix() from ResourceHelper
interface, inlining the getString calls in Currency.kt.

Signed-off-by: Brandon McAnsh <git@bmcreations.dev>
@bmc08gt bmc08gt self-assigned this Jun 24, 2026
@github-actions github-actions Bot added type: chore Maintenance, config, CI/CD area: payments Payments, transfers, intents, billing area: ui Compose UI, theme, components, resources area: tokens Token accounts, balances, token info area: session area: onboarding labels Jun 24, 2026
- UsdcDepositSweepTest: add missing dispatchers param, use TestDispatchers
- ChatCoordinatorEagerBalanceTest: replace advanceUntilIdle with bounded
  advanceTimeBy to avoid infinite heartbeat loop causing OOM
@bmc08gt bmc08gt merged commit 1f8bc73 into code/cash Jun 24, 2026
3 checks passed
@bmc08gt bmc08gt deleted the chore/fake-resource-helper branch June 24, 2026 15:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: onboarding area: payments Payments, transfers, intents, billing area: session area: tokens Token accounts, balances, token info area: ui Compose UI, theme, components, resources type: chore Maintenance, config, CI/CD

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant