-
Notifications
You must be signed in to change notification settings - Fork 48
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
WIP on node-qunit testing, not working yet
- Loading branch information
Showing
1 changed file
with
30 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
var qunit = require('qunit'), | ||
path = require('path'); | ||
|
||
qunit.options.coverage = false; | ||
|
||
function abspath(p) { | ||
return path.join(__dirname, p); | ||
} | ||
|
||
// time.js tests aren't dependent on js-forms in any way | ||
qunit.run({ | ||
code: abspath('../src/time.js'), | ||
tests: abspath('time.js') | ||
}); | ||
|
||
// js-forms tests | ||
var lib = abspath('../js-forms.js') | ||
path.exists(lib, function(exists) { | ||
if (!exists) { | ||
console.log(lib + " doesn't exist - run build.py"); | ||
return; | ||
} | ||
|
||
qunit.run({ | ||
code: lib, | ||
tests: ['util.js', 'validators.js', 'forms.js', 'formsets.js', | ||
'fields.js','errormessages.js', 'widgets.js', 'extra.js', | ||
'regressions.js'].map(abspath) | ||
}); | ||
}); |