File tree Expand file tree Collapse file tree 3 files changed +9
-6
lines changed
Expand file tree Collapse file tree 3 files changed +9
-6
lines changed Original file line number Diff line number Diff line change 99 ],
1010 "scripts" : {
1111 "build" : " babel src --out-dir lib" ,
12- "prepublish" : " rimraf lib && npm run build" ,
13- "test" : " mocha --compilers js:babel-core/register --reporter spec test/*.js"
12+ "prepublish" : " npm run test && rimraf lib && npm run build" ,
13+ "test" : " mocha --compilers js:babel-core/register --reporter spec test/*.js" ,
14+ "posttest" : " npm run lint" ,
15+ "lint" : " eslint src test"
1416 },
1517 "repository" : {
1618 "type" : " git" ,
3739 "chai" : " ^3.2.0" ,
3840 "eslint" : " ^1.10.2" ,
3941 "eslint-config-airbnb" : " 1.0.2" ,
42+ "eslint-plugin-react" : " ^4.1.0" ,
4043 "mocha" : " ^2.2.5" ,
4144 "rimraf" : " ^2.4.3"
4245 }
Original file line number Diff line number Diff line change @@ -5,4 +5,4 @@ function thunkMiddleware({ dispatch, getState }) {
55 next ( action ) ;
66}
77
8- module . exports = thunkMiddleware
8+ module . exports = thunkMiddleware ;
Original file line number Diff line number Diff line change @@ -45,15 +45,15 @@ describe('thunk middleware', () => {
4545 const expected = 'redux' ;
4646 const actionHandler = nextHandler ( ( ) => expected ) ;
4747
48- let outcome = actionHandler ( ) ;
48+ const outcome = actionHandler ( ) ;
4949 chai . assert . strictEqual ( outcome , expected ) ;
5050 } ) ;
5151
5252 it ( 'must return value as expected if a function' , ( ) => {
5353 const expected = 'rocks' ;
5454 const actionHandler = nextHandler ( ) ;
5555
56- let outcome = actionHandler ( ( ) => expected ) ;
56+ const outcome = actionHandler ( ( ) => expected ) ;
5757 chai . assert . strictEqual ( outcome , expected ) ;
5858 } ) ;
5959
@@ -71,7 +71,7 @@ describe('thunk middleware', () => {
7171 it ( 'must throw if argument is non-object' , done => {
7272 try {
7373 thunkMiddleware ( ) ;
74- } catch ( err ) {
74+ } catch ( err ) {
7575 done ( ) ;
7676 }
7777 } ) ;
You can’t perform that action at this time.
0 commit comments