Skip to content

Commit

Permalink
Run tests without jQuery (package by package).
Browse files Browse the repository at this point in the history
Adds support for running tests per-package without jQuery so that jQuery
requirements do not creep into the rest of the framework.
  • Loading branch information
rwjblue committed Dec 23, 2017
1 parent 0ae232b commit 18aafe1
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 12 deletions.
6 changes: 6 additions & 0 deletions bin/run-tests.js
Original file line number Diff line number Diff line change
Expand Up @@ -184,9 +184,15 @@ function generateEachPackageTests() {
testFunctions.push(function() {
return run('package=' + packageName);
});
if (packages[packageName].requiresJQuery === false) {
testFunctions.push(function() {
return run('package=' + packageName + '&jquery=none');
});
}
testFunctions.push(function() {
return run('package=' + packageName + '&enableoptionalfeatures=true');
});

});
}

Expand Down
24 changes: 12 additions & 12 deletions lib/packages.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
module.exports = function() {
var packages = {
'container': { trees: null, requirements: ['ember-utils'], isTypeScript: true, vendorRequirements: ['@glimmer/di'] },
'ember-environment': { trees: null, requirements: [], skipTests: true },
'ember-utils': { trees: null, requirements: [] },
'ember-console': { trees: null, requirements: [], skipTests: true },
'ember-metal': { trees: null, requirements: ['ember-environment', 'ember-utils'], vendorRequirements: ['backburner'] },
'ember-debug': { trees: null, requirements: [] },
'ember-runtime': { trees: null, vendorRequirements: ['rsvp'], requirements: ['container', 'ember-environment', 'ember-console', 'ember-metal'] },
'container': { trees: null, requirements: ['ember-utils'], isTypeScript: true, vendorRequirements: ['@glimmer/di'], requiresJQuery: false },
'ember-environment': { trees: null, requirements: [], skipTests: true, requiresJQuery: false },
'ember-utils': { trees: null, requirements: [], requiresJQuery: false },
'ember-console': { trees: null, requirements: [], skipTests: true, requiresJQuery: false },
'ember-metal': { trees: null, requirements: ['ember-environment', 'ember-utils'], vendorRequirements: ['backburner'], requiresJQuery: false },
'ember-debug': { trees: null, requirements: [], requiresJQuery: false },
'ember-runtime': { trees: null, vendorRequirements: ['rsvp'], requirements: ['container', 'ember-environment', 'ember-console', 'ember-metal'], requiresJQuery: false },
'ember-views': { trees: null, requirements: ['ember-runtime'], skipTests: true },
'ember-extension-support': { trees: null, requirements: ['ember-application'] },
'ember-extension-support': { trees: null, requirements: ['ember-application'], requiresJQuery: false },
'ember-testing': { trees: null, requirements: ['ember-application', 'ember-routing'], testing: true },
'ember-template-compiler': {
trees: null,
Expand All @@ -27,10 +27,10 @@ module.exports = function() {
]
},
'ember-routing': { trees: null, vendorRequirements: ['router', 'route-recognizer'],
requirements: ['ember-runtime', 'ember-views'] },
'ember-application': { trees: null, vendorRequirements: ['dag-map'], requirements: ['ember-routing'] },
requirements: ['ember-runtime', 'ember-views'], requiresJQuery: false },
'ember-application': { trees: null, vendorRequirements: ['dag-map'], requirements: ['ember-routing'], requiresJQuery: false },
'ember': { trees: null, requirements: ['ember-application'] },
'internal-test-helpers': { trees: null },
'internal-test-helpers': { trees: null, requiresJQuery: false },

'ember-glimmer': {
trees: null,
Expand All @@ -43,7 +43,7 @@ module.exports = function() {
'@glimmer/wire-format',
'@glimmer/node'
],
testingVendorRequirements: []
testingVendorRequirements: [],
}
};

Expand Down

0 comments on commit 18aafe1

Please sign in to comment.