You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## **Description**
Split from MetaMask#26651 to reduce CODEOWNERS fanout.
Batch: shared
Standardizes unit tests to avoid hardcoded hex colors by switching theme
mocks and style assertions to the shared `mockTheme` from
`app/util/theme`.
Also updates a small number of test mocks to match current hook
signatures (e.g. `useNetworkEnablement` now returns `popularEvmNetworks`
/ `popularMultichainNetworks` / `popularNetworks`, and `useAnalytics`
requires `identify`).
Related color-no-hex PRs (same initiative):
- MetaMask#26958
- MetaMask#26963
- MetaMask#27008
- MetaMask#27030
- MetaMask#27031
- MetaMask#27149
- MetaMask#27150
- MetaMask#27151
## **Changelog**
CHANGELOG entry: null
## **Related issues**
Fixes:
## **Manual testing steps**
```gherkin
Feature: color-no-hex test updates
Scenario: TypeScript and unit tests are healthy
Given the branch is checked out
When I run yarn lint:tsc
Then it passes
```
## **Screenshots/Recordings**
### **Before**
N/A
### **After**
N/A
## **Pre-merge author checklist**
- [x] I've followed MetaMask Contributor Docs and MetaMask Mobile Coding
Standards.
- [x] I've completed the PR template to the best of my ability
- [x] I've included tests if applicable (updated mocks + ran yarn
lint:tsc)
- [ ] I've documented my code using JSDoc format if applicable
- [ ] I've applied the right labels on the PR (see labeling guidelines).
Not required for external contributors.
<!-- CURSOR_SUMMARY -->
---
> [!NOTE]
> **Low Risk**
> Low risk because changes are confined to unit tests/mocks; main risk
is brittle test failures if the shared `mockTheme` shape or mocked hook
contracts diverge from production interfaces.
>
> **Overview**
> Refactors a batch of unit tests to stop hardcoding hex colors by
switching theme mocks and style assertions to the shared `mockTheme`
from `app/util/theme`.
>
> Updates several test-only mocks to match current hook contracts
(notably `useNetworkEnablement` now returning
`popularEvmNetworks`/`popularMultichainNetworks`/`popularNetworks`,
`useAnalytics` including additional required methods, and `useTailwind`
mock shape changes), plus a small Perps test adjustment to mock
`usePerpsLivePrices`.
>
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
32fe395. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->
0 commit comments