Compare commits

...

3 Commits

Author SHA1 Message Date
130e7c6c1a fix
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
2026-01-02 15:59:59 +03:00
5e5204d04b ff dos -> unix
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
2026-01-02 15:58:52 +03:00
dadd8a8546 now setups, modifiers, tests and cases starting with '_' will not be run...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
2026-01-02 15:55:25 +03:00
3 changed files with 1223 additions and 1215 deletions

View File

@ -1,6 +1,6 @@
{ {
"name": "ig-test", "name": "ig-test",
"version": "1.6.5", "version": "1.6.7",
"description": "experimental test runner....", "description": "experimental test runner....",
"main": "test.js", "main": "test.js",
"bin": { "bin": {

26
test.js
View File

@ -488,15 +488,17 @@ function(spec, chain, mod_chain_length=1){
object.deepKeys(tests) object.deepKeys(tests)
.filter(function(t, i, l){ .filter(function(t, i, l){
return typeof(tests[t]) == 'function' return typeof(tests[t]) == 'function'
// skip blank tests if we have other tests unless // skip methods starting with '_'...
// explicitly specified... && t[0] != '_'
&& ((t == '-' // skip blank tests if we have other tests unless
&& chain.test != t // explicitly specified...
&& l.length > 1) ? && ((t == '-'
false && chain.test != t
: (chain == '**' && l.length > 1) ?
|| chain.test == '*' false
|| chain.test == t) ) }) : (chain == '**'
|| chain.test == '*'
|| chain.test == t) ) })
var mod_queue = [] var mod_queue = []
if(mod_chain_length > 0){ if(mod_chain_length > 0){
if(chain.mod instanceof Array){ if(chain.mod instanceof Array){
@ -505,6 +507,8 @@ function(spec, chain, mod_chain_length=1){
mod_queue = object.deepKeys(modifiers) mod_queue = object.deepKeys(modifiers)
.filter(function(m){ .filter(function(m){
return typeof(modifiers[m]) == 'function' return typeof(modifiers[m]) == 'function'
// skip methods starting with '_'...
&& m[0] != '_'
&& (chain == '**' && (chain == '**'
|| chain.mod == '*' || chain.mod == '*'
|| chain.mod == m) }) || chain.mod == m) })
@ -523,6 +527,8 @@ function(spec, chain, mod_chain_length=1){
var setup_queue = object.deepKeys(setups) var setup_queue = object.deepKeys(setups)
.filter(function(s){ .filter(function(s){
return typeof(setups[s]) == 'function' return typeof(setups[s]) == 'function'
// skip methods starting with '_'...
&& s[0] != '_'
&& (chain == '**' && (chain == '**'
|| chain.setup == '*' || chain.setup == '*'
|| chain.setup == s) }) || chain.setup == s) })
@ -549,6 +555,8 @@ function(spec, chain, mod_chain_length=1){
Object.keys(cases) Object.keys(cases)
.filter(function(s){ .filter(function(s){
return typeof(cases[s]) == 'function' return typeof(cases[s]) == 'function'
// skip methods starting with '_'...
&& s[0] != '_'
&& (chain == '**' && (chain == '**'
|| chain.setup == '*' || chain.setup == '*'
|| chain.setup == s) }) || chain.setup == s) })