diff --git a/Gruntfile.js b/Gruntfile.js index 77b537e2bc..88770f40e2 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -319,6 +319,11 @@ var _ = require('lodash'), return './node_modules/.bin/ember build --environment=production --silent' case 'dev': + return './node_modules/.bin/ember build --silent'; + + case 'test': + return './node_modules/.bin/ember test --silent'; + default: return './node_modules/.bin/ember build --silent'; } @@ -341,14 +346,6 @@ var _ = require('lodash'), } }, - testem: { - command: path.resolve(cwd + '/node_modules/.bin/testem ci -f core/test/client/testem.json'), - options: { - stdout: true, - stdin: false - } - }, - test: { command: function (test) { return 'node ' + mochaPath + ' --timeout=15000 --ui=bdd --reporter=spec core/test/' + test; @@ -631,8 +628,12 @@ var _ = require('lodash'), // details of each of the test suites. // grunt.registerTask('test-all', 'Run tests and lint code', +<<<<<<< HEAD ['lint', 'test-routes', 'test-module', 'test-unit', 'test-integration', 'test-functional', 'shell:testem'] ); +======= + ['jshint', 'jscs', 'test-routes', 'test-module', 'test-unit', 'test-integration', 'shell:ember:test', 'test-functional']); +>>>>>>> Set up tests for ember-cli // ### Lint // diff --git a/core/client/package.json b/core/client/package.json index fd3e8fb094..c1482af555 100644 --- a/core/client/package.json +++ b/core/client/package.json @@ -30,7 +30,7 @@ "ember-cli-htmlbars": "^0.7.4", "ember-cli-ic-ajax": "0.1.1", "ember-cli-inject-live-reload": "^1.3.0", - "ember-cli-qunit": "0.3.7", + "ember-cli-mocha": "^0.4.2", "ember-cli-sass": "3.1.0-beta", "ember-cli-uglify": "1.0.1", "ember-data": "1.0.0-beta.14.1", diff --git a/core/client/tests/test-helper.js b/core/client/tests/test-helper.js index e6cfb70fe8..bbe42fab27 100644 --- a/core/client/tests/test-helper.js +++ b/core/client/tests/test-helper.js @@ -1,6 +1,4 @@ import resolver from './helpers/resolver'; -import { - setResolver -} from 'ember-qunit'; +import { setResolver } from 'ember-mocha'; setResolver(resolver); diff --git a/core/test/client/unit/components/gh-trim-focus-input_test.js b/core/client/tests/unit/components/gh-trim-focus-input_test.js similarity index 100% rename from core/test/client/unit/components/gh-trim-focus-input_test.js rename to core/client/tests/unit/components/gh-trim-focus-input_test.js diff --git a/core/test/client/unit/components/gh-url-preview_test.js b/core/client/tests/unit/components/gh-url-preview_test.js similarity index 100% rename from core/test/client/unit/components/gh-url-preview_test.js rename to core/client/tests/unit/components/gh-url-preview_test.js diff --git a/core/test/client/unit/controllers/post-settings-menu_test.js b/core/client/tests/unit/controllers/post-settings-menu_test.js similarity index 100% rename from core/test/client/unit/controllers/post-settings-menu_test.js rename to core/client/tests/unit/controllers/post-settings-menu_test.js diff --git a/core/test/client/unit/controllers/settings-general_test.js b/core/client/tests/unit/controllers/settings-general_test.js similarity index 100% rename from core/test/client/unit/controllers/settings-general_test.js rename to core/client/tests/unit/controllers/settings-general_test.js diff --git a/core/test/client/unit/models/post_test.js b/core/client/tests/unit/models/post_test.js similarity index 100% rename from core/test/client/unit/models/post_test.js rename to core/client/tests/unit/models/post_test.js diff --git a/core/test/client/unit/models/role_test.js b/core/client/tests/unit/models/role_test.js similarity index 100% rename from core/test/client/unit/models/role_test.js rename to core/client/tests/unit/models/role_test.js diff --git a/core/test/client/unit/models/setting_test.js b/core/client/tests/unit/models/setting_test.js similarity index 100% rename from core/test/client/unit/models/setting_test.js rename to core/client/tests/unit/models/setting_test.js diff --git a/core/test/client/unit/models/tag_test.js b/core/client/tests/unit/models/tag_test.js similarity index 100% rename from core/test/client/unit/models/tag_test.js rename to core/client/tests/unit/models/tag_test.js diff --git a/core/test/client/unit/models/user_test.js b/core/client/tests/unit/models/user_test.js similarity index 100% rename from core/test/client/unit/models/user_test.js rename to core/client/tests/unit/models/user_test.js diff --git a/core/test/client/unit/utils/ghost-paths_test.js b/core/client/tests/unit/utils/ghost-paths_test.js similarity index 100% rename from core/test/client/unit/utils/ghost-paths_test.js rename to core/client/tests/unit/utils/ghost-paths_test.js