mirror of
https://github.com/lrsjng/h5ai.git
synced 2025-05-24 12:07:10 -04:00
Refactor test runner
This commit is contained in:
parent
df76ca0807
commit
c8bffa006b
4 changed files with 55 additions and 37 deletions
|
@ -1,42 +1,35 @@
|
|||
// @include "lib/*.js"
|
||||
// @include "util/*.js"
|
||||
|
||||
(function () {
|
||||
'use strict';
|
||||
|
||||
$(function () {
|
||||
'use strict';
|
||||
|
||||
modulejs.define('config', util.uniqObj());
|
||||
_.each(modulejs._private.instances, function (val, key) {
|
||||
delete modulejs._private.instances[key];
|
||||
util.mockConfigModule();
|
||||
util.clearModulejs();
|
||||
util.setupMocha();
|
||||
|
||||
describe('all tests', function () {
|
||||
|
||||
// @include "tests/premisses.js"
|
||||
|
||||
describe('unit tests', function () {
|
||||
|
||||
// @include "tests/unit/modulejs.js"
|
||||
// @include "tests/unit/libs.js"
|
||||
// @include "tests/unit/boot.js"
|
||||
// @include "tests/unit/config.js"
|
||||
|
||||
// @include "tests/unit/*/*.js"
|
||||
});
|
||||
|
||||
describe('integration tests', function () {
|
||||
|
||||
// @include "tests/integration/first.js"
|
||||
|
||||
// @include "tests/integration/*/*.js"
|
||||
});
|
||||
});
|
||||
|
||||
util.pinHtml();
|
||||
util.runMocha();
|
||||
});
|
||||
|
||||
util.setupMocha();
|
||||
|
||||
describe('all tests', function () {
|
||||
|
||||
// @include "tests/premisses.js"
|
||||
|
||||
describe('unit tests', function () {
|
||||
|
||||
// @include "tests/unit/modulejs.js"
|
||||
// @include "tests/unit/libs.js"
|
||||
// @include "tests/unit/boot.js"
|
||||
// @include "tests/unit/config.js"
|
||||
|
||||
// @include "tests/unit/*/*.js"
|
||||
});
|
||||
|
||||
describe('integration tests', function () {
|
||||
|
||||
// @include "tests/integration/first.js"
|
||||
|
||||
// @include "tests/integration/*/*.js"
|
||||
});
|
||||
});
|
||||
|
||||
}());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue