mirror of
https://github.com/jquery/jquery.git
synced 2024-11-23 02:54:22 +00:00
Build: Drop cross-spawn, use child_process.spawn shell option
This commit is contained in:
parent
90bac40a51
commit
781647b182
@ -3,11 +3,13 @@
|
|||||||
// Run Node with provided parameters: the first one being the Grunt
|
// Run Node with provided parameters: the first one being the Grunt
|
||||||
// done function and latter ones being files to be tested.
|
// done function and latter ones being files to be tested.
|
||||||
// See the comment in ../node_smoke_tests.js for more information.
|
// See the comment in ../node_smoke_tests.js for more information.
|
||||||
module.exports = function spawnTest( done ) {
|
module.exports = function spawnTest( done, command ) {
|
||||||
var testPaths = [].slice.call( arguments, 1 ),
|
var spawn = require( "child_process" ).spawn;
|
||||||
spawn = require( "cross-spawn" );
|
|
||||||
|
|
||||||
spawn( "node", testPaths, { stdio: "inherit" } )
|
spawn( command, {
|
||||||
|
stdio: "inherit",
|
||||||
|
shell: true
|
||||||
|
} )
|
||||||
.on( "close", function( code ) {
|
.on( "close", function( code ) {
|
||||||
done( code === 0 );
|
done( code === 0 );
|
||||||
} );
|
} );
|
||||||
|
@ -22,7 +22,7 @@ module.exports = function( grunt ) {
|
|||||||
var taskName = "node_" + testFilePath.replace( /\.js$/, "" );
|
var taskName = "node_" + testFilePath.replace( /\.js$/, "" );
|
||||||
|
|
||||||
grunt.registerTask( taskName, function() {
|
grunt.registerTask( taskName, function() {
|
||||||
spawnTest( this.async(), "test/node_smoke_tests/" + testFilePath );
|
spawnTest( this.async(), "node test/node_smoke_tests/" + testFilePath );
|
||||||
} );
|
} );
|
||||||
|
|
||||||
nodeSmokeTests.push( taskName );
|
nodeSmokeTests.push( taskName );
|
||||||
|
@ -9,15 +9,15 @@ module.exports = function( grunt ) {
|
|||||||
|
|
||||||
grunt.registerTask( "promises_aplus_tests:deferred", function() {
|
grunt.registerTask( "promises_aplus_tests:deferred", function() {
|
||||||
spawnTest( this.async(),
|
spawnTest( this.async(),
|
||||||
"./node_modules/.bin/promises-aplus-tests",
|
__dirname + "/../../node_modules/.bin/promises-aplus-tests" +
|
||||||
"test/promises_aplus_adapters/deferred.js"
|
" test/promises_aplus_adapters/deferred.js"
|
||||||
);
|
);
|
||||||
} );
|
} );
|
||||||
|
|
||||||
grunt.registerTask( "promises_aplus_tests:when", function() {
|
grunt.registerTask( "promises_aplus_tests:when", function() {
|
||||||
spawnTest( this.async(),
|
spawnTest( this.async(),
|
||||||
"./node_modules/.bin/promises-aplus-tests",
|
__dirname + "/../../node_modules/.bin/promises-aplus-tests" +
|
||||||
"test/promises_aplus_adapters/when.js"
|
" test/promises_aplus_adapters/when.js"
|
||||||
);
|
);
|
||||||
} );
|
} );
|
||||||
};
|
};
|
||||||
|
48
package-lock.json
generated
48
package-lock.json
generated
@ -986,17 +986,6 @@
|
|||||||
"integrity": "sha1-etIg1v/c0Rn5/BJ6d3LKzqOQpLo=",
|
"integrity": "sha1-etIg1v/c0Rn5/BJ6d3LKzqOQpLo=",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"cross-spawn": {
|
|
||||||
"version": "5.1.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-5.1.0.tgz",
|
|
||||||
"integrity": "sha1-6L0O/uWPz/b4+UUQoKVUu/ojVEk=",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"lru-cache": "4.1.1",
|
|
||||||
"shebang-command": "1.2.0",
|
|
||||||
"which": "1.2.14"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"cryptiles": {
|
"cryptiles": {
|
||||||
"version": "2.0.5",
|
"version": "2.0.5",
|
||||||
"resolved": "https://registry.npmjs.org/cryptiles/-/cryptiles-2.0.5.tgz",
|
"resolved": "https://registry.npmjs.org/cryptiles/-/cryptiles-2.0.5.tgz",
|
||||||
@ -3998,16 +3987,6 @@
|
|||||||
"signal-exit": "3.0.2"
|
"signal-exit": "3.0.2"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"lru-cache": {
|
|
||||||
"version": "4.1.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.1.tgz",
|
|
||||||
"integrity": "sha512-q4spe4KTfsAS1SUHLO0wz8Qiyf1+vMIAgpRYioFYDMNqKfHQbg+AVDH3i4fvpl71/P1L0dBl+fQi+P37UYf0ew==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"pseudomap": "1.0.2",
|
|
||||||
"yallist": "2.1.2"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"map-obj": {
|
"map-obj": {
|
||||||
"version": "1.0.1",
|
"version": "1.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/map-obj/-/map-obj-1.0.1.tgz",
|
"resolved": "https://registry.npmjs.org/map-obj/-/map-obj-1.0.1.tgz",
|
||||||
@ -4657,12 +4636,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"pseudomap": {
|
|
||||||
"version": "1.0.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz",
|
|
||||||
"integrity": "sha1-8FKijacOYYkX7wqKw0wa5aaChrM=",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"punycode": {
|
"punycode": {
|
||||||
"version": "1.4.1",
|
"version": "1.4.1",
|
||||||
"resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz",
|
"resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz",
|
||||||
@ -5075,21 +5048,6 @@
|
|||||||
"integrity": "sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU=",
|
"integrity": "sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU=",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"shebang-command": {
|
|
||||||
"version": "1.2.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz",
|
|
||||||
"integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"shebang-regex": "1.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"shebang-regex": {
|
|
||||||
"version": "1.0.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz",
|
|
||||||
"integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"sigmund": {
|
"sigmund": {
|
||||||
"version": "1.0.1",
|
"version": "1.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/sigmund/-/sigmund-1.0.1.tgz",
|
"resolved": "https://registry.npmjs.org/sigmund/-/sigmund-1.0.1.tgz",
|
||||||
@ -5661,12 +5619,6 @@
|
|||||||
"resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.1.tgz",
|
"resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.1.tgz",
|
||||||
"integrity": "sha1-pcbVMr5lbiPbgg77lDofBJmNY68=",
|
"integrity": "sha1-pcbVMr5lbiPbgg77lDofBJmNY68=",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
|
||||||
"yallist": {
|
|
||||||
"version": "2.1.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz",
|
|
||||||
"integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=",
|
|
||||||
"dev": true
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -29,7 +29,6 @@
|
|||||||
"babel-plugin-transform-es2015-for-of": "7.0.0-beta.0",
|
"babel-plugin-transform-es2015-for-of": "7.0.0-beta.0",
|
||||||
"commitplease": "2.7.10",
|
"commitplease": "2.7.10",
|
||||||
"core-js": "2.4.1",
|
"core-js": "2.4.1",
|
||||||
"cross-spawn": "5.1.0",
|
|
||||||
"eslint-config-jquery": "1.0.1",
|
"eslint-config-jquery": "1.0.1",
|
||||||
"grunt": "1.0.1",
|
"grunt": "1.0.1",
|
||||||
"grunt-babel": "7.0.0",
|
"grunt-babel": "7.0.0",
|
||||||
|
Loading…
Reference in New Issue
Block a user