chore: revert account utils test changes perps#29503
Conversation
|
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
🔍 Smart E2E Test Selection
click to see 🤖 AI reasoning detailsE2E Test Selection:
No production code is modified. No E2E flows, UI components, controllers, or shared infrastructure are affected. This change only affects Jest unit tests, not Detox E2E tests. There is no performance impact whatsoever. No E2E tags or performance test tags are warranted. Performance Test Selection: |
|



Description
Changelog
CHANGELOG entry:
Related issues
Fixes:
Manual testing steps
Screenshots/Recordings
Before
After
Pre-merge author checklist
Performance checks (if applicable)
trace()for usage andaddTokenfor an exampleFor performance guidelines and tooling, see the Performance Guide.
Pre-merge reviewer checklist
Note
Low Risk
Low risk because this PR only changes test assertions and does not modify runtime perps/account logic.
Overview
Aligns
addSpotBalanceToAccountStatetest coverage so that when spot collateral is effectively zero (no USDC, USDH-only, or empty balances),totalBalance/availableBalanceare preserved andavailableToTradeBalanceis expected to default toavailableBalance.Renames the zero-spot test to explicitly assert numeric fields are preserved and
availableToTradeBalanceis set consistently.Reviewed by Cursor Bugbot for commit 70dfcde. Bugbot is set up for automated code reviews on this repo. Configure here.