mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-29 07:16:36 +01:00
32 lines
832 B
JavaScript
32 lines
832 B
JavaScript
|
import React from 'react';
|
||
|
import { renderWithProvider } from '../../../../test/jest';
|
||
|
import configureStore from '../../../store/store';
|
||
|
import mockState from '../../../../test/data/mock-state.json';
|
||
|
import ComplianceDetailsModal from './compliance-details-modal';
|
||
|
|
||
|
const props = {
|
||
|
hideModal: jest.fn(),
|
||
|
onGenerateComplianceReport: jest.fn(),
|
||
|
reportAddress: '0xAddress',
|
||
|
};
|
||
|
|
||
|
const render = () => {
|
||
|
const store = configureStore({
|
||
|
...mockState,
|
||
|
metamask: {},
|
||
|
history: {
|
||
|
mostRecentOverviewPage: 'test',
|
||
|
},
|
||
|
});
|
||
|
|
||
|
return renderWithProvider(<ComplianceDetailsModal {...props} />, store);
|
||
|
};
|
||
|
|
||
|
describe('Compliance Modal', function () {
|
||
|
it('render correctly with the correct header', function () {
|
||
|
const { getByText } = render();
|
||
|
|
||
|
expect(getByText('AML/CFT Compliance')).toBeVisible();
|
||
|
});
|
||
|
});
|