This repository was archived by the owner on Sep 9, 2021. It is now read-only.
File tree 5 files changed +38
-14
lines changed
5 files changed +38
-14
lines changed Original file line number Diff line number Diff line change
1
+ {
2
+ "presets" : [" es2015" ]
3
+ }
Original file line number Diff line number Diff line change @@ -19,6 +19,7 @@ coverage
19
19
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
20
20
.grunt
21
21
22
+ /build
22
23
# node-waf configuration
23
24
.lock-wscript
24
25
Original file line number Diff line number Diff line change
1
+ instrumentation :
2
+ root : src
3
+ include-all-sources : true
4
+ es-modules : false
5
+ reporting :
6
+ print : summary
7
+ reports :
8
+ - lcov
9
+ - html
10
+ dir : ./build/coverage
11
+ watermarks :
12
+ statements : [70, 90]
13
+ lines : [70, 90]
14
+ functions : [70, 90]
15
+ branches : [70, 90]
Original file line number Diff line number Diff line change 3
3
"version" : " 0.0.0" ,
4
4
"private" : true ,
5
5
"scripts" : {
6
- "start" : " node --use_strict ./bin/server" ,
7
- "test" : " node_modules/.bin/mocha ./src/test"
6
+ "start" : " babel-node bin/server" ,
7
+ "test" : " mocha --compilers js:babel-register src/test/**/*-test.js" ,
8
+ "cover" : " babel-node node_modules/.bin/isparta cover _mocha -- --reporter dot src/test/**/*-test.js" ,
9
+ "clean" : " rm -rf ./build"
8
10
},
9
11
"dependencies" : {
10
12
"body-parser" : " ~1.13.2" ,
11
13
"cookie-parser" : " ~1.3.5" ,
12
14
"debug" : " ~2.2.0" ,
13
15
"express" : " ~4.13.1" ,
14
- "hbs" : " ~3.1.0" ,
15
16
"morgan" : " ~1.6.1" ,
16
- "request" : " ^2.72.0" ,
17
- "serve-favicon" : " ~2.3.0"
17
+ "request" : " ^2.72.0"
18
18
},
19
19
"devDependencies" : {
20
20
"babel-cli" : " ^6.7.5" ,
21
+ "babel-preset-es2015" : " ^6.6.0" ,
22
+ "babel-register" : " ^6.7.2" ,
21
23
"chai" : " ^3.5.0" ,
24
+ "isparta" : " ^4.0.0" ,
25
+ "istanbul" : " ^0.4.3" ,
22
26
"mocha" : " ^2.4.5" ,
23
27
"sinon" : " ^1.17.3"
24
28
}
Original file line number Diff line number Diff line change 1
- var expect = require ( 'chai' ) . expect ;
2
- var sinon = require ( 'sinon' ) ;
1
+ let expect = require ( 'chai' ) . expect ;
2
+ let sinon = require ( 'sinon' ) ;
3
3
4
- var indexImpl = require ( '../../main/index/index-impl' ) ;
5
- var info = require ( '../../main/index/info' ) ;
4
+ let indexImpl = require ( '../../main/index/index-impl' ) ;
5
+ let info = require ( '../../main/index/info' ) ;
6
6
7
- describe ( 'Index implementation' , function ( ) {
7
+ describe ( 'Index implementation' , ( ) => {
8
8
9
- describe ( 'GET request' , function ( ) {
9
+ describe ( 'GET request' , ( ) => {
10
10
11
- it ( 'should send info object to json method' , function ( ) {
12
- var req , res , spy ;
11
+ it ( 'should send info object to json method' , ( ) => {
12
+ let req = { } ;
13
+ let res = { } ;
14
+ let spy ;
13
15
14
- req = res = { } ;
15
16
spy = res . json = sinon . spy ( ) ;
16
17
17
18
indexImpl . get ( req , res ) ;
You can’t perform that action at this time.
0 commit comments