Avoid running native tests with node < 4.0.0
This commit is contained in:
parent
27d9813114
commit
c4f4c1c0e0
@ -1,10 +1,14 @@
|
|||||||
var ConnectionParameters = require(__dirname + '/../lib/connection-parameters');
|
var ConnectionParameters = require(__dirname + '/../lib/connection-parameters');
|
||||||
var config = new ConnectionParameters(process.argv[2]);
|
var config = new ConnectionParameters(process.argv[2]);
|
||||||
|
var semver = require('semver')
|
||||||
|
|
||||||
for(var i = 0; i < process.argv.length; i++) {
|
for(var i = 0; i < process.argv.length; i++) {
|
||||||
switch(process.argv[i].toLowerCase()) {
|
switch(process.argv[i].toLowerCase()) {
|
||||||
case 'native':
|
case 'native':
|
||||||
config.native = true;
|
if (semver.gte(process.version, '4.0.0')) {
|
||||||
|
console.log('Not running native in node < v4.0.0')
|
||||||
|
config.native = true;
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case 'binary':
|
case 'binary':
|
||||||
config.binary = true;
|
config.binary = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user