Skip to content

Commit 08c4a21

Browse files
committed
test(perps): restore PerpsLimitPriceBottomSheet styles mock to decouple from design tokens and prevent undefined colors in tests
1 parent cae9700 commit 08c4a21

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

app/components/UI/Perps/components/PerpsLimitPriceBottomSheet/PerpsLimitPriceBottomSheet.test.tsx

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,25 @@ jest.mock('../../../../../../locales/i18n', () => ({
9393
strings: jest.fn((key) => key),
9494
}));
9595

96+
// Mock styles to avoid relying on design tokens structure
97+
jest.mock('./PerpsLimitPriceBottomSheet.styles', () => ({
98+
__esModule: true,
99+
createStyles: () => ({
100+
container: {},
101+
inputLabel: {},
102+
errorText: {},
103+
limitPriceDisplay: {},
104+
limitPriceValue: {},
105+
limitPriceCurrency: {},
106+
marketPriceText: {},
107+
percentageButtonsRow: {},
108+
percentageButton: {},
109+
percentageButtonActive: {},
110+
keypadContainer: {},
111+
footerContainer: {},
112+
}),
113+
}));
114+
96115
// Mock BigNumber
97116
jest.mock('bignumber.js', () => ({
98117
BigNumber: jest.fn().mockImplementation((value) => ({

0 commit comments

Comments
 (0)