2022-10-20 20:20:49 +02:00
|
|
|
import React from 'react';
|
|
|
|
import configureMockStore from 'redux-mock-store';
|
|
|
|
import { renderWithProvider } from '../../../../test/lib/render-helpers';
|
|
|
|
import UserPreferencedCurrencyDisplay from '.';
|
|
|
|
|
|
|
|
describe('UserPreferencedCurrencyDisplay Component', () => {
|
|
|
|
describe('rendering', () => {
|
|
|
|
const mockState = {
|
|
|
|
metamask: {
|
2023-05-02 17:53:20 +02:00
|
|
|
providerConfig: {
|
2022-10-20 20:20:49 +02:00
|
|
|
chainId: '0x99',
|
|
|
|
},
|
|
|
|
preferences: {
|
|
|
|
useNativeCurrencyAsPrimaryCurrency: true,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|
|
|
|
const mockStore = configureMockStore()(mockState);
|
|
|
|
|
|
|
|
it('should match snapshot', () => {
|
|
|
|
const { container } = renderWithProvider(
|
|
|
|
<UserPreferencedCurrencyDisplay />,
|
|
|
|
mockStore,
|
|
|
|
);
|
|
|
|
|
|
|
|
expect(container).toMatchSnapshot();
|
|
|
|
});
|
|
|
|
});
|
|
|
|
});
|