X-Git-Url: https://gerrit.onap.org/r/gitweb?p=aai%2Fsparky-fe.git;a=blobdiff_plain;f=test%2Fapp%2Finventory%2FInventory.test.js;fp=test%2Fapp%2Finventory%2FInventory.test.js;h=45b34503b74d42d85370ed0ce1c0f83fa0db55e9;hp=0000000000000000000000000000000000000000;hb=b2c7546f9027099161aeaf5791f1d0f3a52b92d2;hpb=85fa41b6a03a3914788e825cb28db84b33772489 diff --git a/test/app/inventory/Inventory.test.js b/test/app/inventory/Inventory.test.js new file mode 100644 index 0000000..45b3450 --- /dev/null +++ b/test/app/inventory/Inventory.test.js @@ -0,0 +1,30 @@ +import React from 'react'; +import thunk from 'redux-thunk'; + +import configureMockStore from 'redux-mock-store'; +import expect from 'expect'; + +import Inventory from 'app/inventory/Inventory'; +import {shallow} from 'enzyme'; + + +const mockStore = configureMockStore([thunk]); +const store = mockStore({inventoryReducer: {}}); + +describe('Inventory component', () => { + + fetch = require('jest-fetch-mock'); + + it('should be rendered', () => { + + // when + let wrapper = shallow( + + ); + + // then + let actual = wrapper.render().text(); + expect(actual).toInclude('Active Inventory'); + }); + +});