diff --git a/addons/auth/.eslintcache b/addons/auth/.eslintcache deleted file mode 100644 index c6163907a..000000000 --- a/addons/auth/.eslintcache +++ /dev/null @@ -1 +0,0 @@ -[{"/Users/randallmorey/git/boundary-ui/addons/auth/.eslintrc.js":"1","/Users/randallmorey/git/boundary-ui/addons/auth/.prettierrc.js":"2","/Users/randallmorey/git/boundary-ui/addons/auth/.template-lintrc.js":"3","/Users/randallmorey/git/boundary-ui/addons/auth/addon/authenticators/base.js":"4","/Users/randallmorey/git/boundary-ui/addons/auth/addon/authenticators/password.js":"5","/Users/randallmorey/git/boundary-ui/addons/auth/addon/session-stores/cookie.js":"6","/Users/randallmorey/git/boundary-ui/addons/auth/addon/session-stores/local-storage.js":"7","/Users/randallmorey/git/boundary-ui/addons/auth/config/ember-try.js":"8","/Users/randallmorey/git/boundary-ui/addons/auth/config/environment.js":"9","/Users/randallmorey/git/boundary-ui/addons/auth/ember-cli-build.js":"10","/Users/randallmorey/git/boundary-ui/addons/auth/index.js":"11","/Users/randallmorey/git/boundary-ui/addons/auth/testem.js":"12","/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/app/app.js":"13","/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/app/authenticators/base.js":"14","/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/app/authenticators/password.js":"15","/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/app/router.js":"16","/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/app/session-stores/cookie.js":"17","/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/app/session-stores/local-storage.js":"18","/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/config/environment.js":"19","/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/config/targets.js":"20","/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/mirage/config.js":"21","/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/mirage/scenarios/default.js":"22","/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/mirage/serializers/application.js":"23","/Users/randallmorey/git/boundary-ui/addons/auth/tests/test-helper.js":"24","/Users/randallmorey/git/boundary-ui/addons/auth/tests/unit/authenticators/base-test.js":"25","/Users/randallmorey/git/boundary-ui/addons/auth/tests/unit/authenticators/password-test.js":"26","/Users/randallmorey/git/boundary-ui/addons/auth/tests/unit/session-stores/cookie-test.js":"27"},{"size":1261,"mtime":1614968222345,"results":"28","hashOfConfig":"29"},{"size":58,"mtime":1614968153726,"results":"30","hashOfConfig":"29"},{"size":58,"mtime":1614968153727,"results":"31","hashOfConfig":"29"},{"size":2748,"mtime":1614968229848,"results":"32","hashOfConfig":"29"},{"size":2958,"mtime":1614968229863,"results":"33","hashOfConfig":"29"},{"size":4392,"mtime":1614968506425,"results":"34","hashOfConfig":"29"},{"size":694,"mtime":1605716837136,"results":"35","hashOfConfig":"29"},{"size":1686,"mtime":1614968189649,"results":"36","hashOfConfig":"29"},{"size":90,"mtime":1605716837137,"results":"37","hashOfConfig":"29"},{"size":495,"mtime":1605716837137,"results":"38","hashOfConfig":"29"},{"size":72,"mtime":1605716837137,"results":"39","hashOfConfig":"29"},{"size":681,"mtime":1614968201726,"results":"40","hashOfConfig":"29"},{"size":388,"mtime":1605716837138,"results":"41","hashOfConfig":"29"},{"size":277,"mtime":1609793139529,"results":"42","hashOfConfig":"29"},{"size":353,"mtime":1605716837138,"results":"43","hashOfConfig":"29"},{"size":240,"mtime":1605716837139,"results":"44","hashOfConfig":"29"},{"size":192,"mtime":1605716837139,"results":"45","hashOfConfig":"29"},{"size":168,"mtime":1605716837139,"results":"46","hashOfConfig":"29"},{"size":1242,"mtime":1605716837140,"results":"47","hashOfConfig":"29"},{"size":314,"mtime":1605716837140,"results":"48","hashOfConfig":"29"},{"size":763,"mtime":1605716837141,"results":"49","hashOfConfig":"29"},{"size":194,"mtime":1605716837141,"results":"50","hashOfConfig":"29"},{"size":100,"mtime":1605716837141,"results":"51","hashOfConfig":"29"},{"size":323,"mtime":1614968153728,"results":"52","hashOfConfig":"29"},{"size":2786,"mtime":1614968230015,"results":"53","hashOfConfig":"29"},{"size":2520,"mtime":1609793139530,"results":"54","hashOfConfig":"29"},{"size":2789,"mtime":1605716837143,"results":"55","hashOfConfig":"29"},{"filePath":"56","messages":"57","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"2hgbsh",{"filePath":"58","messages":"59","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"60","messages":"61","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"62","messages":"63","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"64","messages":"65","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"66","messages":"67","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"68","messages":"69","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"70","messages":"71","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"72","messages":"73","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"74","messages":"75","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"76","messages":"77","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"78","messages":"79","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"80","messages":"81","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"82","messages":"83","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"84","messages":"85","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"86","messages":"87","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"88","messages":"89","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"90","messages":"91","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"92","messages":"93","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"94","messages":"95","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"96","messages":"97","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"98","messages":"99","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"100","messages":"101","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"102","messages":"103","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"104","messages":"105","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"106","messages":"107","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"108","messages":"109","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"/Users/randallmorey/git/boundary-ui/addons/auth/.eslintrc.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/.prettierrc.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/.template-lintrc.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/addon/authenticators/base.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/addon/authenticators/password.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/addon/session-stores/cookie.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/addon/session-stores/local-storage.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/config/ember-try.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/config/environment.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/ember-cli-build.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/index.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/testem.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/app/app.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/app/authenticators/base.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/app/authenticators/password.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/app/router.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/app/session-stores/cookie.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/app/session-stores/local-storage.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/config/environment.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/config/targets.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/mirage/config.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/mirage/scenarios/default.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/dummy/mirage/serializers/application.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/test-helper.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/unit/authenticators/base-test.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/unit/authenticators/password-test.js",[],"/Users/randallmorey/git/boundary-ui/addons/auth/tests/unit/session-stores/cookie-test.js",[]] \ No newline at end of file diff --git a/addons/auth/.travis.yml b/addons/auth/.travis.yml deleted file mode 100644 index 156fd25fa..000000000 --- a/addons/auth/.travis.yml +++ /dev/null @@ -1,59 +0,0 @@ ---- -language: node_js -node_js: - # we recommend testing addons with the same minimum supported node version as Ember CLI - # so that your addon works for all apps - - "10" - -dist: xenial - -addons: - chrome: stable - -cache: - directories: - - $HOME/.npm - -env: - global: - # See https://git.io/vdao3 for details. - - JOBS=1 - -branches: - only: - - master - # npm version tags - - /^v\d+\.\d+\.\d+/ - -jobs: - fast_finish: true - allow_failures: - - env: EMBER_TRY_SCENARIO=ember-canary - - include: - # runs linting and tests with current locked deps - - stage: "Tests" - name: "Tests" - script: - - npm run lint - - npm run test:ember - - - stage: "Additional Tests" - name: "Floating Dependencies" - install: - - npm install --no-package-lock - script: - - npm run test:ember - - # we recommend new addons test the current and previous LTS - # as well as latest stable release (bonus points to beta/canary) - - env: EMBER_TRY_SCENARIO=ember-lts-3.16 - - env: EMBER_TRY_SCENARIO=ember-lts-3.20 - - env: EMBER_TRY_SCENARIO=ember-release - - env: EMBER_TRY_SCENARIO=ember-beta - - env: EMBER_TRY_SCENARIO=ember-canary - - env: EMBER_TRY_SCENARIO=ember-default-with-jquery - - env: EMBER_TRY_SCENARIO=ember-classic - -script: - - node_modules/.bin/ember try:one $EMBER_TRY_SCENARIO diff --git a/addons/auth/package.json b/addons/auth/package.json index 0746d866d..a1bdbc248 100644 --- a/addons/auth/package.json +++ b/addons/auth/package.json @@ -11,7 +11,7 @@ "lint": "npm-run-all --aggregate-output --continue-on-error --parallel 'lint:!(fix)'", "lint:fix": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*:fix", "lint:hbs:fix": "ember-template-lint . --fix", - "lint:js": "eslint . --cache", + "lint:js": "eslint .", "format": "npm run format:js", "format:js": "prettier --write '{addon,app,config,stories,tests}/**/*.js' *.js", "lint:js:fix": "eslint . --fix", diff --git a/addons/core/.eslintignore b/addons/core/.eslintignore index 72df37307..922165552 100644 --- a/addons/core/.eslintignore +++ b/addons/core/.eslintignore @@ -13,6 +13,7 @@ # misc /coverage/ !.* +.eslintcache # ember-try /.node_modules.ember-try/ diff --git a/addons/core/.eslintrc.js b/addons/core/.eslintrc.js index 928585995..49fb14100 100644 --- a/addons/core/.eslintrc.js +++ b/addons/core/.eslintrc.js @@ -7,48 +7,54 @@ module.exports = { ecmaVersion: 2018, sourceType: 'module', ecmaFeatures: { - legacyDecorators: true - } + legacyDecorators: true, + }, }, - plugins: [ - 'ember' - ], + plugins: ['ember'], extends: [ 'eslint:recommended', - 'plugin:ember/recommended' + 'plugin:ember/recommended', + 'plugin:prettier/recommended', ], env: { - browser: true + browser: true, + }, + rules: { + 'ember/no-get': 'off', + 'ember/no-get-with-default': 'off', + 'ember/no-computed-properties-in-native-classes': 'off', + 'ember/no-assignment-of-untracked-properties-used-in-tracking-contexts': + 'off', }, - rules: {}, overrides: [ // node files { files: [ '.eslintrc.js', + '.prettierrc.js', '.template-lintrc.js', 'ember-cli-build.js', 'index.js', 'testem.js', 'blueprints/*/index.js', 'config/**/*.js', - 'tests/dummy/config/**/*.js' + 'tests/dummy/config/**/*.js', ], excludedFiles: [ 'addon/**', 'addon-test-support/**', 'app/**', - 'tests/dummy/app/**' + 'tests/dummy/app/**', ], parserOptions: { - sourceType: 'script' + sourceType: 'script', }, env: { browser: false, - node: true + node: true, }, plugins: ['node'], - extends: ['plugin:node/recommended'] - } - ] + extends: ['plugin:node/recommended'], + }, + ], }; diff --git a/addons/core/.npmignore b/addons/core/.npmignore index bd09adff9..88818f2c8 100644 --- a/addons/core/.npmignore +++ b/addons/core/.npmignore @@ -10,6 +10,7 @@ /.editorconfig /.ember-cli /.env* +/.eslintcache /.eslintignore /.eslintrc.js /.git/ diff --git a/addons/core/.prettierignore b/addons/core/.prettierignore new file mode 100644 index 000000000..922165552 --- /dev/null +++ b/addons/core/.prettierignore @@ -0,0 +1,21 @@ +# unconventional js +/blueprints/*/files/ +/vendor/ + +# compiled output +/dist/ +/tmp/ + +# dependencies +/bower_components/ +/node_modules/ + +# misc +/coverage/ +!.* +.eslintcache + +# ember-try +/.node_modules.ember-try/ +/bower.json.ember-try +/package.json.ember-try diff --git a/addons/core/.prettierrc.js b/addons/core/.prettierrc.js new file mode 100644 index 000000000..534e6d35a --- /dev/null +++ b/addons/core/.prettierrc.js @@ -0,0 +1,5 @@ +'use strict'; + +module.exports = { + singleQuote: true, +}; diff --git a/addons/core/.template-lintrc.js b/addons/core/.template-lintrc.js index f38737001..3b0b9af95 100644 --- a/addons/core/.template-lintrc.js +++ b/addons/core/.template-lintrc.js @@ -1,5 +1,5 @@ 'use strict'; module.exports = { - extends: 'octane' + extends: 'octane', }; diff --git a/addons/core/README.md b/addons/core/README.md index 3b913d4d3..ad29fbe9e 100644 --- a/addons/core/README.md +++ b/addons/core/README.md @@ -112,7 +112,7 @@ async myAction() { This addon exposes a service to hold all active scopes (org and project where available). -To make use of the service, import it and initialize it using service injection. +To make use of the service, import it and initialize it using service injection. ```js import { inject as service } from '@ember/service'; diff --git a/addons/core/addon/decorators/notify.js b/addons/core/addon/decorators/notify.js index 1ce13d91e..21c5b7f47 100644 --- a/addons/core/addon/decorators/notify.js +++ b/addons/core/addon/decorators/notify.js @@ -51,14 +51,14 @@ export function notifyError(notification, options = { catch: false }) { const owner = getOwner(this); const notifyService = owner.lookup('service:notify'); const intlService = owner.lookup('service:intl'); - + try { return await method.apply(this, arguments); } catch (error) { - - const candidateKey = (typeof notification === 'function') - ? notification.apply(this, [error]) - : notification; + const candidateKey = + typeof notification === 'function' + ? notification.apply(this, [error]) + : notification; const text = intlService.exists(candidateKey) ? intlService.t(candidateKey) diff --git a/addons/core/app/components/error/message.js b/addons/core/app/components/error/message.js index 055e64811..4cea9812f 100644 --- a/addons/core/app/components/error/message.js +++ b/addons/core/app/components/error/message.js @@ -1 +1 @@ -export { default } from 'core/components/error/message'; \ No newline at end of file +export { default } from 'core/components/error/message'; diff --git a/addons/core/app/components/form/authenticate.js b/addons/core/app/components/form/authenticate.js index f471115c1..85004b271 100644 --- a/addons/core/app/components/form/authenticate.js +++ b/addons/core/app/components/form/authenticate.js @@ -1 +1 @@ -export { default } from 'core/components/form/authenticate'; \ No newline at end of file +export { default } from 'core/components/form/authenticate'; diff --git a/addons/core/app/components/form/authenticate/password.js b/addons/core/app/components/form/authenticate/password.js index ec54f0464..f8be6bacb 100644 --- a/addons/core/app/components/form/authenticate/password.js +++ b/addons/core/app/components/form/authenticate/password.js @@ -1 +1 @@ -export { default } from 'core/components/form/authenticate/password'; \ No newline at end of file +export { default } from 'core/components/form/authenticate/password'; diff --git a/addons/core/app/components/pending-confirmations.js b/addons/core/app/components/pending-confirmations.js index 7e60dd82a..6652a5c5e 100644 --- a/addons/core/app/components/pending-confirmations.js +++ b/addons/core/app/components/pending-confirmations.js @@ -1 +1 @@ -export { default } from 'core/components/pending-confirmations'; \ No newline at end of file +export { default } from 'core/components/pending-confirmations'; diff --git a/addons/core/app/helpers/format-date-iso-human.js b/addons/core/app/helpers/format-date-iso-human.js index b4586dc3d..947f5e926 100644 --- a/addons/core/app/helpers/format-date-iso-human.js +++ b/addons/core/app/helpers/format-date-iso-human.js @@ -1 +1,4 @@ -export { default, formatDateIsoHuman } from 'core/helpers/format-date-iso-human'; +export { + default, + formatDateIsoHuman, +} from 'core/helpers/format-date-iso-human'; diff --git a/addons/core/config/ember-try.js b/addons/core/config/ember-try.js index bbdb66252..f14ac7f50 100644 --- a/addons/core/config/ember-try.js +++ b/addons/core/config/ember-try.js @@ -1,84 +1,76 @@ -"use strict"; +'use strict'; -const getChannelURL = require("ember-source-channel-url"); +const getChannelURL = require('ember-source-channel-url'); module.exports = async function () { return { useYarn: true, scenarios: [ { - name: "ember-lts-3.12", + name: 'ember-lts-3.16', npm: { devDependencies: { - "ember-source": "~3.12.0", + 'ember-source': '~3.16.0', }, }, }, { - name: "ember-lts-3.16", + name: 'ember-lts-3.20', npm: { devDependencies: { - "ember-source": "~3.16.0", + 'ember-source': '~3.20.5', }, }, }, { - name: "ember-lts-3.20", + name: 'ember-release', npm: { devDependencies: { - "ember-source": "~3.20.5", + 'ember-source': await getChannelURL('release'), }, }, }, { - name: "ember-release", + name: 'ember-beta', npm: { devDependencies: { - "ember-source": await getChannelURL("release"), + 'ember-source': await getChannelURL('beta'), }, }, }, { - name: "ember-beta", + name: 'ember-canary', npm: { devDependencies: { - "ember-source": await getChannelURL("beta"), + 'ember-source': await getChannelURL('canary'), }, }, }, { - name: "ember-canary", - npm: { - devDependencies: { - "ember-source": await getChannelURL("canary"), - }, - }, - }, - { - name: "ember-default-with-jquery", + name: 'ember-default-with-jquery', env: { EMBER_OPTIONAL_FEATURES: JSON.stringify({ - "jquery-integration": true, + 'jquery-integration': true, }), }, npm: { devDependencies: { - "@ember/jquery": "^1.1.0", + '@ember/jquery': '^1.1.0', }, }, }, { - name: "ember-classic", + name: 'ember-classic', env: { EMBER_OPTIONAL_FEATURES: JSON.stringify({ - "application-template-wrapper": true, - "default-async-observers": false, - "template-only-glimmer-components": false, + 'application-template-wrapper': true, + 'default-async-observers': false, + 'template-only-glimmer-components': false, }), }, npm: { ember: { - edition: "classic", + edition: 'classic', }, }, }, diff --git a/addons/core/config/environment.js b/addons/core/config/environment.js index b7238585e..331ab30df 100644 --- a/addons/core/config/environment.js +++ b/addons/core/config/environment.js @@ -1,4 +1,4 @@ -"use strict"; +'use strict'; module.exports = function (/* environment, appConfig */) { return {}; diff --git a/addons/core/ember-cli-build.js b/addons/core/ember-cli-build.js index b6a8f26a0..ba0649dc9 100644 --- a/addons/core/ember-cli-build.js +++ b/addons/core/ember-cli-build.js @@ -1,6 +1,6 @@ -"use strict"; +'use strict'; -const EmberAddon = require("ember-cli/lib/broccoli/ember-addon"); +const EmberAddon = require('ember-cli/lib/broccoli/ember-addon'); module.exports = function (defaults) { let app = new EmberAddon(defaults, { diff --git a/addons/core/index.js b/addons/core/index.js index 245249bda..fa6be2662 100644 --- a/addons/core/index.js +++ b/addons/core/index.js @@ -1,4 +1,4 @@ -"use strict"; +'use strict'; module.exports = { - name: require("./package").name, + name: require('./package').name, }; diff --git a/addons/core/package.json b/addons/core/package.json index d5e613ea4..63edf135d 100644 --- a/addons/core/package.json +++ b/addons/core/package.json @@ -15,10 +15,13 @@ "scripts": { "build:development": "ember build", "build": "ember build --environment=production", - "lint": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*", + "lint": "npm-run-all --aggregate-output --continue-on-error --parallel 'lint:!(fix)'", + "lint:fix": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*:fix", + "lint:hbs:fix": "ember-template-lint . --fix", "lint:js": "eslint .", "format": "npm run format:js", "format:js": "prettier --write '{addon,app,config,stories,tests}/**/*.js' *.js", + "lint:js:fix": "eslint . --fix", "start": "ember serve", "test": "ember test", "test:ember-compatibility": "ember try:each", @@ -27,8 +30,8 @@ "dependencies": { "api": "*", "auth": "*", - "ember-cli-babel": "^7.21.0", - "ember-cli-htmlbars": "^5.2.0", + "ember-cli-babel": "^7.23.0", + "ember-cli-htmlbars": "^5.3.1", "ember-get-config": "^0.3.0", "ember-intl": "^5.5.0", "ember-loading": "^0.4.0", @@ -37,38 +40,43 @@ "rose": "*" }, "devDependencies": { - "@ember/optional-features": "^1.3.0", - "@glimmer/component": "^1.0.1", - "@glimmer/tracking": "^1.0.0", + "@ember/optional-features": "^2.0.0", + "@ember/test-helpers": "^2.1.4", + "@glimmer/component": "^1.0.3", + "@glimmer/tracking": "^1.0.3", "babel-eslint": "^10.1.0", "broccoli-asset-rev": "^3.0.0", "doctoc": "^1.4.0", - "ember-auto-import": "^1.6.0", - "ember-cli": "~3.20.2", + "ember-auto-import": "^1.10.1", + "ember-cli": "~3.24.0", "ember-cli-dependency-checker": "^3.2.0", "ember-cli-inject-live-reload": "^2.0.2", "ember-cli-sri": "^2.1.1", - "ember-cli-uglify": "^3.0.0", + "ember-cli-terser": "^4.0.1", "ember-disable-prototype-extensions": "^1.1.3", "ember-export-application-global": "^2.0.1", "ember-inline-svg": "^1.0.0", "ember-intl": "^5.5.0", - "ember-load-initializers": "^2.1.1", + "ember-load-initializers": "^2.1.2", "ember-maybe-import-regenerator": "^0.1.6", - "ember-qunit": "^4.6.0", - "ember-resolver": "^8.0.0", - "ember-source": "~3.20.2", - "ember-source-channel-url": "^2.0.1", - "ember-template-lint": "^2.9.1", + "ember-page-title": "^6.0.3", + "ember-qunit": "^5.1.1", + "ember-resolver": "^8.0.2", + "ember-source": "~3.24.0", + "ember-source-channel-url": "^3.0.0", + "ember-template-lint": "^2.15.0", "ember-try": "^1.4.0", - "eslint": "^7.5.0", - "eslint-plugin-ember": "^8.9.1", + "eslint": "^7.17.0", + "eslint-config-prettier": "^7.1.0", + "eslint-plugin-ember": "^10.1.1", "eslint-plugin-node": "^11.1.0", + "eslint-plugin-prettier": "^3.3.1", "faker": "^5.1.0", "loader.js": "^4.7.0", "npm-run-all": "^4.1.5", - "prettier": "^2.1.2", - "qunit-dom": "^1.2.0" + "prettier": "^2.2.1", + "qunit": "^2.13.0", + "qunit-dom": "^1.6.0" }, "engines": { "node": "10.* || >= 12" diff --git a/addons/core/testem.js b/addons/core/testem.js index e3e8564ff..ed2f37124 100644 --- a/addons/core/testem.js +++ b/addons/core/testem.js @@ -1,22 +1,22 @@ -"use strict"; +'use strict'; module.exports = { - test_page: "tests/index.html?hidepassed", + test_page: 'tests/index.html?hidepassed', disable_watching: true, - launch_in_ci: ["Chrome"], - launch_in_dev: ["Chrome"], + launch_in_ci: ['Chrome'], + launch_in_dev: ['Chrome'], browser_start_timeout: 120, browser_args: { Chrome: { ci: [ // --no-sandbox is needed when running Chrome inside a container - process.env.CI ? "--no-sandbox" : null, - "--headless", - "--disable-dev-shm-usage", - "--disable-software-rasterizer", - "--mute-audio", - "--remote-debugging-port=0", - "--window-size=1440,900", + process.env.CI ? '--no-sandbox' : null, + '--headless', + '--disable-dev-shm-usage', + '--disable-software-rasterizer', + '--mute-audio', + '--remote-debugging-port=0', + '--window-size=1440,900', ].filter(Boolean), }, }, diff --git a/addons/core/tests/dummy/app/app.js b/addons/core/tests/dummy/app/app.js index 2ae212dbd..523bad60c 100644 --- a/addons/core/tests/dummy/app/app.js +++ b/addons/core/tests/dummy/app/app.js @@ -1,7 +1,7 @@ -import Application from "@ember/application"; -import Resolver from "ember-resolver"; -import loadInitializers from "ember-load-initializers"; -import config from "dummy/config/environment"; +import Application from '@ember/application'; +import Resolver from 'ember-resolver'; +import loadInitializers from 'ember-load-initializers'; +import config from 'dummy/config/environment'; export default class App extends Application { modulePrefix = config.modulePrefix; diff --git a/addons/core/tests/dummy/app/formats.js b/addons/core/tests/dummy/app/formats.js index 4a4add42f..f5d1f1502 100644 --- a/addons/core/tests/dummy/app/formats.js +++ b/addons/core/tests/dummy/app/formats.js @@ -1,29 +1,29 @@ export default { time: { hhmmss: { - hour: "numeric", - minute: "numeric", - second: "numeric", + hour: 'numeric', + minute: 'numeric', + second: 'numeric', }, }, date: { hhmmss: { - hour: "numeric", - minute: "numeric", - second: "numeric", + hour: 'numeric', + minute: 'numeric', + second: 'numeric', }, }, number: { - compact: { notation: "compact" }, + compact: { notation: 'compact' }, EUR: { - style: "currency", - currency: "EUR", + style: 'currency', + currency: 'EUR', minimumFractionDigits: 2, maximumFractionDigits: 2, }, USD: { - style: "currency", - currency: "USD", + style: 'currency', + currency: 'USD', minimumFractionDigits: 2, maximumFractionDigits: 2, }, diff --git a/addons/core/tests/dummy/app/router.js b/addons/core/tests/dummy/app/router.js index 018b4b1ca..64e543ab2 100644 --- a/addons/core/tests/dummy/app/router.js +++ b/addons/core/tests/dummy/app/router.js @@ -1,5 +1,5 @@ -import EmberRouter from "@ember/routing/router"; -import config from "dummy/config/environment"; +import EmberRouter from '@ember/routing/router'; +import config from 'dummy/config/environment'; export default class Router extends EmberRouter { location = config.locationType; diff --git a/addons/core/tests/dummy/config/ember-cli-update.json b/addons/core/tests/dummy/config/ember-cli-update.json index 7d2c3ace4..279e6dab9 100644 --- a/addons/core/tests/dummy/config/ember-cli-update.json +++ b/addons/core/tests/dummy/config/ember-cli-update.json @@ -3,7 +3,7 @@ "packages": [ { "name": "ember-cli", - "version": "3.20.2", + "version": "3.24.0", "blueprints": [ { "name": "addon", diff --git a/addons/core/tests/dummy/config/ember-intl.js b/addons/core/tests/dummy/config/ember-intl.js index a5a3a93d5..70719ccdc 100644 --- a/addons/core/tests/dummy/config/ember-intl.js +++ b/addons/core/tests/dummy/config/ember-intl.js @@ -25,7 +25,7 @@ module.exports = function (/* environment */) { * @type {String} * @default "'translations'" */ - inputPath: "../../translations", + inputPath: '../../translations', /** * Prevents the translations from being bundled with the application code. diff --git a/addons/core/tests/dummy/config/environment.js b/addons/core/tests/dummy/config/environment.js index 2a5061f98..dca0b66ac 100644 --- a/addons/core/tests/dummy/config/environment.js +++ b/addons/core/tests/dummy/config/environment.js @@ -1,11 +1,11 @@ -"use strict"; +'use strict'; module.exports = function (environment) { let ENV = { - modulePrefix: "dummy", + modulePrefix: 'dummy', environment, - rootURL: "/", - locationType: "auto", + rootURL: '/', + locationType: 'auto', EmberENV: { FEATURES: { // Here you can enable experimental features on an ember canary build @@ -29,7 +29,7 @@ module.exports = function (environment) { baseURL: 'https://boundaryproject.io/help/admin-ui', topics: { account: '/accounts', - } + }, }, api: { @@ -38,13 +38,13 @@ module.exports = function (environment) { }, 'ember-cli-mirage': { - directory: '../api/mirage' + directory: '../api/mirage', }, - enableConfirmService: false + enableConfirmService: false, }; - if (environment === "development") { + if (environment === 'development') { // ENV.APP.LOG_RESOLVER = true; // ENV.APP.LOG_ACTIVE_GENERATION = true; // ENV.APP.LOG_TRANSITIONS = true; @@ -52,19 +52,19 @@ module.exports = function (environment) { // ENV.APP.LOG_VIEW_LOOKUPS = true; } - if (environment === "test") { + if (environment === 'test') { // Testem prefers this... - ENV.locationType = "none"; + ENV.locationType = 'none'; // keep test console output quieter ENV.APP.LOG_ACTIVE_GENERATION = false; ENV.APP.LOG_VIEW_LOOKUPS = false; - ENV.APP.rootElement = "#ember-testing"; + ENV.APP.rootElement = '#ember-testing'; ENV.APP.autoboot = false; } - if (environment === "production") { + if (environment === 'production') { // here you can enable a production-specific feature } diff --git a/addons/core/tests/dummy/config/targets.js b/addons/core/tests/dummy/config/targets.js index 9a022efa9..4b33327e8 100644 --- a/addons/core/tests/dummy/config/targets.js +++ b/addons/core/tests/dummy/config/targets.js @@ -1,16 +1,16 @@ -"use strict"; +'use strict'; const browsers = [ - "last 1 Chrome versions", - "last 1 Firefox versions", - "last 1 Safari versions", + 'last 1 Chrome versions', + 'last 1 Firefox versions', + 'last 1 Safari versions', ]; const isCI = Boolean(process.env.CI); -const isProduction = process.env.EMBER_ENV === "production"; +const isProduction = process.env.EMBER_ENV === 'production'; if (isCI || isProduction) { - browsers.push("ie 11"); + browsers.push('ie 11'); } module.exports = { diff --git a/addons/core/tests/index.html b/addons/core/tests/index.html index 5209b8523..3eb848dbd 100644 --- a/addons/core/tests/index.html +++ b/addons/core/tests/index.html @@ -21,6 +21,13 @@ {{content-for "body"}} {{content-for "test-body"}} +
+
+
+
+
+
+ diff --git a/addons/core/tests/integration/components/error/message-test.js b/addons/core/tests/integration/components/error/message-test.js index 47651bd89..a28f3c618 100644 --- a/addons/core/tests/integration/components/error/message-test.js +++ b/addons/core/tests/integration/components/error/message-test.js @@ -60,7 +60,7 @@ module('Integration | Component | error/message', function (hooks) { ); assert.equal( find('.rose-message-description').textContent.trim(), - 'We\'re not sure what happened. Please contact your administrator or try again later.' + "We're not sure what happened. Please contact your administrator or try again later." ); }); }); diff --git a/addons/core/tests/integration/helpers/company-copyright-test.js b/addons/core/tests/integration/helpers/company-copyright-test.js index 3025f34a1..2965f90e0 100644 --- a/addons/core/tests/integration/helpers/company-copyright-test.js +++ b/addons/core/tests/integration/helpers/company-copyright-test.js @@ -10,6 +10,9 @@ module('Integration | Helper | company-copyright', function (hooks) { assert.expect(1); const currentYear = new Date().getFullYear(); await render(hbs`{{company-copyright}}`); - assert.equal(this.element.textContent.trim(), `© ${currentYear} Company Name`); + assert.equal( + this.element.textContent.trim(), + `© ${currentYear} Company Name` + ); }); }); diff --git a/addons/core/tests/test-helper.js b/addons/core/tests/test-helper.js index d71607e7e..4efd6e58a 100644 --- a/addons/core/tests/test-helper.js +++ b/addons/core/tests/test-helper.js @@ -1,8 +1,12 @@ -import Application from "dummy/app"; -import config from "dummy/config/environment"; -import { setApplication } from "@ember/test-helpers"; -import { start } from "ember-qunit"; +import Application from 'dummy/app'; +import config from 'dummy/config/environment'; +import * as QUnit from 'qunit'; +import { setApplication } from '@ember/test-helpers'; +import { setup } from 'qunit-dom'; +import { start } from 'ember-qunit'; setApplication(Application.create(config.APP)); +setup(QUnit.assert); + start();