mirror of
https://github.com/ansible/awx.git
synced 2026-02-02 01:58:09 -03:30
Get tests running again
This commit is contained in:
8
Makefile
8
Makefile
@@ -86,7 +86,7 @@ MOCK_CFG ?=
|
||||
develop refresh adduser syncdb migrate dbchange dbshell runserver celeryd \
|
||||
receiver test test_coverage coverage_html ui_analysis_report test_ui test_jenkins dev_build \
|
||||
release_build release_clean sdist rpmtar mock-rpm mock-srpm rpm-sign \
|
||||
deb deb-src debian reprepro setup_tarball sync_ui \
|
||||
deb deb-src debian reprepro setup_tarball sync_ui node-tests \
|
||||
virtualbox-ovf virtualbox-centos-7 virtualbox-centos-6
|
||||
|
||||
# Remove setup build files
|
||||
@@ -333,8 +333,10 @@ awx/ui/%: node_modules clean-ui Brocfile.js bower.json
|
||||
$(BROCCOLI_BIN) build $@ -- $(UI_FLAGS)
|
||||
|
||||
testjs: UI_FLAGS=--node-tests --no-concat --no-styles $(EXTRA_UI_FLAGS)
|
||||
testjs: awx/ui/build_test
|
||||
$(MOCHA_BIN) --full-trace $(shell find awx/ui/build_test -name '*-test.js')
|
||||
testjs: awx/ui/build_test node-tests
|
||||
|
||||
node-tests:
|
||||
NODE_PATH=awx/ui/build_test $(MOCHA_BIN) --full-trace $(shell find awx/ui/build_test -name '*-test.js')
|
||||
|
||||
devjs: awx/ui/static
|
||||
|
||||
|
||||
@@ -3,9 +3,9 @@
|
||||
import '../support/node';
|
||||
|
||||
import {describeModule} from '../support/describe-module';
|
||||
import '../../src/shared/Utilities';
|
||||
import '../../src/shared/RestServices';
|
||||
import JobStatusGraph from '../../src/dashboard/graphs/job-status/main';
|
||||
import 'shared/Utilities';
|
||||
import 'shared/RestServices';
|
||||
import JobStatusGraph from 'dashboard/graphs/job-status/main';
|
||||
|
||||
var resizeHandler = sinon.spy();
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import '../support/node';
|
||||
|
||||
import featuresController from '../../src/shared/features/features.controller';
|
||||
import featuresController from 'shared/features/features.controller';
|
||||
|
||||
describe('featuresController', function() {
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import '../support/node';
|
||||
|
||||
import features from '../../src/shared/features/main';
|
||||
import features from 'shared/features/main';
|
||||
import {describeModule} from '../support/describe-module';
|
||||
|
||||
//test that it returns features, as well as test that it is returned in rootScope
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import '../support/node';
|
||||
|
||||
import jobTemplates from '../../src/job-templates/main';
|
||||
import jobTemplates from 'job-templates/main';
|
||||
import {describeModule} from '../support/describe-module';
|
||||
|
||||
describeModule(jobTemplates.name)
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import '../support/node';
|
||||
|
||||
import {describeModule} from '../support/describe-module';
|
||||
import mod from '../../src/shared/multi-select-list/main';
|
||||
import mod from 'shared/multi-select-list/main';
|
||||
|
||||
describeModule(mod.name)
|
||||
.testDirective('multiSelectList', function(test) {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import '../support/node';
|
||||
|
||||
import {describeModule} from '../support/describe-module';
|
||||
import mod from '../../src/shared/multi-select-list/main';
|
||||
import mod from 'shared/multi-select-list/main';
|
||||
|
||||
var mockController = {
|
||||
selectAll: sinon.spy(),
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import '../support/node';
|
||||
|
||||
import {describeModule} from '../support/describe-module';
|
||||
import JobStatusGraph from '../../src/dashboard/graphs/job-status/main';
|
||||
import JobStatusGraph from 'dashboard/graphs/job-status/main';
|
||||
|
||||
var processErrors = sinon.spy();
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import '../support/node';
|
||||
|
||||
import '../../src/shared/main';
|
||||
import 'shared/main';
|
||||
|
||||
describe('LodashAsPromised', function() {
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
import '../../support/node';
|
||||
|
||||
import compareFacts from '../../../src/system-tracking/compare-facts/flat';
|
||||
import compareFacts from 'system-tracking/compare-facts/flat';
|
||||
|
||||
// This makes this test runnable in node OR karma. The sheer
|
||||
// number of times I had to run this test made the karma
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
import '../../support/node';
|
||||
|
||||
import compareFacts from '../../../src/system-tracking/compare-facts/nested';
|
||||
import compareFacts from 'system-tracking/compare-facts/nested';
|
||||
|
||||
describe('CompareFacts.Nested', function() {
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import '../support/node';
|
||||
|
||||
import systemTracking from '../../src/system-tracking/data-services/main';
|
||||
import systemTracking from 'system-tracking/data-services/main';
|
||||
import {describeModule} from '../support/describe-module';
|
||||
import moment from '../../src/shared/moment/moment';
|
||||
import moment from 'shared/moment/moment';
|
||||
|
||||
describeModule(systemTracking.name)
|
||||
.testService('factScanDataService', function(test, restStub) {
|
||||
|
||||
24
testem.yml
24
testem.yml
@@ -1,25 +1,23 @@
|
||||
---
|
||||
framework: mocha
|
||||
cwd: awx/ui/
|
||||
cwd: awx/ui/client
|
||||
port: 7358
|
||||
src_files:
|
||||
- client/**/*.js
|
||||
- client/**/*.js
|
||||
- src/**/*.js
|
||||
- tests/**/*.js
|
||||
serve_files:
|
||||
- static/tower.concat.js
|
||||
- static/tests/**/*.js
|
||||
- static/tests/unit.js
|
||||
- ../static/tower.concat.js
|
||||
- ../static/tests/**/*.js
|
||||
- ../static/tests/unit.js
|
||||
unsafe_file_serving: true
|
||||
test_page: tests.html
|
||||
disable_watching: true
|
||||
routes:
|
||||
/awx/ui/static: /static
|
||||
/tests.html: ../../packaging/grunt/testem.mustache
|
||||
/test-loader.js: client/lib/ember-cli-test-loader/test-loader.js
|
||||
/vendor: ../../node_modules
|
||||
/angular-mocks.js: static/lib/angular-mocks/angular-mocks.js
|
||||
/templates.js: static/templates.js
|
||||
/static: ../static
|
||||
/tests.html: ../../../packaging/grunt/testem.mustache
|
||||
/test-loader.js: lib/ember-cli-test-loader/test-loader.js
|
||||
/vendor: ../../../node_modules
|
||||
/angular-mocks.js: lib/angular-mocks/angular-mocks.js
|
||||
reporter: xunit
|
||||
launch_in_dev:
|
||||
- Mocha
|
||||
@@ -27,4 +25,4 @@ launch_in_ci:
|
||||
- PhantomJS
|
||||
launchers:
|
||||
Mocha:
|
||||
command: npm test
|
||||
command: make node-tests
|
||||
|
||||
Reference in New Issue
Block a user