From bee4fe08a60451777ef2d048964402fd361587ef Mon Sep 17 00:00:00 2001 From: Travis Hoover Date: Mon, 22 Mar 2021 12:21:02 -0700 Subject: [PATCH] add embroider test suite --- config/ember-try.js | 5 ++++- ember-cli-build.js | 3 ++- package.json | 1 + yarn.lock | 8 ++++++++ 4 files changed, 15 insertions(+), 2 deletions(-) diff --git a/config/ember-try.js b/config/ember-try.js index 2835054d..1b5c2b9d 100644 --- a/config/ember-try.js +++ b/config/ember-try.js @@ -3,6 +3,7 @@ /* eslint-env node */ const getChannelURL = require('ember-source-channel-url'); +const { embroiderSafe, embroiderOptimized } = require('@embroider/test-setup'); module.exports = function() { return Promise.all([ @@ -44,7 +45,9 @@ module.exports = function() { npm: { devDependencies: {} } - } + }, + embroiderSafe(), + embroiderOptimized(), ] }; }); diff --git a/ember-cli-build.js b/ember-cli-build.js index 11edd19e..3bc590cd 100644 --- a/ember-cli-build.js +++ b/ember-cli-build.js @@ -24,5 +24,6 @@ module.exports = function(defaults) { behave. You most likely want to be modifying `./index.js` or app's build file */ - return app.toTree(); + const { maybeEmbroider } = require('@embroider/test-setup'); + return maybeEmbroider(app); }; diff --git a/package.json b/package.json index 77749751..8ef0c405 100644 --- a/package.json +++ b/package.json @@ -31,6 +31,7 @@ }, "devDependencies": { "@babel/core": "^7.13.10", + "@embroider/test-setup": "^0.37.0", "broccoli-stew": "^3.0.0", "ember-cli": "~3.22.0", "ember-cli-dependency-checker": "^3.2.0", diff --git a/yarn.lock b/yarn.lock index 5e8e9282..f8cf640e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1104,6 +1104,14 @@ ember-cli-htmlbars-inline-precompile "^2.1.0" ember-test-waiters "^1.1.1" +"@embroider/test-setup@^0.37.0": + version "0.37.0" + resolved "https://registry.yarnpkg.com/@embroider/test-setup/-/test-setup-0.37.0.tgz#4c0590c8c3e45813dd53b8b551206acd0a49cefd" + integrity sha512-4jme5zEonjGvKeyVRygyXmooMuwmaa3nBiIxwbkRA6KWh0BLyZSqPwlQl93s7IT7S5PO5U9TqNiqI4yp2k5T7Q== + dependencies: + lodash "^4.17.20" + resolve "^1.17.0" + "@eslint/eslintrc@^0.4.0": version "0.4.0" resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-0.4.0.tgz#99cc0a0584d72f1df38b900fb062ba995f395547"