Files
pwap/mobile/src/screens/__tests__/StakingScreen.test.tsx
T
pezkuwichain 8d30519efc Fix all shadow deprecation warnings across entire mobile app
- Replaced shadowColor/shadowOffset/shadowOpacity/shadowRadius with boxShadow
- Fixed 28 files (21 screens + 7 components)
- Preserved elevation for Android compatibility
- All React Native Web deprecation warnings resolved

Files fixed:
- All screen components
- All reusable components
- Navigation components
- Modal components
2026-01-14 15:05:10 +03:00

31 lines
893 B
TypeScript

import React from 'react';
import { render } from '@testing-library/react-native';
import { LanguageProvider } from '../../contexts/LanguageContext';
import { PezkuwiProvider } from '../contexts/PezkuwiContext';
import StakingScreen from '../StakingScreen';
jest.mock('@react-navigation/native', () => ({
...jest.requireActual('@react-navigation/native'),
useNavigation: () => ({ navigate: jest.fn() }),
}));
const StakingScreenWrapper = () => (
<LanguageProvider>
<PezkuwiProvider>
<StakingScreen />
</PezkuwiProvider>
</LanguageProvider>
);
describe('StakingScreen', () => {
it('should render without crashing', () => {
const { toJSON } = render(<StakingScreenWrapper />);
expect(toJSON()).toBeTruthy();
});
it('should match snapshot', () => {
const { toJSON } = render(<StakingScreenWrapper />);
expect(toJSON()).toMatchSnapshot();
});
});