minor tweaking...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2020-07-14 20:10:49 +03:00
parent ab400e432d
commit 779e842923
2 changed files with 9 additions and 6 deletions

View File

@ -28,6 +28,6 @@
"devDependencies": { "devDependencies": {
"c8": "*", "c8": "*",
"colors": "^1.4.0", "colors": "^1.4.0",
"ig-argv": "^2.0.1" "ig-argv": "^2.2.2"
} }
} }

13
test.js
View File

@ -911,7 +911,7 @@ if(typeof(__filename) != 'undefined'
Each of the items in the test spec can be a "*" indicating Each of the items in the test spec can be a "*" indicating
that all relevant items should be used, for example: that all relevant items should be used, for example:
${ '$ ./$SCRIPTNAME basic:*:*' } $ ./$SCRIPTNAME basic:*:*
Here $SCRIPTNAME is instructed to run all tests and modifiers Here $SCRIPTNAME is instructed to run all tests and modifiers
only on the basic setup. only on the basic setup.
@ -965,9 +965,12 @@ if(typeof(__filename) != 'undefined'
process.exit() }}, process.exit() }},
'-verbose': { '-verbose': {
doc: 'verbose mode (defaults to: $VERBOSE).', doc: 'verbose mode',
env: 'VERBOSE',
handler: function(){ handler: function(){
module.VERBOSE = true }}, module.VERBOSE = true }},
'@*': undefined,
}) })
.then(function(chains){ .then(function(chains){
// run the tests... // run the tests...
@ -978,7 +981,8 @@ if(typeof(__filename) != 'undefined'
: runner('*', stats) : runner('*', stats)
// print stats... // print stats...
console.log('Tests run:', stats.tests, console.log(
'Tests run:', stats.tests,
' Assertions:', stats.assertions, ' Assertions:', stats.assertions,
' Failures:', stats.failures, ' Failures:', stats.failures,
` (${stats.time}ms)`.bold.black) ` (${stats.time}ms)`.bold.black)
@ -986,8 +990,7 @@ if(typeof(__filename) != 'undefined'
// report error status to the OS... // report error status to the OS...
process.exit(stats.failures) process.exit(stats.failures)
}) })
(process.argv) (process.argv) }
}