forked from sombochea/verdaccio-ui
chore: sync with verdaccio master
This commit is contained in:
27
test/unit/webui/components/notfound.spec.js
Normal file
27
test/unit/webui/components/notfound.spec.js
Normal file
@@ -0,0 +1,27 @@
|
||||
/**
|
||||
* NotFound component
|
||||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { BrowserRouter as Router } from 'react-router-dom';
|
||||
import { shallow } from 'enzyme';
|
||||
import NotFound from '../../../../src/webui/components/NotFound/index';
|
||||
|
||||
console.error = jest.fn();
|
||||
|
||||
describe('<NotFound /> component', () => {
|
||||
let routerWrapper;
|
||||
beforeEach(() => {
|
||||
routerWrapper = shallow(
|
||||
<Router>
|
||||
<NotFound />
|
||||
</Router>
|
||||
);
|
||||
});
|
||||
|
||||
|
||||
test('should load the component in default state', () => {
|
||||
expect(routerWrapper.find(NotFound)).toMatchSnapshot();
|
||||
});
|
||||
|
||||
});
|
||||
Reference in New Issue
Block a user