Skip to content

Commit 78a5fef

Browse files
authored
Merge pull request #4 from dmitry-zaets/master
Fix export of assertions
2 parents 3a83e53 + 2ce96f2 commit 78a5fef

File tree

5 files changed

+20
-4
lines changed

5 files changed

+20
-4
lines changed

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "redux-actions-assertions-js",
33
"description": "Javascript assertions for redux actions testing",
4-
"version": "1.0.0",
4+
"version": "1.1.0",
55
"main": "lib/index.js",
66
"files": [
77
"lib"

src/assertions.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { toDispatchActionsWithState } from './asserts/toDispatchActionsWithState
33
import { toNotDispatchActions } from './asserts/toNotDispatchActions';
44
import { toNotDispatchActionsWithState } from './asserts/toNotDispatchActionsWithState';
55

6-
export default {
6+
export const assertions = {
77
toDispatchActions,
88
toDispatchActionsWithState,
99
toNotDispatchActions,

src/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { registerMiddlewares } from './mockStore';
22
import { registerInitialStoreState, buildInitialStoreState } from './initialState';
3-
import assertions from './assertions';
3+
import { assertions } from './assertions';
44

55
export {
66
registerMiddlewares,

test/assertions/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import expect from 'expect';
2-
import assertions from '../../src/assertions';
2+
import { assertions } from '../../src/assertions';
33

44
describe('assertions', () => {
55
it('should export toDispatchActions', () => {

test/index.js

+16
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,20 @@ describe('index', () => {
2222
it('should export assertions', () => {
2323
expect(assertions).toBeA('object');
2424
});
25+
26+
it('should export toDispatchActions', () => {
27+
expect(assertions.toDispatchActions).toBeA('function');
28+
});
29+
30+
it('should export toDispatchActionsWithState', () => {
31+
expect(assertions.toDispatchActionsWithState).toBeA('function');
32+
});
33+
34+
it('should export toNotDispatchActions', () => {
35+
expect(assertions.toNotDispatchActions).toBeA('function');
36+
});
37+
38+
it('should export toNotDispatchActionsWithState', () => {
39+
expect(assertions.toNotDispatchActionsWithState).toBeA('function');
40+
});
2541
});

0 commit comments

Comments
 (0)