Skip to content
This repository has been archived by the owner on Jan 6, 2021. It is now read-only.

Commit

Permalink
chore(deps): update cross-spawn and trash-cli (#14)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhuangya authored and Kent C. Dodds committed May 20, 2016
1 parent afc91b7 commit 22bf76d
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
},
"scripts": {
"start": "npm run test:watch",
"prebuild": "trash dist && mkdir dist",
"prebuild": "rimraf dist && mkdir dist",
"build": "cd src && babel index.js -d ../dist && cd ..",
"commit": "git-cz",
"eslint": "eslint src/ -c other/src.eslintrc --ignore-path other/src.eslintignore && eslint src/*.test.js",
Expand Down Expand Up @@ -47,10 +47,10 @@
"manage-path": "2.0.0",
"mocha": "2.3.3",
"proxyquire": "1.7.2",
"rimraf": "^2.5.2",
"semantic-release": "4.3.5",
"sinon": "1.17.1",
"sinon-chai": "2.8.0",
"trash": "2.0.0",
"validate-commit-msg": "1.0.0"
},
"config": {
Expand All @@ -62,7 +62,7 @@
}
},
"dependencies": {
"cross-spawn-async": "2.0.0",
"cross-spawn": "^3.0.1",
"lodash.assign": "^3.2.0"
}
}
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {spawn} from 'cross-spawn-async';
import {spawn} from 'cross-spawn';
import assign from 'lodash.assign';
export default crossEnv;

Expand Down
10 changes: 5 additions & 5 deletions src/index.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ chai.use(sinonChai);
const {expect} = chai;
const spawned = {on: sinon.spy()};
const proxied = {
'cross-spawn-async': {
'cross-spawn': {
spawn: sinon.spy(() => spawned)
}
};
Expand All @@ -19,7 +19,7 @@ const crossEnv = proxyquire('./index', proxied);
describe(`cross-env`, () => {

beforeEach(() => {
proxied['cross-spawn-async'].spawn.reset();
proxied['cross-spawn'].spawn.reset();
spawned.on.reset();
});

Expand Down Expand Up @@ -62,7 +62,7 @@ describe(`cross-env`, () => {

it(`should do nothing given no command`, () => {
crossEnv([]);
expect(proxied['cross-spawn-async'].spawn).to.have.not.been.called;
expect(proxied['cross-spawn'].spawn).to.have.not.been.called;
});

function testEnvSetting(expected, ...envSettings) {
Expand All @@ -72,8 +72,8 @@ describe(`cross-env`, () => {
assign(env, expected);

expect(ret, 'returns what spawn returns').to.equal(spawned);
expect(proxied['cross-spawn-async'].spawn).to.have.been.calledOnce;
expect(proxied['cross-spawn-async'].spawn).to.have.been.calledWith(
expect(proxied['cross-spawn'].spawn).to.have.been.calledOnce;
expect(proxied['cross-spawn'].spawn).to.have.been.calledWith(
'echo', ['hello world'], {
stdio: 'inherit',
env: assign({}, process.env, env)
Expand Down

0 comments on commit 22bf76d

Please sign in to comment.