Skip to content

Commit

Permalink
Merge pull request #91 from stalniy/fix/updates
Browse files Browse the repository at this point in the history
chore(package): drop support for node 0.x
  • Loading branch information
keithamus authored Jan 10, 2018
2 parents 27d9769 + fc83ab5 commit 509926a
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 17 deletions.
8 changes: 5 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
sudo: false
language: node_js
node_js:
- 0.1
- 4.3
- stable
- 4 # to be removed 2018-04-01
- 6 # to be removed 2019-04-01
- 7 # to be removed 2017-06-30
- lts/* # safety net; don't remove
- node # safety net; don't remove

script:
- npm run test.only
Expand Down
13 changes: 7 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,15 @@
"build": "rollup -c support/compile.js"
},
"engines": {
"node": ">= 0.4.0"
"node": ">= 4.0.0"
},
"peerDependencies": {
"chai": "*"
},
"dependencies": {},
"devDependencies": {
"chai": "*",
"mocha": "*",
"rollup": "^0.47.4",
"rollup-plugin-commonjs": "^8.1.0"
},
"optionalDependencies": {}
"rollup": "^0.53.3",
"rollup-plugin-commonjs": "^8.2.6"
}
}
17 changes: 9 additions & 8 deletions support/compile.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ import commonjs from 'rollup-plugin-commonjs';

const MODULE_NAME = '__chaiSpies__'

function injectChaiPresenceCheck() {
function replaceGlobalExportWithChaiUse() {
return {
name: 'chai-presence-check',
name: 'chai-use',

transformBundle(source, options) {
return source.replace(
Expand All @@ -21,13 +21,14 @@ function injectChaiPresenceCheck() {
}

export default {
entry: 'lib/spy.js',
dest: './chai-spies.js',
format: 'umd',
exports: 'default',
moduleName: MODULE_NAME,
input: 'lib/spy.js',
output: {
format: 'umd',
name: MODULE_NAME,
file: './chai-spies.js'
},
plugins: [
commonjs(),
injectChaiPresenceCheck()
replaceGlobalExportWithChaiUse()
]
};

0 comments on commit 509926a

Please sign in to comment.