Skip to content

Commit

Permalink
Running tests and coverage against src, not lib
Browse files Browse the repository at this point in the history
Fixes: #31
  • Loading branch information
sadasant committed Feb 17, 2017
1 parent 30ff37a commit f320ee3
Show file tree
Hide file tree
Showing 8 changed files with 15 additions and 19 deletions.
14 changes: 6 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,15 @@
{
"name": "futil-js",
"version": "1.7.0",
"version": "1.7.1",
"description": "F(unctional) util(ities). Resistance is futile.",
"main": "lib/futil-js.js",
"scripts": {
"build": "webpack",
"test": "mocha",
"test": "babel-node ./node_modules/mocha/bin/_mocha",
"test:watch": "chokidar 'src/*.js' 'test/*.js' -c 'npm t'",
"coverage": "babel-node ./node_modules/istanbul/lib/cli.js cover ./node_modules/mocha/bin/_mocha",
"cicoverage": "babel-node ./node_modules/istanbul/lib/cli.js cover ./node_modules/mocha/bin/_mocha --report lcovonly -- -R spec && cat ./coverage/lcov.info",
"lint": "eslint src/*.js test/*.js",
"pretest": "npm run build",
"precoverage": "npm run build"
"coverage": "nyc --require babel-core/register node_modules/.bin/mocha test",
"cicoverage": "nyc --reporter=lcov --require babel-core/register node_modules/.bin/mocha test && cat ./coverage/lcov.info",
"lint": "eslint src/*.js test/*.js"
},
"author": "Samuel Greene <sgreene@smartprocure.us>",
"license": "MIT",
Expand All @@ -38,9 +36,9 @@
"eslint-config-smartprocure": "^0.0.4",
"eslint-plugin-lodash-fp": "^2.0.1",
"eslint-plugin-mocha": "^4.8.0",
"istanbul": "^0.4.5",
"mocha": "^3.2.0",
"mocha-lcov-reporter": "^1.2.0",
"nyc": "^10.1.2",
"webpack": "^2.2.1"
},
"directories": {
Expand Down
2 changes: 1 addition & 1 deletion test/array.spec.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import chai from 'chai'
import * as f from '../lib/futil-js'
import * as f from '../src/'
chai.expect()
const expect = chai.expect

Expand Down
2 changes: 1 addition & 1 deletion test/collections.spec.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import chai from 'chai'
import * as f from '../lib/futil-js'
import * as f from '../src/'

chai.expect()
const expect = chai.expect
Expand Down
4 changes: 2 additions & 2 deletions test/flipped.spec.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import chai from 'chai'
import * as f from '../lib/futil-js'
import * as f from '../src'

chai.expect()
const expect = chai.expect
Expand All @@ -14,4 +14,4 @@ describe('Flipped FP Functions', function() {
a: 1
})('a')).to.equal(1)
})
})
})
2 changes: 1 addition & 1 deletion test/misc.spec.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import chai from 'chai'
import * as f from '../lib/futil-js'
import * as f from '../src'
chai.expect()
const expect = chai.expect

Expand Down
2 changes: 0 additions & 2 deletions test/mocha.opts

This file was deleted.

4 changes: 2 additions & 2 deletions test/mutables.spec.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import chai from 'chai'
import * as f from '../lib/futil-js'
import * as f from '../src'

chai.expect()
const expect = chai.expect
Expand Down Expand Up @@ -32,4 +32,4 @@ describe('Mutable FP Functions', function() {
c: 4
})
})
})
})
4 changes: 2 additions & 2 deletions test/objects.spec.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import chai from 'chai'
import * as f from '../lib/futil-js'
import * as f from '../src'

chai.expect()
const expect = chai.expect
Expand Down Expand Up @@ -62,4 +62,4 @@ describe('Object Functions', function() {
'a.b.c': 1
})
})
})
})

0 comments on commit f320ee3

Please sign in to comment.