rename all test files to *.test.js

This commit is contained in:
Keith Grant
2019-04-10 09:55:57 -04:00
parent 70137dea5a
commit 909c5e77c4
23 changed files with 0 additions and 0 deletions

View File

@@ -0,0 +1,29 @@
import React from 'react';
import { mount } from 'enzyme';
import InventoryScripts from '../../src/pages/InventoryScripts';
describe('<InventoryScripts />', () => {
let pageWrapper;
let pageSections;
let title;
beforeEach(() => {
pageWrapper = mount(<InventoryScripts />);
pageSections = pageWrapper.find('PageSection');
title = pageWrapper.find('Title');
});
afterEach(() => {
pageWrapper.unmount();
});
test('initially renders without crashing', () => {
expect(pageWrapper.length).toBe(1);
expect(pageSections.length).toBe(2);
expect(title.length).toBe(1);
expect(title.props().size).toBe('2xl');
pageSections.forEach(section => {
expect(section.props().variant).toBeDefined();
});
});
});