From 1fe7702430548c00a3096f639e32eb3acb0bba7c Mon Sep 17 00:00:00 2001 From: Matthew Dillon Date: Thu, 12 Nov 2015 06:36:22 -0700 Subject: [PATCH] ember-cli 1.13.11 --- .watchmanconfig | 2 +- app/app.js | 4 ++-- app/router.js | 2 +- bower.json | 16 +++++++-------- config/environment.js | 2 ++ ember-cli-build.js | 1 + package.json | 28 +++++++++++++------------- tests/helpers/destroy-app.js | 5 +++++ tests/helpers/module-for-acceptance.js | 23 +++++++++++++++++++++ tests/helpers/resolver.js | 2 +- tests/helpers/start-app.js | 6 +++--- tests/index.html | 5 +++-- 12 files changed, 64 insertions(+), 32 deletions(-) create mode 100644 tests/helpers/destroy-app.js create mode 100644 tests/helpers/module-for-acceptance.js diff --git a/.watchmanconfig b/.watchmanconfig index 5e9462c..e7834e3 100644 --- a/.watchmanconfig +++ b/.watchmanconfig @@ -1,3 +1,3 @@ { - "ignore_dirs": ["tmp"] + "ignore_dirs": ["tmp", "dist"] } diff --git a/app/app.js b/app/app.js index 8d66b95..8b234d6 100644 --- a/app/app.js +++ b/app/app.js @@ -3,14 +3,14 @@ import Resolver from 'ember/resolver'; import loadInitializers from 'ember/load-initializers'; import config from './config/environment'; -var App; +let App; Ember.MODEL_FACTORY_INJECTIONS = true; App = Ember.Application.extend({ modulePrefix: config.modulePrefix, podModulePrefix: config.podModulePrefix, - Resolver: Resolver + Resolver }); loadInitializers(App, config.modulePrefix); diff --git a/app/router.js b/app/router.js index f5cc4af..13b6c88 100644 --- a/app/router.js +++ b/app/router.js @@ -1,7 +1,7 @@ import Ember from 'ember'; import config from './config/environment'; -var Router = Ember.Router.extend({ +const Router = Ember.Router.extend({ location: config.locationType }); diff --git a/bower.json b/bower.json index 0c58bd9..db98942 100644 --- a/bower.json +++ b/bower.json @@ -3,15 +3,15 @@ "dependencies": { "jquery": "~2.1.1", "ember": "1.13.10", - "ember-cli-shims": "ember-cli/ember-cli-shims#0.0.3", - "ember-cli-test-loader": "ember-cli-test-loader#0.1.3", - "ember-data": "1.13.13", - "ember-load-initializers": "ember-cli/ember-load-initializers#0.1.5", - "ember-qunit": "0.4.9", - "ember-qunit-notifications": "0.0.7", - "ember-resolver": "~0.1.18", + "ember-cli-shims": "0.0.6", + "ember-cli-test-loader": "0.2.1", + "ember-data": "1.13.15", + "ember-load-initializers": "0.1.7", + "ember-qunit": "0.4.16", + "ember-qunit-notifications": "0.1.0", + "ember-resolver": "~0.1.20", "loader.js": "ember-cli/loader.js#3.2.1", - "qunit": "~1.18.0", + "qunit": "~1.20.0", "flakes": "~1.0.0", "moment": "~2.10.6", "select2": "3.5.2", diff --git a/config/environment.js b/config/environment.js index 6351cb1..752e4c9 100644 --- a/config/environment.js +++ b/config/environment.js @@ -37,6 +37,8 @@ module.exports = function(environment) { ENV.APP.LOG_ACTIVE_GENERATION = false; ENV.APP.LOG_VIEW_LOOKUPS = false; ENV.locationType = 'none'; + ENV.baseURL = '/'; + ENV.APP.rootElement = '#ember-testing'; } if (environment === 'staging') { diff --git a/ember-cli-build.js b/ember-cli-build.js index 995161c..3ae8de0 100644 --- a/ember-cli-build.js +++ b/ember-cli-build.js @@ -1,3 +1,4 @@ +/*jshint node:true*/ /* global require, module */ var EmberApp = require('ember-cli/lib/broccoli/ember-app'); diff --git a/package.json b/package.json index 9b901cb..6925274 100644 --- a/package.json +++ b/package.json @@ -19,25 +19,25 @@ "author": "", "license": "MIT", "devDependencies": { - "broccoli-asset-rev": "^2.1.2", - "ember-cli": "1.13.8", - "ember-cli-app-version": "0.5.0", - "ember-cli-babel": "^5.1.3", - "ember-cli-dependency-checker": "^1.0.1", - "ember-cli-divshot": "^0.1.7", + "broccoli-asset-rev": "^2.2.0", + "ember-cli": "1.13.11", + "ember-cli-app-version": "^1.0.0", + "ember-cli-babel": "^5.1.5", + "ember-cli-content-security-policy": "0.4.0", + "ember-cli-dependency-checker": "^1.1.0", "ember-cli-flash": "1.3.6", - "ember-cli-htmlbars": "0.7.9", - "ember-cli-htmlbars-inline-precompile": "^0.2.0", + "ember-cli-htmlbars": "^1.0.1", + "ember-cli-htmlbars-inline-precompile": "^0.3.1", "ember-cli-ic-ajax": "0.2.1", "ember-cli-inject-live-reload": "^1.3.1", "ember-cli-mirage": "0.1.11", - "ember-cli-qunit": "^1.0.0", - "ember-cli-release": "0.2.3", - "ember-cli-sri": "^1.0.3", + "ember-cli-qunit": "^1.0.4", + "ember-cli-release": "0.2.8", + "ember-cli-sri": "^1.1.0", "ember-cli-uglify": "^1.2.0", - "ember-data": "1.13.13", - "ember-disable-proxy-controllers": "^1.0.0", - "ember-export-application-global": "^1.0.3", + "ember-data": "1.13.15", + "ember-disable-proxy-controllers": "^1.0.1", + "ember-export-application-global": "^1.0.4", "ember-one-way-input": "0.1.3", "ember-select-2": "1.3.0", "ember-simple-auth": "1.0.0" diff --git a/tests/helpers/destroy-app.js b/tests/helpers/destroy-app.js new file mode 100644 index 0000000..c3d4d1a --- /dev/null +++ b/tests/helpers/destroy-app.js @@ -0,0 +1,5 @@ +import Ember from 'ember'; + +export default function destroyApp(application) { + Ember.run(application, 'destroy'); +} diff --git a/tests/helpers/module-for-acceptance.js b/tests/helpers/module-for-acceptance.js new file mode 100644 index 0000000..ed23003 --- /dev/null +++ b/tests/helpers/module-for-acceptance.js @@ -0,0 +1,23 @@ +import { module } from 'qunit'; +import startApp from '../helpers/start-app'; +import destroyApp from '../helpers/destroy-app'; + +export default function(name, options = {}) { + module(name, { + beforeEach() { + this.application = startApp(); + + if (options.beforeEach) { + options.beforeEach.apply(this, arguments); + } + }, + + afterEach() { + destroyApp(this.application); + + if (options.afterEach) { + options.afterEach.apply(this, arguments); + } + } + }); +} diff --git a/tests/helpers/resolver.js b/tests/helpers/resolver.js index 28f4ece..ebfb4e4 100644 --- a/tests/helpers/resolver.js +++ b/tests/helpers/resolver.js @@ -1,7 +1,7 @@ import Resolver from 'ember/resolver'; import config from '../../config/environment'; -var resolver = Resolver.create(); +const resolver = Resolver.create(); resolver.namespace = { modulePrefix: config.modulePrefix, diff --git a/tests/helpers/start-app.js b/tests/helpers/start-app.js index 0f7aab1..e098f1d 100644 --- a/tests/helpers/start-app.js +++ b/tests/helpers/start-app.js @@ -3,12 +3,12 @@ import Application from '../../app'; import config from '../../config/environment'; export default function startApp(attrs) { - var application; + let application; - var attributes = Ember.merge({}, config.APP); + let attributes = Ember.merge({}, config.APP); attributes = Ember.merge(attributes, attrs); // use defaults, but you can override; - Ember.run(function() { + Ember.run(() => { application = Application.create(attributes); application.setupForTesting(); application.injectTestHelpers(); diff --git a/tests/index.html b/tests/index.html index 648f884..de2e29b 100644 --- a/tests/index.html +++ b/tests/index.html @@ -18,13 +18,14 @@ {{content-for 'test-head-footer'}} - {{content-for 'body'}} {{content-for 'test-body'}} + - + + {{content-for 'body-footer'}}