Skip to content

Commit

Permalink
missing test
Browse files Browse the repository at this point in the history
  • Loading branch information
komissarovyv committed Feb 22, 2018
1 parent 290177c commit 41bb0ab
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
'use strict';

Object.defineProperty(exports, "__esModule", {
value: true
value: true,
});
exports.composeReducers = exports.createReducer = undefined;

Expand Down
14 changes: 13 additions & 1 deletion test/createReducerTest.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/* global describe, it, before */

import chai from 'chai';
import {createReducer} from '../src';
import {createStore} from 'redux';
import {createReducer} from '../src';

chai.expect();

Expand All @@ -25,6 +25,18 @@ describe('Test init', () => {
});
});

describe('Test init', () => {
before(() => {
reducer = createReducer().toFunction();
store = createStore(reducer);
});
describe('Test reducer with default initial state', () => {
it('should be empty object', () => {
expect(store.getState()).to.deep.equal({});
});
});
});

describe('Test state mutation', () => {
before(() => {
reducer = createReducer({
Expand Down

0 comments on commit 41bb0ab

Please sign in to comment.