diff --git a/test/bootstrap.test.js b/test/bootstrap.test.js index 5c42efc..da3a5b1 100644 --- a/test/bootstrap.test.js +++ b/test/bootstrap.test.js @@ -44,6 +44,23 @@ test('Boostrap new app with an initial state', assert => { }) }) +test('Boostrap new app with initial state on modules', assert => { + const testModule = { initialState: { foo: 'bar' } } + + const app = boot(null, [testModule]) + + app.then(({action, store}) => { + + assert.deepEqual( + store.getState(), + testModule.initialState, + 'State is equal to module\'s initial state' + ) + + assert.end() + }) +}) + test('Boostrap new app with a module implementing a reducer', assert => { const initialState = { foo: 'bar' @@ -212,4 +229,4 @@ test('Boostrap new app with a module implementing an enhancer', assert => { assert.end() }) -}) \ No newline at end of file +})