+ `);
+
+ assert.ok(find('.ember-power-select-trigger .cool-flag-icon'), 'The custom selectedItemComponent renders with the extra.coolFlagIcon customization option triggering some state change.');
+ });
});
From bfffc23fdc0c1ecdc41bd511c9e70faffc40485a Mon Sep 17 00:00:00 2001
From: Alex DiLiberto
Date: Sat, 10 Mar 2018 20:05:07 -0500
Subject: [PATCH 02/34] Test: Add a couple missing tests for
power-select-multiple with custom components
---
.../templates/components/selected-country.hbs | 4 +--
.../customization-with-components-test.js | 34 +++++++++++++++++++
2 files changed, 36 insertions(+), 2 deletions(-)
diff --git a/tests/dummy/app/templates/components/selected-country.hbs b/tests/dummy/app/templates/components/selected-country.hbs
index ec9ae4ef9..f268ff64d 100644
--- a/tests/dummy/app/templates/components/selected-country.hbs
+++ b/tests/dummy/app/templates/components/selected-country.hbs
@@ -1,2 +1,2 @@
-
-{{select.selected.name}}
\ No newline at end of file
+
+{{select.selected.name}}
diff --git a/tests/integration/components/power-select/customization-with-components-test.js b/tests/integration/components/power-select/customization-with-components-test.js
index 5d02e3770..304ee9c8d 100644
--- a/tests/integration/components/power-select/customization-with-components-test.js
+++ b/tests/integration/components/power-select/customization-with-components-test.js
@@ -283,6 +283,40 @@ module('Integration | Component | Ember Power Select (Customization using compon
clickTrigger();
});
+ test('the power-select-multiple `optionsComponent` receives the `extra` hash', async function(assert) {
+ assert.expect(2);
+
+ this.countries = countries;
+ this.country = countries[1]; // Spain
+
+ await render(hbs`
+ {{#power-select-multiple options=countries selected=country optionsComponent="list-of-countries" onchange=(action (mut foo)) extra=(hash field='code') as |country|}}
+ {{country.code}}
+ {{/power-select-multiple}}
+ `);
+
+ clickTrigger();
+ let text = find('.ember-power-select-options').textContent.trim();
+ assert.ok(/Countries:/.test(text), 'The given component is rendered');
+ assert.ok(/3\. RU/.test(text), 'The component uses the field in the extra has to render the options');
+ });
+
+ test('the power-select-multiple `triggerComponent` receives the `extra` hash', async function(assert) {
+ assert.expect(1);
+
+ this.countries = countries;
+ this.country = countries[1]; // Spain
+
+ await render(hbs`
+ {{#power-select-multiple options=countries selected=country triggerComponent="selected-country" onchange=(action (mut foo)) extra=(hash coolFlagIcon=true) as |country|}}
+ {{country.code}}
+ {{/power-select-multiple}}
+ `);
+
+ clickTrigger();
+ assert.ok(find('.ember-power-select-trigger .cool-flag-icon'), 'The custom triggerComponent renders with the extra.coolFlagIcon customization option triggering some state change.');
+ });
+
test('the power-select-multiple `selectedItemComponent` receives the `extra` hash', async function(assert) {
assert.expect(1);
From 18f1ef1eca6a3d4f7590933d77ae61e8aff017ad Mon Sep 17 00:00:00 2001
From: Julien Palmas
Date: Wed, 28 Mar 2018 13:46:24 +0200
Subject: [PATCH 03/34] Update how-to-use-it.hbs (#1080)
typo
---
tests/dummy/app/templates/public-pages/docs/how-to-use-it.hbs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/dummy/app/templates/public-pages/docs/how-to-use-it.hbs b/tests/dummy/app/templates/public-pages/docs/how-to-use-it.hbs
index fe8b43ff5..544311b30 100644
--- a/tests/dummy/app/templates/public-pages/docs/how-to-use-it.hbs
+++ b/tests/dummy/app/templates/public-pages/docs/how-to-use-it.hbs
@@ -57,7 +57,7 @@
Updates in the selected element will update the selected value in the component as expected.
- selected (and all other options options actually) is read only. This means that selecting
+ selected (and all other options actually) is read only. This means that selecting
an element in the component won't do anything. That is a design decision and the reason why the
onchange action is mandatory. This is aligned with Ember's Data Down Actions Up (DDAU) philosophy.
- This explicit import is needed is because using css preprocessors like SASS and LESS allows you to
+ This explicit import is needed because using css preprocessors like SASS and LESS allows you to
customize the appearance of ember-power-select using variables. This is easier and generates less
code than overriding styles you don't like.
From 52538cd0252d6a45f1d5728ef318205f76d5d3cc Mon Sep 17 00:00:00 2001
From: Julien Palmas
Date: Wed, 28 Mar 2018 13:47:16 +0200
Subject: [PATCH 05/34] Update installation.hbs (#1079)
this might be a typo as well
---
tests/dummy/app/templates/public-pages/docs/installation.hbs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/dummy/app/templates/public-pages/docs/installation.hbs b/tests/dummy/app/templates/public-pages/docs/installation.hbs
index 3eed00f0a..8047c60cd 100644
--- a/tests/dummy/app/templates/public-pages/docs/installation.hbs
+++ b/tests/dummy/app/templates/public-pages/docs/installation.hbs
@@ -32,7 +32,7 @@
- When installing this though
ember install
the addon will add the snippet above
+ When installing this through
ember install
the addon will add the snippet above
automatically for you in your app.scss or app.less.
From 96448de4f377e9b50c97d363cde8ec7c464463c7 Mon Sep 17 00:00:00 2001
From: Julien Palmas
Date: Wed, 28 Mar 2018 13:47:52 +0200
Subject: [PATCH 06/34] Update action-handling.hbs (#1081)
Sorry to submit several PRs. I create them as I encounter typos.
I tried compile only one for action-handling.hbs this time tough ;-)
---
.../templates/public-pages/docs/action-handling.hbs | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/tests/dummy/app/templates/public-pages/docs/action-handling.hbs b/tests/dummy/app/templates/public-pages/docs/action-handling.hbs
index 714b697ea..9b2533a24 100644
--- a/tests/dummy/app/templates/public-pages/docs/action-handling.hbs
+++ b/tests/dummy/app/templates/public-pages/docs/action-handling.hbs
@@ -34,7 +34,7 @@
{{/code-example}}
- That gives you the freedom of doing whatever suits your need when the user selects a value.
+ That gives you the freedom of doing whatever suits your needs when the user selects a value.
If the only thing you want to do is update the value, you can make it more concise by using the
mut helper.
@@ -53,7 +53,7 @@
The second option you can provide to the component to customize it's behavior is onkeypress.
- This options will be fired whenever the user presses a key while the component or the search input inside
+ This option will be fired whenever the user presses a key while the component or the search input inside
have the focus.
@@ -68,7 +68,7 @@
One particular common use case for this action is to add new options in multiple selects when the
- user introduced free text.
+ user introduces free text.
{{#code-example hbs="action-handling-3.hbs" js="action-handling-3-js.js" as |partialName|}}
@@ -84,7 +84,7 @@
- This action gives your the opportunity to react to any change in the inputs of the select, even when the inputs are
+ This action gives you the opportunity to react to any change in the inputs of the select, even when the inputs are
emptied, because the search action doesn't fire in that case. If you return false from this action,
you will prevent the default behavior, which is searching.
@@ -122,7 +122,7 @@
onopen/onclose Actions
- As their names suggest, this actions are fired when the component is about to be opened or closed respectively,
+ As their names suggest, these actions are fired when the component is about to be opened or closed respectively,
and they both have the same signature (select, event) (the event will be undefined if
the component is not opened as result of user interaction).
@@ -139,7 +139,7 @@
Another neat trick is that you can prevent the component from open/close if you return false
from these actions, so you have the last word. This is all it takes to create a mandatory select component
- that once opened it cannot be closed until you select some value, and changes
+ that once opened cannot be closed until you select some value, and changes
the styles of the component.
From 5d22c63fde313a7729284791f4a1019ee3352289 Mon Sep 17 00:00:00 2001
From: Marcell Monteiro Cruz <0000marcell@gmail.com>
Date: Wed, 11 Apr 2018 10:47:51 -0300
Subject: [PATCH 07/34] stop click propagation added to the docs (#1087)
* stop click propagation added to the docs
* added more info about stop click propagation in the docs
---
.../app/controllers/public-pages/docs/the-list.js | 6 ++++++
.../app/templates/public-pages/docs/the-list.hbs | 14 ++++++++++++++
.../dummy/app/templates/snippets/the-list-10-js.js | 13 +++++++++++++
tests/dummy/app/templates/snippets/the-list-10.hbs | 11 +++++++++++
4 files changed, 44 insertions(+)
create mode 100644 tests/dummy/app/templates/snippets/the-list-10-js.js
create mode 100644 tests/dummy/app/templates/snippets/the-list-10.hbs
diff --git a/tests/dummy/app/controllers/public-pages/docs/the-list.js b/tests/dummy/app/controllers/public-pages/docs/the-list.js
index 4fc28b11f..e4f99e821 100644
--- a/tests/dummy/app/controllers/public-pages/docs/the-list.js
+++ b/tests/dummy/app/controllers/public-pages/docs/the-list.js
@@ -43,6 +43,12 @@ export default Controller.extend({
actions: {
refreshCollection() {
this.set('promise', generatePromise());
+ },
+ stopPropagation(e) {
+ e.stopPropagation();
+ },
+ removeName(name) {
+ alert(`remove name: ${name}`);
}
}
});
diff --git a/tests/dummy/app/templates/public-pages/docs/the-list.hbs b/tests/dummy/app/templates/public-pages/docs/the-list.hbs
index 948368cff..474440e23 100644
--- a/tests/dummy/app/templates/public-pages/docs/the-list.hbs
+++ b/tests/dummy/app/templates/public-pages/docs/the-list.hbs
@@ -149,6 +149,20 @@
This is because it deserves an entire chapter of its own.
+
Prevent click propagation inside the list
+
+
+ The options inside the list are selected with mousedown, a good way to prevent the selection is intercepting onmouseup and calling stopPropagation on the element "e.stopPropagation()"
+
+
+
+This is particularly useful if you want to add some kind of link or button inside the list of options and prevent the selection of the item when the user clicks on the link.
+
< The triggerThe search >
diff --git a/tests/dummy/app/templates/snippets/the-list-10-js.js b/tests/dummy/app/templates/snippets/the-list-10-js.js
new file mode 100644
index 000000000..094ccc6b5
--- /dev/null
+++ b/tests/dummy/app/templates/snippets/the-list-10-js.js
@@ -0,0 +1,13 @@
+import Controller from '@ember/controller';
+
+export default Controller.extend({
+ names: ['Stefan', 'Miguel', 'Tomster', 'Pluto'],
+ actions: {
+ stopPropagation(e) {
+ e.stopPropagation();
+ },
+ removeName(name) {
+ alert(`remove name: ${name}`);
+ }
+ }
+});
diff --git a/tests/dummy/app/templates/snippets/the-list-10.hbs b/tests/dummy/app/templates/snippets/the-list-10.hbs
new file mode 100644
index 000000000..d06d04f5e
--- /dev/null
+++ b/tests/dummy/app/templates/snippets/the-list-10.hbs
@@ -0,0 +1,11 @@
+{{#power-select
+ options=names
+ renderInPlace=true
+ selected=name345
+ onchange=(action (mut name345))
+ as |name|
+}}
+ {{name}}
+ ×
+{{/power-select}}
From 51e4411f2d4c1e837ec88e41c52b3af9b8a6f739 Mon Sep 17 00:00:00 2001
From: Miguel Camba
Date: Sun, 15 Apr 2018 21:25:30 +0200
Subject: [PATCH 08/34] Update addon to 3.1 (#1088)
* Update addon to 3.1
* Smarter way to decide wether or not we want to load jquery
---
.eslintrc.js | 44 +-
.npmignore | 2 +-
.travis.yml | 2 +
.../power-select-multiple/trigger.js | 2 +-
addon/components/power-select/options.js | 3 +-
.../power-select-multiple/trigger.hbs | 4 +-
addon/utils/group-utils.js | 2 +-
compile-css.js | 3 +-
config/deploy.js | 2 +-
config/ember-try.js | 181 +-
config/environment.js | 1 -
config/release.js | 2 +-
ember-cli-build.js | 8 +-
index.js | 21 +-
package.json | 38 +-
run-fastboot-tests.js | 4 +-
testem.js | 14 +-
.../dummy/app/controllers/helpers-testing.js | 1 -
tests/dummy/app/controllers/legacy-demo.js | 1 -
tests/dummy/app/models/user.js | 5 +-
tests/dummy/config/environment.js | 5 +-
tests/dummy/config/targets.js | 23 +-
tests/dummy/mirage/models/pet.js | 5 -
tests/dummy/mirage/models/user.js | 6 -
tests/dummy/mirage/serializers/user.js | 11 +-
.../power-select/ember-data-test.js | 24 +-
.../power-select/public-actions-test.js | 23 +-
tests/test-helper.js | 3 +-
yarn.lock | 1948 ++++++++++-------
29 files changed, 1376 insertions(+), 1012 deletions(-)
delete mode 100644 tests/dummy/mirage/models/pet.js
delete mode 100644 tests/dummy/mirage/models/user.js
diff --git a/.eslintrc.js b/.eslintrc.js
index 58f361870..7ca289579 100644
--- a/.eslintrc.js
+++ b/.eslintrc.js
@@ -4,15 +4,51 @@ module.exports = {
ecmaVersion: 2017,
sourceType: 'module'
},
+ plugins: [
+ 'ember'
+ ],
extends: [
'eslint:recommended',
- 'plugin:ember-suave/recommended'
+ 'plugin:ember/recommended'
],
env: {
browser: true
},
rules: {
- 'ember-suave/no-direct-property-access': 0,
- 'ember-suave/prefer-destructuring': 0
- }
+ 'no-console': 0,
+ 'ember/avoid-leaking-state-in-ember-objects': 0
+ },
+ overrides: [
+ // node files
+ {
+ files: [
+ 'compile-css.js',
+ 'ember-cli-build.js',
+ 'index.js',
+ 'testem.js',
+ 'config/**/*.js',
+ 'tests/dummy/config/**/*.js'
+ ],
+ excludedFiles: [
+ 'addon/**',
+ 'addon-test-support/**',
+ 'app/**',
+ 'run-fastboot-tests.js',
+ 'tests/dummy/app/**',
+ 'app/templates/snippets/**/*.js'
+ ],
+ parserOptions: {
+ sourceType: 'script',
+ ecmaVersion: 2017
+ },
+ env: {
+ browser: false,
+ node: true
+ },
+ plugins: ['node'],
+ rules: Object.assign({}, require('eslint-plugin-node').configs.recommended.rules, {
+ // add your custom rules and overrides for node files here
+ })
+ }
+ ]
};
diff --git a/.npmignore b/.npmignore
index 08040d838..d47920839 100644
--- a/.npmignore
+++ b/.npmignore
@@ -7,8 +7,8 @@
.bowerrc
.editorconfig
.ember-cli
-.gitignore
.eslintrc.js
+.gitignore
.watchmanconfig
.travis.yml
bower.json
diff --git a/.travis.yml b/.travis.yml
index 5bd0146f4..0102d41ef 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -22,6 +22,7 @@ env:
- EMBER_TRY_SCENARIO=ember-2.10
- EMBER_TRY_SCENARIO=ember-lts-2.12
- EMBER_TRY_SCENARIO=ember-lts-2.16
+ - EMBER_TRY_SCENARIO=ember-lts-2.18
- EMBER_TRY_SCENARIO=ember-release
- EMBER_TRY_SCENARIO=ember-beta
- EMBER_TRY_SCENARIO=ember-canary
@@ -41,6 +42,7 @@ install:
- yarn install --no-lockfile --non-interactive
script:
+ - yarn lint:js
# Usually, it's ok to finish the test scenario without reverting
# to the addon's original dependency state, skipping "cleanup".
- node_modules/.bin/ember try:one $EMBER_TRY_SCENARIO --skip-cleanup
diff --git a/addon/components/power-select-multiple/trigger.js b/addon/components/power-select-multiple/trigger.js
index 5d2353489..81d71ca87 100644
--- a/addon/components/power-select-multiple/trigger.js
+++ b/addon/components/power-select-multiple/trigger.js
@@ -52,7 +52,7 @@ export default Component.extend({
},
// CPs
- triggerMultipleInputStyle: computed('select.searchText.length', 'select.selected.length', function() {
+ triggerMultipleInputStyle: computed('select.{searchText.length,selected.length}', function() {
let select = this.get('select');
scheduleOnce('actions', select.actions.reposition);
if (!select.selected || select.selected.length === 0) {
diff --git a/addon/components/power-select/options.js b/addon/components/power-select/options.js
index 53f36a875..a7a83ba0c 100644
--- a/addon/components/power-select/options.js
+++ b/addon/components/power-select/options.js
@@ -2,6 +2,7 @@ import Component from '@ember/component';
import { computed } from '@ember/object';
import layout from '../../templates/components/power-select/options';
+const isTouchDevice = (!!self.window && 'ontouchstart' in self.window);
(function(ElementProto) {
if (typeof ElementProto.matches !== 'function') {
ElementProto.matches = ElementProto.msMatchesSelector || ElementProto.mozMatchesSelector || ElementProto.webkitMatchesSelector;
@@ -22,7 +23,7 @@ import layout from '../../templates/components/power-select/options';
})(window.Element.prototype);
export default Component.extend({
- isTouchDevice: (!!self.window && 'ontouchstart' in self.window),
+ isTouchDevice,
layout,
tagName: 'ul',
attributeBindings: ['role', 'aria-controls'],
diff --git a/addon/templates/components/power-select-multiple/trigger.hbs b/addon/templates/components/power-select-multiple/trigger.hbs
index b60d983d0..49d8b0d54 100644
--- a/addon/templates/components/power-select-multiple/trigger.hbs
+++ b/addon/templates/components/power-select-multiple/trigger.hbs
@@ -30,8 +30,8 @@
placeholder={{maybePlaceholder}}
disabled={{select.disabled}}
oninput={{action "onInput"}}
- onFocus={{onFocus}}
- onBlur={{onBlur}}
+ onfocus={{onFocus}}
+ onblur={{onBlur}}
tabindex={{tabindex}}
onkeydown={{action "onKeydown"}}>
{{/if}}
diff --git a/addon/utils/group-utils.js b/addon/utils/group-utils.js
index 731929df0..bb1f395d9 100644
--- a/addon/utils/group-utils.js
+++ b/addon/utils/group-utils.js
@@ -1008,7 +1008,7 @@ export function stripDiacritics(text) {
return DIACRITICS[a] || a;
}
- return `${text}`.replace(/[^\u0000-\u007E]/g, match);
+ return `${text}`.replace(/[^\u0000-\u007E]/g, match); // eslint-disable-line
}
export function defaultMatcher(value, text) {
diff --git a/compile-css.js b/compile-css.js
index 41d66ee3a..958661571 100644
--- a/compile-css.js
+++ b/compile-css.js
@@ -1,5 +1,4 @@
-/* global require, module */
-var sass = require('node-sass');
+var sass = require('node-sass'); // eslint-disable-line
var fs = require('fs');
var path = require('path');
diff --git a/config/deploy.js b/config/deploy.js
index abab2f0ca..b16efbfe2 100644
--- a/config/deploy.js
+++ b/config/deploy.js
@@ -1,4 +1,4 @@
-module.exports = function(deployTarget) {
+module.exports = function() {
return {
};
};
diff --git a/config/ember-try.js b/config/ember-try.js
index b3a472830..067374e2b 100644
--- a/config/ember-try.js
+++ b/config/ember-try.js
@@ -1,100 +1,91 @@
-/* eslint-env node */
-module.exports = {
- useYarn: true,
- scenarios: [
- {
- name: 'ember-2.10',
- bower: {
- dependencies: {
- ember: '~2.10.0'
- }
- },
- npm: {
- devDependencies: {
- 'ember-source': null,
- 'ember-native-dom-event-dispatcher': null,
- 'ember-factory-for-polyfill': '1.3.1'
- }
- }
- },
- {
- name: 'ember-lts-2.12',
- npm: {
- devDependencies: {
- 'ember-source': '~2.12.0',
- 'ember-native-dom-event-dispatcher': null
- }
- }
- },
- {
- name: 'ember-lts-2.16',
- npm: {
- devDependencies: {
- 'ember-source': '~2.16.0'
- }
- }
- },
- {
- name: 'ember-release',
- bower: {
- dependencies: {
- 'ember': 'components/ember#release'
+'use strict';
+
+const getChannelURL = require('ember-source-channel-url');
+
+module.exports = function() {
+ return Promise.all([
+ getChannelURL('release'),
+ getChannelURL('beta'),
+ getChannelURL('canary')
+ ]).then((urls) => {
+ return {
+ useYarn: true,
+ scenarios: [
+ {
+ name: 'ember-2.10',
+ bower: {
+ dependencies: {
+ ember: '~2.10.0'
+ }
+ },
+ npm: {
+ devDependencies: {
+ 'ember-source': null,
+ 'ember-factory-for-polyfill': '1.3.1'
+ }
+ }
},
- resolutions: {
- 'ember': 'release'
- }
- },
- npm: {
- devDependencies: {
- 'ember-source': null,
- 'ember-native-dom-event-dispatcher': null
- }
- }
- },
- {
- name: 'ember-beta',
- bower: {
- dependencies: {
- 'ember': 'components/ember#beta'
+ {
+ name: 'ember-lts-2.12',
+ npm: {
+ devDependencies: {
+ 'ember-source': '~2.12.0'
+ }
+ }
},
- resolutions: {
- 'ember': 'beta'
- }
- },
- npm: {
- devDependencies: {
- 'ember-source': null
- }
- }
- },
- {
- name: 'ember-canary',
- bower: {
- dependencies: {
- 'ember': 'components/ember#canary'
+ {
+ name: 'ember-lts-2.16',
+ npm: {
+ devDependencies: {
+ 'ember-source': '~2.16.0',
+ 'ember-native-dom-event-dispatcher': '^0.6.4'
+ }
+ }
},
- resolutions: {
- 'ember': 'canary'
- }
- },
- npm: {
- devDependencies: {
- 'ember-source': null
+ {
+ name: 'ember-lts-2.18',
+ npm: {
+ devDependencies: {
+ 'ember-source': '~2.18.0',
+ 'ember-native-dom-event-dispatcher': '^0.6.4'
+ }
+ }
+ },
+ {
+ name: 'ember-release',
+ npm: {
+ devDependencies: {
+ 'ember-source': urls[0]
+ }
+ }
+ },
+ {
+ name: 'ember-beta',
+ npm: {
+ devDependencies: {
+ 'ember-source': urls[1]
+ }
+ }
+ },
+ {
+ name: 'ember-canary',
+ npm: {
+ devDependencies: {
+ 'ember-source': urls[2]
+ }
+ }
+ },
+ {
+ name: 'ember-default',
+ npm: {
+ devDependencies: {}
+ }
+ },
+ {
+ name: 'node-tests',
+ command: 'npm run nodetest'
}
- }
- },
- {
- name: 'ember-default',
- npm: {
- devDependencies: {}
- }
- },
- {
- name: 'node-tests',
- command: 'npm run nodetest',
- bower: {
- dependencies: {}
- }
- }
- ]
+ ]
+ };
+ });
};
diff --git a/config/environment.js b/config/environment.js
index 012a412f6..0dfaed472 100644
--- a/config/environment.js
+++ b/config/environment.js
@@ -1,4 +1,3 @@
-/* eslint-env node */
'use strict';
module.exports = function(/* environment, appConfig */) {
diff --git a/config/release.js b/config/release.js
index 52c6bced6..adf223450 100644
--- a/config/release.js
+++ b/config/release.js
@@ -14,7 +14,7 @@ module.exports = {
// format: 'YYYY-MM-DD',
// timezone: 'America/Los_Angeles',
//
- beforeCommit: function(project, versions) {
+ beforeCommit: function (/* project, versions */) {
require('../compile-css.js'); // Requiring the file compiles
return new Promise(function(resolve) {
simpleGit.add(['vendor/ember-power-select.css'], function() {
diff --git a/ember-cli-build.js b/ember-cli-build.js
index 7739b0b61..05c247c3e 100644
--- a/ember-cli-build.js
+++ b/ember-cli-build.js
@@ -1,15 +1,17 @@
-/* eslint-env node */
'use strict';
const EmberAddon = require('ember-cli/lib/broccoli/ember-addon');
+const VersionChecker = require('ember-cli-version-checker'); // eslint-disable-line
+
module.exports = function(defaults) {
- let project = defaults.project;
+ let checker = new VersionChecker(defaults);
+ let emberChecker = checker.forEmber();
let options = {
snippetPaths: ['tests/dummy/app/templates/snippets']
};
- if (project.findAddonByName('ember-native-dom-event-dispatcher') && process.env.DEPLOY_TARGET === undefined) {
+ if (process.env.DEPLOY_TARGET === undefined && emberChecker.isAbove('2.14.0')) {
options.vendorFiles = { 'jquery.js': null };
}
diff --git a/index.js b/index.js
index ed5bab40b..459e78068 100644
--- a/index.js
+++ b/index.js
@@ -1,22 +1,21 @@
-/* eslint-env node */
'use strict';
// For ember-cli < 2.7 findHost doesnt exist so we backport from that version
// for earlier version of ember-cli.
-//https://github.com/ember-cli/ember-cli/blame/16e4492c9ebf3348eb0f31df17215810674dbdf6/lib/models/addon.js#L533
- function findHostShim() {
- let current = this;
- let app;
- do {
- app = current.app || app;
- } while (current.parent.parent && (current = current.parent));
- return app;
- }
+// https://github.com/ember-cli/ember-cli/blame/16e4492c9ebf3348eb0f31df17215810674dbdf6/lib/models/addon.js#L533
+function findHostShim() {
+ let current = this;
+ let app;
+ do {
+ app = current.app || app;
+ } while (current.parent.parent && (current = current.parent));
+ return app;
+}
module.exports = {
name: 'ember-power-select',
- included(appOrAddon) {
+ included() {
let findHost = this._findHost || findHostShim;
let app = findHost.call(this);
if (!app.__emberPowerSelectIncludedInvoked) {
diff --git a/package.json b/package.json
index 54a48b181..e113e758c 100644
--- a/package.json
+++ b/package.json
@@ -7,7 +7,8 @@
"select",
"select2",
"selectize",
- "dropdown"
+ "dropdown",
+ "ember-power"
],
"license": "MIT",
"author": {
@@ -25,9 +26,11 @@
},
"scripts": {
"build": "ember build",
+ "lint:js": "eslint ./*.js addon addon-test-support app config lib server test-support tests --ignore-pattern tests/dummy/app/templates/snippets",
+ "nodetest": "$(npm bin)/mocha node-tests --recursive",
"start": "ember serve",
- "test": "ember try:each",
- "nodetest": "$(npm bin)/mocha node-tests --recursive"
+ "test": "ember test",
+ "test:all": "ember try:each"
},
"files": [
"addon/",
@@ -39,7 +42,7 @@
"vendor"
],
"dependencies": {
- "ember-basic-dropdown": "^1.0.0-beta.3",
+ "ember-basic-dropdown": "^1.0.0-beta.5",
"ember-cli-babel": "^6.11.0",
"ember-cli-htmlbars": "^2.0.1",
"ember-concurrency": "^0.8.12",
@@ -48,33 +51,35 @@
},
"devDependencies": {
"broccoli-asset-rev": "^2.4.5",
- "ember-cli": "~2.17.1",
+ "ember-cli": "~3.1.2",
"ember-cli-blueprint-test-helpers": "^0.18.3",
"ember-cli-dependency-checker": "^2.0.1",
"ember-cli-eslint": "^4.2.1",
"ember-cli-htmlbars-inline-precompile": "^1.0.2",
"ember-cli-inject-live-reload": "^1.7.0",
- "ember-cli-mirage": "^0.4.0",
+ "ember-cli-mirage": "^0.4.3",
"ember-cli-qunit": "^4.3.2",
- "ember-cli-sass": "^7.1.0",
+ "ember-cli-sass": "^7.1.7",
"ember-cli-template-lint": "0.7.5",
- "ember-cli-uglify": "^2.0.0",
+ "ember-cli-uglify": "^2.1.0",
"ember-code-example-component": "^0.2.0",
"ember-code-snippet": "2.0.0",
- "ember-data": "^2.17.0",
+ "ember-data": "^3.1.1",
"ember-disable-prototype-extensions": "^1.1.3",
"ember-export-application-global": "^2.0.0",
- "ember-fetch": "^3.4.0",
+ "ember-fetch": "^3.4.5",
"ember-href-to": "1.15.1",
"ember-load-initializers": "^1.0.0",
"ember-maybe-import-regenerator": "^0.1.6",
- "ember-native-dom-event-dispatcher": "^0.6.3",
- "ember-native-dom-helpers": "^0.5.10",
+ "ember-native-dom-helpers": "^0.6.2",
"ember-qunit-assert-helpers": "^0.2.1",
"ember-resolver": "^4.0.0",
- "ember-source": "~2.17.0",
- "eslint-plugin-ember-suave": "^1.0.0",
- "liquid-fire": "0.29.1",
+ "ember-source": "~3.1.0",
+ "ember-source-channel-url": "^1.0.1",
+ "ember-try": "^0.2.23",
+ "eslint-plugin-ember": "^5.0.0",
+ "eslint-plugin-node": "^6.0.1",
+ "liquid-fire": "0.29.2",
"loader.js": "^4.6.0",
"memory-scroll": "0.9.1",
"mocha": "2.5.3",
@@ -85,7 +90,6 @@
"node": "^4.5 || 6.* || >= 7.*"
},
"ember-addon": {
- "configPath": "tests/dummy/config",
- "before": "ember-cli-sri"
+ "configPath": "tests/dummy/config"
}
}
diff --git a/run-fastboot-tests.js b/run-fastboot-tests.js
index 7a94ccdd6..8ff14dddc 100755
--- a/run-fastboot-tests.js
+++ b/run-fastboot-tests.js
@@ -1,4 +1,4 @@
-/* eslint-env node */
+ /* eslint-env node */
global.QUnit = require('qunitjs');
// adds test reporting
@@ -18,4 +18,4 @@ function addFiles(files) {
addFiles('/**/*-test.js');
-QUnit.load();
+global.QUnit.load();
diff --git a/testem.js b/testem.js
index 75e6af4e9..a4402a571 100644
--- a/testem.js
+++ b/testem.js
@@ -1,24 +1,20 @@
-/* eslint-env node */
module.exports = {
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_args: {
Chrome: {
mode: 'ci',
args: [
+ // --no-sandbox is needed when running Chrome inside a container
process.env.TRAVIS ? '--no-sandbox' : null,
'--touch-events',
'--disable-gpu',
'--headless',
'--remote-debugging-port=0',
'--window-size=1440,900'
- ]
- },
+ ].filter(Boolean)
+ }
}
};
diff --git a/tests/dummy/app/controllers/helpers-testing.js b/tests/dummy/app/controllers/helpers-testing.js
index 861bc978e..b6edda686 100644
--- a/tests/dummy/app/controllers/helpers-testing.js
+++ b/tests/dummy/app/controllers/helpers-testing.js
@@ -1,7 +1,6 @@
import Controller from '@ember/controller';
import { later } from '@ember/runloop';
import RSVP from 'rsvp';
-
const numbers = [
'one',
'two',
diff --git a/tests/dummy/app/controllers/legacy-demo.js b/tests/dummy/app/controllers/legacy-demo.js
index 9b66ffa02..dd3d55c6b 100644
--- a/tests/dummy/app/controllers/legacy-demo.js
+++ b/tests/dummy/app/controllers/legacy-demo.js
@@ -1,4 +1,3 @@
-/* eslint no-console: 0 */
import Controller from '@ember/controller';
import { computed } from '@ember/object';
import { later } from '@ember/runloop';
diff --git a/tests/dummy/app/models/user.js b/tests/dummy/app/models/user.js
index 3e34faeab..8646e5974 100644
--- a/tests/dummy/app/models/user.js
+++ b/tests/dummy/app/models/user.js
@@ -3,6 +3,5 @@ import DS from 'ember-data';
export default DS.Model.extend({
name: DS.attr('string'),
age: DS.attr('number'),
- pets: DS.hasMany('pet', { inverse: 'owner' }),
- bestie: DS.belongsTo('pet')
-});
\ No newline at end of file
+ pets: DS.hasMany('pet', { inverse: 'owner' })
+});
diff --git a/tests/dummy/config/environment.js b/tests/dummy/config/environment.js
index ab1faefd4..5cb0fa609 100644
--- a/tests/dummy/config/environment.js
+++ b/tests/dummy/config/environment.js
@@ -1,4 +1,3 @@
-/* eslint-env node */
'use strict';
module.exports = function(environment) {
@@ -48,9 +47,7 @@ module.exports = function(environment) {
}
if (environment === 'production') {
- // ENV['ember-cli-mirage'] = {
- // enabled: true
- // }
+ // here you can enable a production-specific feature
}
return ENV;
diff --git a/tests/dummy/config/targets.js b/tests/dummy/config/targets.js
index df7664c25..8ffae3636 100644
--- a/tests/dummy/config/targets.js
+++ b/tests/dummy/config/targets.js
@@ -1,9 +1,18 @@
-/* eslint-env node */
+'use strict';
+
+const browsers = [
+ 'last 1 Chrome versions',
+ 'last 1 Firefox versions',
+ 'last 1 Safari versions'
+];
+
+const isCI = !!process.env.CI;
+const isProduction = process.env.EMBER_ENV === 'production';
+
+if (isCI || isProduction) {
+ browsers.push('ie 11');
+}
+
module.exports = {
- browsers: [
- 'ie 9',
- 'last 1 Chrome versions',
- 'last 1 Firefox versions',
- 'last 1 Safari versions'
- ]
+ browsers
};
diff --git a/tests/dummy/mirage/models/pet.js b/tests/dummy/mirage/models/pet.js
deleted file mode 100644
index 3932d4f9a..000000000
--- a/tests/dummy/mirage/models/pet.js
+++ /dev/null
@@ -1,5 +0,0 @@
-import { Model, belongsTo } from 'ember-cli-mirage';
-
-export default Model.extend({
- owner: belongsTo('user')
-});
diff --git a/tests/dummy/mirage/models/user.js b/tests/dummy/mirage/models/user.js
deleted file mode 100644
index 43c45f9cc..000000000
--- a/tests/dummy/mirage/models/user.js
+++ /dev/null
@@ -1,6 +0,0 @@
-import { Model, hasMany, belongsTo } from 'ember-cli-mirage';
-
-export default Model.extend({
- pets: hasMany('pet'),
- bestie: belongsTo('pet')
-});
diff --git a/tests/dummy/mirage/serializers/user.js b/tests/dummy/mirage/serializers/user.js
index 36e7d46d3..031605dfc 100644
--- a/tests/dummy/mirage/serializers/user.js
+++ b/tests/dummy/mirage/serializers/user.js
@@ -1,12 +1,5 @@
import BaseSerializer from './application';
export default BaseSerializer.extend({
- include: ['pets'],
- links(model) {
- return {
- bestie: {
- related: `/pets/${model.bestieId}`
- }
- };
- }
-});
\ No newline at end of file
+ include: ['pets']
+});
diff --git a/tests/integration/components/power-select/ember-data-test.js b/tests/integration/components/power-select/ember-data-test.js
index 30f841af5..1a45891c5 100644
--- a/tests/integration/components/power-select/ember-data-test.js
+++ b/tests/integration/components/power-select/ember-data-test.js
@@ -3,27 +3,23 @@ import { setupRenderingTest } from 'ember-qunit';
import { render, settled } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
-import { startMirage } from '../../../../initializers/ember-cli-mirage';
import emberDataInitializer from '../../../../initializers/ember-data';
import { find, findAll, click } from 'ember-native-dom-helpers';
+import setupMirage from 'ember-cli-mirage/test-support/setup-mirage';
module('Integration | Component | Ember Power Select (Ember-data integration)', function(hooks) {
setupRenderingTest(hooks);
+ setupMirage(hooks);
hooks.beforeEach(function() {
let owner = this.owner;
- startMirage({ environment: 'test', modulePrefix: 'dummy' });
emberDataInitializer.initialize(owner);
this.store = owner.lookup('service:store');
});
- hooks.afterEach(function() {
- server.shutdown();
- });
-
test('Passing as options of a `store.findAll` works', async function(assert) {
- server.createList('user', 10);
- server.timing = 200;
+ this.server.createList('user', 10);
+ this.server.timing = 200;
this.users = [];
await render(hbs`
{{#power-select options=users searchField="name" onchange=(action (mut foo)) as |option|}}
@@ -43,13 +39,13 @@ module('Integration | Component | Ember Power Select (Ember-data integration)',
});
test('Passing as options the result of `store.query` works', async function(assert) {
- server.createList('user', 10);
- server.timing = 200;
+ this.server.createList('user', 10);
+ this.server.timing = 200;
this.users = [];
await render(hbs`
- {{#power-select options=users searchField="name" onchange=(action (mut foo)) as |option|}}
- {{option.name}}
- {{/power-select}}
+ {{#power-select options=users searchField="name" onchange=(action (mut foo)) as |option|}}
+ {{option.name}}
+ {{/power-select}}
`);
this.set('users', this.store.query('user', { foo: 'bar' }));
@@ -64,7 +60,7 @@ module('Integration | Component | Ember Power Select (Ember-data integration)',
});
test('Delete an item in a multiple selection', async function(assert) {
- server.createList('user', 10);
+ this.server.createList('user', 10);
this.users = [];
await render(hbs`
{{#power-select-multiple options=users searchField="name" selected=users onchange=(action (mut users)) as |option|}}
diff --git a/tests/integration/components/power-select/public-actions-test.js b/tests/integration/components/power-select/public-actions-test.js
index 993c3350b..61ba445a0 100644
--- a/tests/integration/components/power-select/public-actions-test.js
+++ b/tests/integration/components/power-select/public-actions-test.js
@@ -4,7 +4,7 @@ import { render } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { clickTrigger, typeInSearch } from 'ember-power-select/test-support/helpers';
import { numbers } from '../constants';
-import { find, findAll, click, keyEvent, focus } from 'ember-native-dom-helpers';
+import { find, findAll, click, triggerKeyEvent, focus } from '@ember/test-helpers';
import { run } from '@ember/runloop';
function assertPublicAPIShape(assert, select) {
@@ -127,8 +127,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
clickTrigger();
let input = find('.ember-power-select-search-input');
- keyEvent(input, 'keydown', 13);
- keyEvent(input, 'keydown', 65);
+ triggerKeyEvent(input, 'keydown', 13);
+ triggerKeyEvent(input, 'keydown', 65);
});
test('The onkeydown can be used to easily allow to select on tab', async function(assert) {
@@ -150,9 +150,9 @@ module('Integration | Component | Ember Power Select (Public actions)', function
clickTrigger();
let trigger = find('.ember-power-select-trigger');
- keyEvent(trigger, 'keydown', 40);
- keyEvent(trigger, 'keydown', 40);
- keyEvent(trigger, 'keydown', 9);
+ await triggerKeyEvent(trigger, 'keydown', 40);
+ await triggerKeyEvent(trigger, 'keydown', 40);
+ await triggerKeyEvent(trigger, 'keydown', 9);
assert.equal(trigger.textContent.trim(), 'three', 'The highlighted options has been selected');
assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is opened');
});
@@ -174,8 +174,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
clickTrigger();
let input = find('.ember-power-select-trigger-multiple-input');
- keyEvent(input, 'keydown', 13);
- keyEvent(input, 'keydown', 65);
+ triggerKeyEvent(input, 'keydown', 13);
+ triggerKeyEvent(input, 'keydown', 65);
});
test('returning false from the `onkeydown` action prevents the default behaviour in single selects', async function(assert) {
@@ -195,9 +195,9 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- keyEvent('.ember-power-select-trigger', 'keydown', 13);
+ triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is still closed');
- keyEvent('.ember-power-select-trigger', 'keydown', 84); // 't'
+ triggerKeyEvent('.ember-power-select-trigger', 'keydown', 84); // 't'
assert.notEqual(find('.ember-power-select-trigger').textContent.trim(), 'two', 'nothing was selected');
});
@@ -218,7 +218,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
+ triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is still closed');
});
@@ -268,6 +268,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
};
await render(hbs`
+
{{#power-select-multiple options=numbers selected=foo onfocus=handleFocus onchange=(action (mut foo)) as |number|}}
{{number}}
{{/power-select-multiple}}
diff --git a/tests/test-helper.js b/tests/test-helper.js
index b58f4e792..0382a848d 100644
--- a/tests/test-helper.js
+++ b/tests/test-helper.js
@@ -1,7 +1,8 @@
import Application from '../app';
+import config from '../config/environment';
import { setApplication } from '@ember/test-helpers';
import { start } from 'ember-qunit';
-import config from '../config/environment';
setApplication(Application.create(config.APP));
+
start();
diff --git a/yarn.lock b/yarn.lock
index 3a7afa286..7bca8a3a4 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -2,75 +2,79 @@
# yarn lockfile v1
+"@ember/ordered-set@^1.0.0":
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/@ember/ordered-set/-/ordered-set-1.0.0.tgz#cf9ab5fd7510bcad370370ebcded705f6d1c542b"
+ dependencies:
+ ember-cli-babel "6.12.0"
+ ember-compatibility-helpers "^1.0.0-beta.2"
+
"@ember/test-helpers@^0.7.18":
- version "0.7.18"
- resolved "https://registry.yarnpkg.com/@ember/test-helpers/-/test-helpers-0.7.18.tgz#a0c474c3029588ec46d2e406252fc072b7f9aa3c"
+ version "0.7.21"
+ resolved "https://registry.yarnpkg.com/@ember/test-helpers/-/test-helpers-0.7.21.tgz#1bb6555e7d201d86800671a0ba64e70d3d23a3a0"
dependencies:
broccoli-funnel "^2.0.1"
ember-cli-babel "^6.10.0"
ember-cli-htmlbars-inline-precompile "^1.0.0"
-"@glimmer/compiler@^0.30.1":
- version "0.30.3"
- resolved "https://registry.yarnpkg.com/@glimmer/compiler/-/compiler-0.30.3.tgz#9fc27ebfbce66b1142084b876326ee0f1793649e"
+"@glimmer/compiler@^0.32.3":
+ version "0.32.3"
+ resolved "https://registry.yarnpkg.com/@glimmer/compiler/-/compiler-0.32.3.tgz#fc15780ec38aa62b60da600618ca1f43da6b979c"
dependencies:
- "@glimmer/interfaces" "^0.30.3"
- "@glimmer/syntax" "^0.30.3"
- "@glimmer/util" "^0.30.3"
- "@glimmer/wire-format" "^0.30.3"
+ "@glimmer/interfaces" "^0.32.3"
+ "@glimmer/syntax" "^0.32.3"
+ "@glimmer/util" "^0.32.3"
+ "@glimmer/wire-format" "^0.32.3"
simple-html-tokenizer "^0.4.1"
"@glimmer/di@^0.2.0":
version "0.2.0"
resolved "https://registry.yarnpkg.com/@glimmer/di/-/di-0.2.0.tgz#73bfd4a6ee4148a80bf092e8a5d29bcac9d4ce7e"
-"@glimmer/interfaces@^0.30.3":
- version "0.30.3"
- resolved "https://registry.yarnpkg.com/@glimmer/interfaces/-/interfaces-0.30.3.tgz#ea53e6b945ae3cc14588e655626ad9c6ed90a9f9"
+"@glimmer/interfaces@^0.32.3":
+ version "0.32.3"
+ resolved "https://registry.yarnpkg.com/@glimmer/interfaces/-/interfaces-0.32.3.tgz#a328344d88490c1ae765ebe18ee357ed9a66f0fb"
dependencies:
- "@glimmer/wire-format" "^0.30.3"
+ "@glimmer/wire-format" "^0.32.3"
"@glimmer/resolver@^0.4.1":
- version "0.4.2"
- resolved "https://registry.yarnpkg.com/@glimmer/resolver/-/resolver-0.4.2.tgz#60c9b492e90bc3956ac82b3134649bd337e1651c"
+ version "0.4.3"
+ resolved "https://registry.yarnpkg.com/@glimmer/resolver/-/resolver-0.4.3.tgz#b1baae5c3291b4621002ccf8d7870466097e841d"
dependencies:
"@glimmer/di" "^0.2.0"
-"@glimmer/syntax@^0.30.2", "@glimmer/syntax@^0.30.3":
- version "0.30.3"
- resolved "https://registry.yarnpkg.com/@glimmer/syntax/-/syntax-0.30.3.tgz#31ca56d00b4f7c63af13aeb70b5d58a9b250f02e"
+"@glimmer/syntax@^0.32.3":
+ version "0.32.3"
+ resolved "https://registry.yarnpkg.com/@glimmer/syntax/-/syntax-0.32.3.tgz#f6b035948013728e646731d774ccd8c49f7d10d1"
dependencies:
- "@glimmer/interfaces" "^0.30.3"
- "@glimmer/util" "^0.30.3"
+ "@glimmer/interfaces" "^0.32.3"
+ "@glimmer/util" "^0.32.3"
handlebars "^4.0.6"
simple-html-tokenizer "^0.4.1"
-"@glimmer/util@^0.30.3":
- version "0.30.3"
- resolved "https://registry.yarnpkg.com/@glimmer/util/-/util-0.30.3.tgz#c771fce2d766c380ae50d3ad8045eff224637e8c"
+"@glimmer/util@^0.32.3":
+ version "0.32.3"
+ resolved "https://registry.yarnpkg.com/@glimmer/util/-/util-0.32.3.tgz#b73ccc1b73097ba6ec1e250954a1a2e1eb83eb48"
-"@glimmer/wire-format@^0.30.3":
- version "0.30.3"
- resolved "https://registry.yarnpkg.com/@glimmer/wire-format/-/wire-format-0.30.3.tgz#32629d99f3107b4c940cf84607e417686e55b94d"
+"@glimmer/wire-format@^0.32.3":
+ version "0.32.3"
+ resolved "https://registry.yarnpkg.com/@glimmer/wire-format/-/wire-format-0.32.3.tgz#2f684a6d88ba7162d32cd5f01bd0b83151cdb73d"
dependencies:
- "@glimmer/util" "^0.30.3"
+ "@glimmer/util" "^0.32.3"
+
+"@sindresorhus/is@^0.7.0":
+ version "0.7.0"
+ resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-0.7.0.tgz#9a06f4f137ee84d7df0460c1fdb1135ffa6c50fd"
abbrev@1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8"
-accepts@1.3.3:
- version "1.3.3"
- resolved "https://registry.yarnpkg.com/accepts/-/accepts-1.3.3.tgz#c3ca7434938648c3e0d9c1e328dd68b622c284ca"
- dependencies:
- mime-types "~2.1.11"
- negotiator "0.6.1"
-
-accepts@~1.3.4:
- version "1.3.4"
- resolved "https://registry.yarnpkg.com/accepts/-/accepts-1.3.4.tgz#86246758c7dd6d21a6474ff084a4740ec05eb21f"
+accepts@~1.3.4, accepts@~1.3.5:
+ version "1.3.5"
+ resolved "https://registry.yarnpkg.com/accepts/-/accepts-1.3.5.tgz#eb777df6011723a3b14e8a72c0805c8e86746bd2"
dependencies:
- mime-types "~2.1.16"
+ mime-types "~2.1.18"
negotiator "0.6.1"
acorn-jsx@^3.0.0:
@@ -83,13 +87,13 @@ acorn@^3.0.4:
version "3.3.0"
resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a"
-acorn@^5.2.1:
- version "5.2.1"
- resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.2.1.tgz#317ac7821826c22c702d66189ab8359675f135d7"
+acorn@^5.5.0:
+ version "5.5.3"
+ resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.5.3.tgz#f473dd47e0277a08e28e9bec5aeeb04751f0b8c9"
-after@0.8.1:
- version "0.8.1"
- resolved "https://registry.yarnpkg.com/after/-/after-0.8.1.tgz#ab5d4fb883f596816d3515f8f791c0af486dd627"
+after@0.8.2:
+ version "0.8.2"
+ resolved "https://registry.yarnpkg.com/after/-/after-0.8.2.tgz#fedb394f9f0e02aa9768e702bda23b505fae7e1f"
ajv-keywords@^2.1.0:
version "2.1.1"
@@ -125,9 +129,9 @@ amd-name-resolver@0.0.7:
dependencies:
ensure-posix-path "^1.0.1"
-amd-name-resolver@1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/amd-name-resolver/-/amd-name-resolver-1.0.0.tgz#0e593b28d6fa3326ab1798107edaea961046e8d8"
+amd-name-resolver@^1.2.0:
+ version "1.2.0"
+ resolved "https://registry.yarnpkg.com/amd-name-resolver/-/amd-name-resolver-1.2.0.tgz#fc41b3848824b557313897d71f8d5a0184fbe679"
dependencies:
ensure-posix-path "^1.0.1"
@@ -140,8 +144,8 @@ ansi-escapes@^1.1.0:
resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-1.4.0.tgz#d3a8a83b319aa67793662b13e761c7911422306e"
ansi-escapes@^3.0.0:
- version "3.0.0"
- resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.0.0.tgz#ec3e8b4e9f8064fc02c3ac9b65f1c275bda8ef92"
+ version "3.1.0"
+ resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.1.0.tgz#f73207bb81207d75fd6c83f125af26eea378ca30"
ansi-regex@^0.2.0, ansi-regex@^0.2.1:
version "0.2.1"
@@ -163,9 +167,9 @@ ansi-styles@^2.2.1:
version "2.2.1"
resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe"
-ansi-styles@^3.0.0, ansi-styles@^3.1.0:
- version "3.2.0"
- resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.0.tgz#c159b8d5be0f9e5a6f346dab94f16ce022161b88"
+ansi-styles@^3.0.0, ansi-styles@^3.2.1:
+ version "3.2.1"
+ resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d"
dependencies:
color-convert "^1.9.0"
@@ -180,12 +184,27 @@ anymatch@^1.3.0:
micromatch "^2.1.5"
normalize-path "^2.0.0"
+anymatch@^2.0.0:
+ version "2.0.0"
+ resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-2.0.0.tgz#bcb24b4f37934d9aa7ac17b4adaf89e7c76ef2eb"
+ dependencies:
+ micromatch "^3.1.4"
+ normalize-path "^2.1.1"
+
aot-test-generators@^0.1.0:
version "0.1.0"
resolved "https://registry.yarnpkg.com/aot-test-generators/-/aot-test-generators-0.1.0.tgz#43f0f615f97cb298d7919c1b0b4e6b7310b03cd0"
dependencies:
jsesc "^2.5.0"
+applause@1.2.2:
+ version "1.2.2"
+ resolved "https://registry.yarnpkg.com/applause/-/applause-1.2.2.tgz#a8468579e81f67397bb5634c29953bedcd0f56c0"
+ dependencies:
+ cson-parser "^1.1.0"
+ js-yaml "^3.3.0"
+ lodash "^3.10.0"
+
aproba@^1.0.3:
version "1.2.0"
resolved "https://registry.yarnpkg.com/aproba/-/aproba-1.2.0.tgz#6802e6264efd18c790a1b0d517f0f2627bf2c94a"
@@ -198,8 +217,8 @@ are-we-there-yet@~1.1.2:
readable-stream "^2.0.6"
argparse@^1.0.7:
- version "1.0.9"
- resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.9.tgz#73d83bc263f86e97f8cc4f6bae1b0e90a7d22c86"
+ version "1.0.10"
+ resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz#bcd6791ea5ae09725e17e5ad988134cd40b3d911"
dependencies:
sprintf-js "~1.0.2"
@@ -261,9 +280,9 @@ array-unique@^0.3.2:
version "0.3.2"
resolved "https://registry.yarnpkg.com/array-unique/-/array-unique-0.3.2.tgz#a894b75d4bc4f6cd679ef3244a9fd8f46ae2d428"
-arraybuffer.slice@0.0.6:
- version "0.0.6"
- resolved "https://registry.yarnpkg.com/arraybuffer.slice/-/arraybuffer.slice-0.0.6.tgz#f33b2159f0532a3f3107a272c0ccfbd1ad2979ca"
+arraybuffer.slice@~0.0.7:
+ version "0.0.7"
+ resolved "https://registry.yarnpkg.com/arraybuffer.slice/-/arraybuffer.slice-0.0.7.tgz#3bbc4275dd584cc1b10809b89d4e8b63a69e7675"
arrify@^1.0.0:
version "1.0.1"
@@ -282,8 +301,8 @@ assert-plus@^0.2.0:
resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-0.2.0.tgz#d74e1b87e7affc0db8aadb7021f3fe48101ab234"
assertion-error@^1.0.1:
- version "1.0.2"
- resolved "https://registry.yarnpkg.com/assertion-error/-/assertion-error-1.0.2.tgz#13ca515d86206da0bac66e834dd397d87581094c"
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/assertion-error/-/assertion-error-1.1.0.tgz#e60b6b0e8f301bd97e5375215bda406c85118c0b"
assign-symbols@^1.0.0:
version "1.0.0"
@@ -313,7 +332,11 @@ async-foreach@^0.1.3:
version "0.1.3"
resolved "https://registry.yarnpkg.com/async-foreach/-/async-foreach-0.1.3.tgz#36121f845c0578172de419a97dbeb1d16ec34542"
-async-promise-queue@^1.0.3:
+async-limiter@~1.0.0:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/async-limiter/-/async-limiter-1.0.0.tgz#78faed8c3d074ab81f22b4e985d79e8738f720f8"
+
+async-promise-queue@^1.0.3, async-promise-queue@^1.0.4:
version "1.0.4"
resolved "https://registry.yarnpkg.com/async-promise-queue/-/async-promise-queue-1.0.4.tgz#308baafbc74aff66a0bb6e7f4a18d4fe8434440c"
dependencies:
@@ -339,8 +362,8 @@ asynckit@^0.4.0:
resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79"
atob@^2.0.0:
- version "2.0.3"
- resolved "https://registry.yarnpkg.com/atob/-/atob-2.0.3.tgz#19c7a760473774468f20b2d2d03372ad7d4cbf5d"
+ version "2.1.0"
+ resolved "https://registry.yarnpkg.com/atob/-/atob-2.1.0.tgz#ab2b150e51d7b122b9efc8d7340c06b6c41076bc"
aws-sign2@~0.6.0:
version "0.6.0"
@@ -351,8 +374,8 @@ aws-sign2@~0.7.0:
resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8"
aws4@^1.2.1, aws4@^1.6.0:
- version "1.6.0"
- resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.6.0.tgz#83ef5ca860b2b32e4a0deedee8c771b9db57471e"
+ version "1.7.0"
+ resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.7.0.tgz#d4d0e9b9dbfca77bf08eeb0a8a471550fe39e289"
babel-code-frame@^6.22.0, babel-code-frame@^6.26.0:
version "6.26.0"
@@ -387,8 +410,8 @@ babel-core@^6.14.0, babel-core@^6.24.1, babel-core@^6.26.0:
source-map "^0.5.6"
babel-generator@^6.26.0:
- version "6.26.0"
- resolved "https://registry.yarnpkg.com/babel-generator/-/babel-generator-6.26.0.tgz#ac1ae20070b79f6e3ca1d3269613053774f20dc5"
+ version "6.26.1"
+ resolved "https://registry.yarnpkg.com/babel-generator/-/babel-generator-6.26.1.tgz#1844408d3b8f0d35a404ea7ac180f087a601bd90"
dependencies:
babel-messages "^6.23.0"
babel-runtime "^6.26.0"
@@ -396,7 +419,7 @@ babel-generator@^6.26.0:
detect-indent "^4.0.0"
jsesc "^1.3.0"
lodash "^4.17.4"
- source-map "^0.5.6"
+ source-map "^0.5.7"
trim-right "^1.0.1"
babel-helper-builder-binary-assignment-operator-visitor@^6.24.1:
@@ -539,8 +562,8 @@ babel-plugin-filter-imports@^0.3.1:
resolved "https://registry.yarnpkg.com/babel-plugin-filter-imports/-/babel-plugin-filter-imports-0.3.1.tgz#e7859b56886b175dd2616425d277b219e209ea8b"
babel-plugin-htmlbars-inline-precompile@^0.2.3:
- version "0.2.3"
- resolved "https://registry.yarnpkg.com/babel-plugin-htmlbars-inline-precompile/-/babel-plugin-htmlbars-inline-precompile-0.2.3.tgz#cd365e278af409bfa6be7704c4354beee742446b"
+ version "0.2.4"
+ resolved "https://registry.yarnpkg.com/babel-plugin-htmlbars-inline-precompile/-/babel-plugin-htmlbars-inline-precompile-0.2.4.tgz#54b48168432bbc03f1f26f2e9090cb222bc78c75"
babel-plugin-syntax-async-functions@^6.8.0:
version "6.13.0"
@@ -876,9 +899,9 @@ base64-arraybuffer@0.1.5:
version "0.1.5"
resolved "https://registry.yarnpkg.com/base64-arraybuffer/-/base64-arraybuffer-0.1.5.tgz#73926771923b5a19747ad666aa5cd4bf9c6e9ce8"
-base64id@0.1.0:
- version "0.1.0"
- resolved "https://registry.yarnpkg.com/base64id/-/base64id-0.1.0.tgz#02ce0fdeee0cef4f40080e1e73e834f0b1bfce3f"
+base64id@1.0.0:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/base64id/-/base64id-1.0.0.tgz#47688cb99bb6804f0e06d3e763b1c32e57d8e6b6"
base@^0.11.1:
version "0.11.2"
@@ -915,8 +938,8 @@ binary-extensions@^1.0.0:
resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.11.0.tgz#46aa1751fb6a2f93ee5e689bb1087d4b14c6c205"
"binaryextensions@1 || 2":
- version "2.0.0"
- resolved "https://registry.yarnpkg.com/binaryextensions/-/binaryextensions-2.0.0.tgz#e597d1a7a6a3558a2d1c7241a16c99965e6aa40f"
+ version "2.1.1"
+ resolved "https://registry.yarnpkg.com/binaryextensions/-/binaryextensions-2.1.1.tgz#3209a51ca4a4ad541a3b8d3d6a6d5b83a2485935"
blank-object@^1.0.1:
version "1.0.2"
@@ -993,8 +1016,8 @@ bower-endpoint-parser@0.2.2:
resolved "https://registry.yarnpkg.com/bower-endpoint-parser/-/bower-endpoint-parser-0.2.2.tgz#00b565adbfab6f2d35addde977e97962acbcb3f6"
brace-expansion@^1.0.0, brace-expansion@^1.1.7:
- version "1.1.8"
- resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.8.tgz#c07b211c7c952ec1f8efd51a77ef0d1d3990a292"
+ version "1.1.11"
+ resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd"
dependencies:
balanced-match "^1.0.0"
concat-map "0.0.1"
@@ -1008,16 +1031,14 @@ braces@^1.8.2:
repeat-element "^1.1.2"
braces@^2.3.1:
- version "2.3.1"
- resolved "https://registry.yarnpkg.com/braces/-/braces-2.3.1.tgz#7086c913b4e5a08dbe37ac0ee6a2500c4ba691bb"
+ version "2.3.2"
+ resolved "https://registry.yarnpkg.com/braces/-/braces-2.3.2.tgz#5979fd3f14cd531565e5fa2df1abfff1dfaee729"
dependencies:
arr-flatten "^1.1.0"
array-unique "^0.3.2"
- define-property "^1.0.0"
extend-shallow "^2.0.1"
fill-range "^4.0.0"
isobject "^3.0.1"
- kind-of "^6.0.2"
repeat-element "^1.1.2"
snapdragon "^0.8.1"
snapdragon-node "^2.0.1"
@@ -1025,11 +1046,12 @@ braces@^2.3.1:
to-regex "^3.0.1"
broccoli-asset-rev@^2.4.5:
- version "2.6.0"
- resolved "https://registry.yarnpkg.com/broccoli-asset-rev/-/broccoli-asset-rev-2.6.0.tgz#0633fc3a0b2ba0c2c1d56fa9feb7b331fc83be6d"
+ version "2.7.0"
+ resolved "https://registry.yarnpkg.com/broccoli-asset-rev/-/broccoli-asset-rev-2.7.0.tgz#c73da1d97c4180366fa442a87624ca1b7fb99161"
dependencies:
broccoli-asset-rewrite "^1.1.0"
broccoli-filter "^1.2.2"
+ broccoli-persistent-filter "^1.4.3"
json-stable-stringify "^1.0.0"
minimatch "^3.0.4"
rsvp "^3.0.6"
@@ -1041,8 +1063,8 @@ broccoli-asset-rewrite@^1.1.0:
broccoli-filter "^1.2.3"
broccoli-babel-transpiler@^6.0.0, broccoli-babel-transpiler@^6.1.2:
- version "6.1.2"
- resolved "https://registry.yarnpkg.com/broccoli-babel-transpiler/-/broccoli-babel-transpiler-6.1.2.tgz#26019c045b5ea3e44cfef62821302f9bd483cabd"
+ version "6.1.4"
+ resolved "https://registry.yarnpkg.com/broccoli-babel-transpiler/-/broccoli-babel-transpiler-6.1.4.tgz#8be8074c42abf2e17ff79b2d2a21df5c51143c82"
dependencies:
babel-core "^6.14.0"
broccoli-funnel "^1.0.0"
@@ -1053,17 +1075,11 @@ broccoli-babel-transpiler@^6.0.0, broccoli-babel-transpiler@^6.1.2:
heimdalljs-logger "^0.1.7"
json-stable-stringify "^1.0.0"
rsvp "^3.5.0"
- workerpool "^2.2.1"
-
-broccoli-brocfile-loader@^0.18.0:
- version "0.18.0"
- resolved "https://registry.yarnpkg.com/broccoli-brocfile-loader/-/broccoli-brocfile-loader-0.18.0.tgz#2e86021c805c34ffc8d29a2fb721cf273e819e4b"
- dependencies:
- findup-sync "^0.4.2"
+ workerpool "^2.3.0"
broccoli-builder@^0.18.8:
- version "0.18.10"
- resolved "https://registry.yarnpkg.com/broccoli-builder/-/broccoli-builder-0.18.10.tgz#9767e0061ff5b5e6eb1619d1a972ef2c7fd07631"
+ version "0.18.11"
+ resolved "https://registry.yarnpkg.com/broccoli-builder/-/broccoli-builder-0.18.11.tgz#a42393c7b10bb0380df255a616307945f5e26efb"
dependencies:
heimdalljs "^0.2.0"
promise-map-series "^0.2.1"
@@ -1160,8 +1176,8 @@ broccoli-filter@^0.1.11:
walk-sync "^0.1.3"
broccoli-filter@^1.0.1, broccoli-filter@^1.2.2, broccoli-filter@^1.2.3:
- version "1.2.4"
- resolved "https://registry.yarnpkg.com/broccoli-filter/-/broccoli-filter-1.2.4.tgz#409afb94b9a3a6da9fac8134e91e205f40cc7330"
+ version "1.3.0"
+ resolved "https://registry.yarnpkg.com/broccoli-filter/-/broccoli-filter-1.3.0.tgz#71e3a8e32a17f309e12261919c5b1006d6766de6"
dependencies:
broccoli-kitchen-sink-helpers "^0.3.1"
broccoli-plugin "^1.0.0"
@@ -1269,12 +1285,12 @@ broccoli-merge-trees@^2.0.0:
broccoli-plugin "^1.3.0"
merge-trees "^1.0.1"
-broccoli-middleware@^1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/broccoli-middleware/-/broccoli-middleware-1.0.0.tgz#92f4e1fb9a791ea986245a7077f35cc648dab097"
+broccoli-middleware@^1.2.1:
+ version "1.2.1"
+ resolved "https://registry.yarnpkg.com/broccoli-middleware/-/broccoli-middleware-1.2.1.tgz#a21f255f8bfe5a21c2f0fbf2417addd9d24c9436"
dependencies:
handlebars "^4.0.4"
- mime "^1.2.11"
+ mime-types "^2.1.18"
broccoli-persistent-filter@^1.0.3, broccoli-persistent-filter@^1.1.5, broccoli-persistent-filter@^1.1.6, broccoli-persistent-filter@^1.2.0, broccoli-persistent-filter@^1.4.0, broccoli-persistent-filter@^1.4.3:
version "1.4.3"
@@ -1303,6 +1319,14 @@ broccoli-plugin@^1.0.0, broccoli-plugin@^1.1.0, broccoli-plugin@^1.2.0, broccoli
rimraf "^2.3.4"
symlink-or-copy "^1.1.8"
+broccoli-replace@^0.12.0:
+ version "0.12.0"
+ resolved "https://registry.yarnpkg.com/broccoli-replace/-/broccoli-replace-0.12.0.tgz#36460a984c45c61731638c53068b0ab12ea8fdb7"
+ dependencies:
+ applause "1.2.2"
+ broccoli-persistent-filter "^1.2.0"
+ minimatch "^3.0.0"
+
broccoli-rollup@^1.2.0:
version "1.3.0"
resolved "https://registry.yarnpkg.com/broccoli-rollup/-/broccoli-rollup-1.3.0.tgz#43a0a7798555bab54217009eb470a4ff5a056df0"
@@ -1320,13 +1344,13 @@ broccoli-rollup@^1.2.0:
walk-sync "^0.3.1"
broccoli-sass-source-maps@^2.1.0:
- version "2.1.1"
- resolved "https://registry.yarnpkg.com/broccoli-sass-source-maps/-/broccoli-sass-source-maps-2.1.1.tgz#5d71d3734234acb102000e5d7776d4c722aad756"
+ version "2.2.0"
+ resolved "https://registry.yarnpkg.com/broccoli-sass-source-maps/-/broccoli-sass-source-maps-2.2.0.tgz#1f1a0794136152b096188638b59b42b17a4bdc68"
dependencies:
broccoli-caching-writer "^3.0.3"
include-path-searcher "^0.1.0"
mkdirp "^0.3.5"
- node-sass "^4.1.0"
+ node-sass "^4.7.2"
object-assign "^2.0.0"
rsvp "^3.0.6"
@@ -1382,10 +1406,11 @@ broccoli-templater@^1.0.0:
broccoli-stew "^1.2.0"
lodash.template "^3.3.2"
-broccoli-uglify-sourcemap@^2.0.0:
- version "2.0.1"
- resolved "https://registry.yarnpkg.com/broccoli-uglify-sourcemap/-/broccoli-uglify-sourcemap-2.0.1.tgz#e8f2f6c49e04b6e921f1ecd30e12f06fb75e585f"
+broccoli-uglify-sourcemap@^2.1.1:
+ version "2.1.1"
+ resolved "https://registry.yarnpkg.com/broccoli-uglify-sourcemap/-/broccoli-uglify-sourcemap-2.1.1.tgz#33005537e18a322a181a5aea3e46d145b3355630"
dependencies:
+ async-promise-queue "^1.0.4"
broccoli-plugin "^1.2.1"
debug "^3.1.0"
lodash.defaultsdeep "^4.6.0"
@@ -1395,6 +1420,7 @@ broccoli-uglify-sourcemap@^2.0.0:
symlink-or-copy "^1.0.1"
uglify-es "^3.1.3"
walk-sync "^0.3.2"
+ workerpool "^2.3.0"
broccoli-unwatched-tree@^0.1.1:
version "0.1.3"
@@ -1409,12 +1435,16 @@ broccoli-writer@^0.1.1, broccoli-writer@~0.1.1:
quick-temp "^0.1.0"
rsvp "^3.0.6"
+browser-stdout@1.3.0:
+ version "1.3.0"
+ resolved "https://registry.yarnpkg.com/browser-stdout/-/browser-stdout-1.3.0.tgz#f351d32969d32fa5d7a5567154263d928ae3bd1f"
+
browserslist@^2.1.2:
- version "2.10.0"
- resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-2.10.0.tgz#bac5ee1cc69ca9d96403ffb8a3abdc5b6aed6346"
+ version "2.11.3"
+ resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-2.11.3.tgz#fe36167aed1bbcde4827ebfe71347a2cc70b99b2"
dependencies:
- caniuse-lite "^1.0.30000780"
- electron-to-chromium "^1.3.28"
+ caniuse-lite "^1.0.30000792"
+ electron-to-chromium "^1.3.30"
bser@^2.0.0:
version "2.0.0"
@@ -1422,6 +1452,10 @@ bser@^2.0.0:
dependencies:
node-int64 "^0.4.0"
+buffer-from@^1.0.0:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.0.0.tgz#4cb8832d23612589b0406e9e2956c17f06fdf531"
+
builtin-modules@^1.0.0:
version "1.1.1"
resolved "https://registry.yarnpkg.com/builtin-modules/-/builtin-modules-1.1.1.tgz#270f076c5a72c02f5b65a47df94c5fe3a278892f"
@@ -1452,6 +1486,18 @@ cache-base@^1.0.1:
union-value "^1.0.0"
unset-value "^1.0.0"
+cacheable-request@^2.1.1:
+ version "2.1.4"
+ resolved "https://registry.yarnpkg.com/cacheable-request/-/cacheable-request-2.1.4.tgz#0d808801b6342ad33c91df9d0b44dc09b91e5c3d"
+ dependencies:
+ clone-response "1.0.2"
+ get-stream "3.0.0"
+ http-cache-semantics "3.8.1"
+ keyv "3.0.0"
+ lowercase-keys "1.0.0"
+ normalize-url "2.0.1"
+ responselike "1.0.2"
+
calculate-cache-key-for-tree@^1.0.0, calculate-cache-key-for-tree@^1.1.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/calculate-cache-key-for-tree/-/calculate-cache-key-for-tree-1.1.0.tgz#0c3e42c9c134f3c9de5358c0f16793627ea976d6"
@@ -1497,9 +1543,9 @@ can-symlink@^1.0.0:
dependencies:
tmp "0.0.28"
-caniuse-lite@^1.0.30000780:
- version "1.0.30000783"
- resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000783.tgz#9b5499fb1b503d2345d12aa6b8612852f4276ffd"
+caniuse-lite@^1.0.30000792:
+ version "1.0.30000830"
+ resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000830.tgz#cb96b8a2dd3cbfe04acea2af3c4e894249095328"
capture-exit@^1.1.0:
version "1.2.0"
@@ -1547,7 +1593,7 @@ chai-files@^1.0.0, chai-files@^1.1.0:
dependencies:
assertion-error "^1.0.1"
-chai@^3.3.0:
+chai@^3.3.0, chai@^3.5.0:
version "3.5.0"
resolved "https://registry.yarnpkg.com/chai/-/chai-3.5.0.tgz#4d02637b067fe958bdbfdd3a40ec56fef7373247"
dependencies:
@@ -1586,13 +1632,13 @@ chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3:
strip-ansi "^3.0.0"
supports-color "^2.0.0"
-chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0:
- version "2.3.0"
- resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.3.0.tgz#b5ea48efc9c1793dccc9b4767c93914d3f2d52ba"
+chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.3.1:
+ version "2.3.2"
+ resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.3.2.tgz#250dc96b07491bfd601e648d66ddf5f60c7a5c65"
dependencies:
- ansi-styles "^3.1.0"
+ ansi-styles "^3.2.1"
escape-string-regexp "^1.0.5"
- supports-color "^4.0.0"
+ supports-color "^5.3.0"
chardet@^0.4.0:
version "0.4.2"
@@ -1667,9 +1713,9 @@ cli-cursor@^2.1.0:
dependencies:
restore-cursor "^2.0.0"
-cli-spinners@^1.0.0:
- version "1.1.0"
- resolved "https://registry.yarnpkg.com/cli-spinners/-/cli-spinners-1.1.0.tgz#f1847b168844d917a671eb9d147e3df497c90d06"
+cli-spinners@^1.1.0:
+ version "1.3.1"
+ resolved "https://registry.yarnpkg.com/cli-spinners/-/cli-spinners-1.3.1.tgz#002c1990912d0d59580c93bd36c056de99e4259a"
cli-table2@^0.2.0:
version "0.2.0"
@@ -1706,9 +1752,19 @@ cliui@^3.2.0:
strip-ansi "^3.0.1"
wrap-ansi "^2.0.0"
+clone-response@1.0.2:
+ version "1.0.2"
+ resolved "https://registry.yarnpkg.com/clone-response/-/clone-response-1.0.2.tgz#d1dc973920314df67fbeb94223b4ee350239e96b"
+ dependencies:
+ mimic-response "^1.0.0"
+
+clone@^1.0.2:
+ version "1.0.4"
+ resolved "https://registry.yarnpkg.com/clone/-/clone-1.0.4.tgz#da309cc263df15994c688ca902179ca3c7cd7c7e"
+
clone@^2.0.0:
- version "2.1.1"
- resolved "https://registry.yarnpkg.com/clone/-/clone-2.1.1.tgz#d217d1e961118e3ac9a4b8bba3285553bf647cdb"
+ version "2.1.2"
+ resolved "https://registry.yarnpkg.com/clone/-/clone-2.1.2.tgz#1b7f4b9f591f1e8f83670401600345a02887435f"
co@^4.6.0:
version "4.6.0"
@@ -1718,6 +1774,10 @@ code-point-at@^1.0.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77"
+coffee-script@^1.10.0:
+ version "1.12.7"
+ resolved "https://registry.yarnpkg.com/coffee-script/-/coffee-script-1.12.7.tgz#c05dae0cb79591d05b3070a8433a98c9a89ccc53"
+
collection-visit@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/collection-visit/-/collection-visit-1.0.0.tgz#4bc0373c164bc3291b4d368c829cf1a80a59dca0"
@@ -1740,12 +1800,12 @@ colors@1.0.3:
resolved "https://registry.yarnpkg.com/colors/-/colors-1.0.3.tgz#0433f44d809680fdeb60ed260f1b0c262e82a40b"
colors@^1.1.2:
- version "1.1.2"
- resolved "https://registry.yarnpkg.com/colors/-/colors-1.1.2.tgz#168a4701756b6a7f51a12ce0c97bfa28c084ed63"
+ version "1.2.1"
+ resolved "https://registry.yarnpkg.com/colors/-/colors-1.2.1.tgz#f4a3d302976aaf042356ba1ade3b1a2c62d9d794"
-combined-stream@^1.0.5, combined-stream@~1.0.5:
- version "1.0.5"
- resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.5.tgz#938370a57b4a51dea2c77c15d5c5fdf895164009"
+combined-stream@1.0.6, combined-stream@^1.0.5, combined-stream@~1.0.5:
+ version "1.0.6"
+ resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.6.tgz#723e7df6e801ac5613113a7e445a9b69cb632818"
dependencies:
delayed-stream "~1.0.0"
@@ -1753,7 +1813,7 @@ commander@0.6.1:
version "0.6.1"
resolved "https://registry.yarnpkg.com/commander/-/commander-0.6.1.tgz#fa68a14f6a945d54dbbe50d8cdb3320e9e3b1a06"
-commander@2.12.2, commander@^2.6.0, commander@^2.9.0, commander@~2.12.1:
+commander@2.12.2:
version "2.12.2"
resolved "https://registry.yarnpkg.com/commander/-/commander-2.12.2.tgz#0f5946c427ed9ec0d91a46bb9def53e54650e555"
@@ -1767,9 +1827,23 @@ commander@2.8.x:
dependencies:
graceful-readlink ">= 1.0.0"
+commander@2.9.0:
+ version "2.9.0"
+ resolved "https://registry.yarnpkg.com/commander/-/commander-2.9.0.tgz#9c99094176e12240cb22d6c5146098400fe0f7d4"
+ dependencies:
+ graceful-readlink ">= 1.0.0"
+
+commander@^2.6.0, commander@^2.9.0:
+ version "2.15.1"
+ resolved "https://registry.yarnpkg.com/commander/-/commander-2.15.1.tgz#df46e867d0fc2aec66a34662b406a9ccafff5b0f"
+
+commander@~2.13.0:
+ version "2.13.0"
+ resolved "https://registry.yarnpkg.com/commander/-/commander-2.13.0.tgz#6964bca67685df7c1f1430c584f07d7597885b9c"
+
common-tags@^1.4.0:
- version "1.5.1"
- resolved "https://registry.yarnpkg.com/common-tags/-/common-tags-1.5.1.tgz#e2e39931a013cd02253defeed89a1ad615a27f07"
+ version "1.7.2"
+ resolved "https://registry.yarnpkg.com/common-tags/-/common-tags-1.7.2.tgz#24d9768c63d253a56ecff93845b44b4df1d52771"
dependencies:
babel-runtime "^6.26.0"
@@ -1777,10 +1851,6 @@ component-bind@1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/component-bind/-/component-bind-1.0.0.tgz#00c608ab7dcd93897c0009651b1d3a8e1e73bbd1"
-component-emitter@1.1.2:
- version "1.1.2"
- resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.1.2.tgz#296594f2753daa63996d2af08d15a95116c9aec3"
-
component-emitter@1.2.1, component-emitter@^1.2.1:
version "1.2.1"
resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.2.1.tgz#137918d6d78283f7df7a6b7c5a63e140e69425e6"
@@ -1789,19 +1859,19 @@ component-inherit@0.0.3:
version "0.0.3"
resolved "https://registry.yarnpkg.com/component-inherit/-/component-inherit-0.0.3.tgz#645fc4adf58b72b649d5cae65135619db26ff143"
-compressible@~2.0.11:
- version "2.0.12"
- resolved "https://registry.yarnpkg.com/compressible/-/compressible-2.0.12.tgz#c59a5c99db76767e9876500e271ef63b3493bd66"
+compressible@~2.0.13:
+ version "2.0.13"
+ resolved "https://registry.yarnpkg.com/compressible/-/compressible-2.0.13.tgz#0d1020ab924b2fdb4d6279875c7d6daba6baa7a9"
dependencies:
- mime-db ">= 1.30.0 < 2"
+ mime-db ">= 1.33.0 < 2"
compression@^1.4.4:
- version "1.7.1"
- resolved "https://registry.yarnpkg.com/compression/-/compression-1.7.1.tgz#eff2603efc2e22cf86f35d2eb93589f9875373db"
+ version "1.7.2"
+ resolved "http://registry.npmjs.org/compression/-/compression-1.7.2.tgz#aaffbcd6aaf854b44ebb280353d5ad1651f59a69"
dependencies:
accepts "~1.3.4"
bytes "3.0.0"
- compressible "~2.0.11"
+ compressible "~2.0.13"
debug "2.6.9"
on-headers "~1.0.1"
safe-buffer "5.1.1"
@@ -1812,16 +1882,17 @@ concat-map@0.0.1:
resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b"
concat-stream@^1.4.7, concat-stream@^1.6.0:
- version "1.6.0"
- resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.0.tgz#0aac662fd52be78964d5532f694784e70110acf7"
+ version "1.6.2"
+ resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34"
dependencies:
+ buffer-from "^1.0.0"
inherits "^2.0.3"
readable-stream "^2.2.2"
typedarray "^0.0.6"
configstore@^3.0.0:
- version "3.1.1"
- resolved "https://registry.yarnpkg.com/configstore/-/configstore-3.1.1.tgz#094ee662ab83fad9917678de114faaea8fcdca90"
+ version "3.1.2"
+ resolved "https://registry.yarnpkg.com/configstore/-/configstore-3.1.2.tgz#c6f25defaeef26df12dd33414b001fe81a543f8f"
dependencies:
dot-prop "^4.1.0"
graceful-fs "^4.1.2"
@@ -1834,14 +1905,16 @@ console-control-strings@^1.0.0, console-control-strings@~1.1.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/console-control-strings/-/console-control-strings-1.1.0.tgz#3d7cf4464db6446ea644bf4b39507f9851008e8e"
-console-ui@^2.0.0:
- version "2.0.1"
- resolved "https://registry.yarnpkg.com/console-ui/-/console-ui-2.0.1.tgz#56d0721ebcc44e6c9c3de02f355f898aba41ea79"
+console-ui@^2.1.0:
+ version "2.2.2"
+ resolved "https://registry.yarnpkg.com/console-ui/-/console-ui-2.2.2.tgz#b294a2934de869dd06789ab4be69555411edef29"
dependencies:
chalk "^2.1.0"
inquirer "^2"
- ora "^1.3.0"
+ json-stable-stringify "^1.0.1"
+ ora "^2.0.0"
through "^2.3.8"
+ user-info "^1.0.0"
consolidate@^0.14.0:
version "0.14.5"
@@ -1882,8 +1955,8 @@ copy-descriptor@^0.1.0:
resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d"
core-js@^2.4.0, core-js@^2.5.0:
- version "2.5.3"
- resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.5.3.tgz#8acc38345824f16d8365b7c9b4259168e8ed603e"
+ version "2.5.5"
+ resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.5.5.tgz#b14dde936c640c0579a6b50cabcc132dd6127e3b"
core-object@^1.1.0:
version "1.1.0"
@@ -1914,6 +1987,16 @@ cross-spawn@^5.0.1, cross-spawn@^5.1.0:
shebang-command "^1.2.0"
which "^1.2.9"
+cross-spawn@^6.0.0:
+ version "6.0.5"
+ resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4"
+ dependencies:
+ nice-try "^1.0.4"
+ path-key "^2.0.1"
+ semver "^5.5.0"
+ shebang-command "^1.2.0"
+ which "^1.2.9"
+
cryptiles@2.x.x:
version "2.0.5"
resolved "https://registry.yarnpkg.com/cryptiles/-/cryptiles-2.0.5.tgz#3bdfecdc608147c1c67202fa291e7dca59eaa3b8"
@@ -1930,6 +2013,12 @@ crypto-random-string@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/crypto-random-string/-/crypto-random-string-1.0.0.tgz#a230f64f568310e1498009940790ec99545bca7e"
+cson-parser@^1.1.0:
+ version "1.3.5"
+ resolved "https://registry.yarnpkg.com/cson-parser/-/cson-parser-1.3.5.tgz#7ec675e039145533bf2a6a856073f1599d9c2d24"
+ dependencies:
+ coffee-script "^1.10.0"
+
currently-unhandled@^0.4.1:
version "0.4.1"
resolved "https://registry.yarnpkg.com/currently-unhandled/-/currently-unhandled-0.4.1.tgz#988df33feab191ef799a61369dd76c17adf957ea"
@@ -1958,19 +2047,19 @@ debug@2.2.0:
dependencies:
ms "0.7.1"
-debug@2.3.3:
- version "2.3.3"
- resolved "https://registry.yarnpkg.com/debug/-/debug-2.3.3.tgz#40c453e67e6e13c901ddec317af8986cda9eff8c"
+debug@2.6.8:
+ version "2.6.8"
+ resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.8.tgz#e731531ca2ede27d188222427da17821d68ff4fc"
dependencies:
- ms "0.7.2"
+ ms "2.0.0"
-debug@2.6.9, debug@^2.1.0, debug@^2.1.1, debug@^2.1.3, debug@^2.2.0, debug@^2.3.3, debug@^2.4.0, debug@^2.6.8, debug@~2.6.7:
+debug@2.6.9, debug@^2.1.0, debug@^2.1.1, debug@^2.1.3, debug@^2.2.0, debug@^2.3.3, debug@^2.4.0, debug@^2.6.8:
version "2.6.9"
resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f"
dependencies:
ms "2.0.0"
-debug@^3.0.0, debug@^3.0.1, debug@^3.1.0:
+debug@^3.0.0, debug@^3.1.0, debug@~3.1.0:
version "3.1.0"
resolved "https://registry.yarnpkg.com/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261"
dependencies:
@@ -1984,6 +2073,12 @@ decode-uri-component@^0.2.0:
version "0.2.0"
resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545"
+decompress-response@^3.3.0:
+ version "3.3.0"
+ resolved "https://registry.yarnpkg.com/decompress-response/-/decompress-response-3.3.0.tgz#80a4dd323748384bfa248083622aedec982adff3"
+ dependencies:
+ mimic-response "^1.0.0"
+
deep-eql@^0.1.3:
version "0.1.3"
resolved "https://registry.yarnpkg.com/deep-eql/-/deep-eql-0.1.3.tgz#ef558acab8de25206cd713906d74e56930eb69f2"
@@ -2004,6 +2099,12 @@ deep-is@~0.1.3:
version "0.1.3"
resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34"
+defaults@^1.0.3:
+ version "1.0.3"
+ resolved "https://registry.yarnpkg.com/defaults/-/defaults-1.0.3.tgz#c656051e9817d9ff08ed881477f3fe4019f3ef7d"
+ dependencies:
+ clone "^1.0.2"
+
define-property@^0.2.5:
version "0.2.5"
resolved "https://registry.yarnpkg.com/define-property/-/define-property-0.2.5.tgz#c35b1ef918ec3c990f9a5bc57be04aacec5c8116"
@@ -2043,20 +2144,18 @@ delegates@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/delegates/-/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a"
-depd@1.1.1, depd@~1.1.1:
+depd@1.1.1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/depd/-/depd-1.1.1.tgz#5783b4e1c459f06fa5ca27f991f3d06e7a310359"
+depd@~1.1.1, depd@~1.1.2:
+ version "1.1.2"
+ resolved "https://registry.yarnpkg.com/depd/-/depd-1.1.2.tgz#9bcd52e14c097763e749b274c4346ed2e560b5a9"
+
destroy@~1.0.4:
version "1.0.4"
resolved "https://registry.yarnpkg.com/destroy/-/destroy-1.0.4.tgz#978857442c44749e4206613e37946205826abd80"
-detect-file@^0.1.0:
- version "0.1.0"
- resolved "https://registry.yarnpkg.com/detect-file/-/detect-file-0.1.0.tgz#4935dedfd9488648e006b0129566e9386711ea63"
- dependencies:
- fs-exists-sync "^0.1.0"
-
detect-file@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/detect-file/-/detect-file-1.0.0.tgz#f0d66d03672a825cb1b73bdb3fe62310c8e552b7"
@@ -2075,13 +2174,17 @@ diff@1.4.0:
version "1.4.0"
resolved "https://registry.yarnpkg.com/diff/-/diff-1.4.0.tgz#7f28d2eb9ee7b15a97efd89ce63dcfdaa3ccbabf"
+diff@3.2.0:
+ version "3.2.0"
+ resolved "https://registry.yarnpkg.com/diff/-/diff-3.2.0.tgz#c9ce393a4b7cbd0b058a725c93df299027868ff9"
+
diff@^3.2.0:
- version "3.4.0"
- resolved "https://registry.yarnpkg.com/diff/-/diff-3.4.0.tgz#b1d85507daf3964828de54b37d0d73ba67dda56c"
+ version "3.5.0"
+ resolved "https://registry.yarnpkg.com/diff/-/diff-3.5.0.tgz#800c0dd1e0a8bfbc95835c202ad220fe317e5a12"
-doctrine@^2.0.2:
- version "2.0.2"
- resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.0.2.tgz#68f96ce8efc56cc42651f1faadb4f175273b0075"
+doctrine@^2.1.0:
+ version "2.1.0"
+ resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.1.0.tgz#5cd01fc101621b42c4cd7f5d1a66243716d3f39d"
dependencies:
esutils "^2.0.2"
@@ -2091,6 +2194,10 @@ dot-prop@^4.1.0:
dependencies:
is-obj "^1.0.0"
+duplexer3@^0.1.4:
+ version "0.1.4"
+ resolved "https://registry.yarnpkg.com/duplexer3/-/duplexer3-0.1.4.tgz#ee01dd1cac0ed3cbc7fdbea37dc0a8f1ce002ce2"
+
ecc-jsbn@~0.1.1:
version "0.1.1"
resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.1.tgz#0fc73a9ed5f0d53c38193398523ef7e543777505"
@@ -2098,29 +2205,28 @@ ecc-jsbn@~0.1.1:
jsbn "~0.1.0"
editions@^1.1.1:
- version "1.3.3"
- resolved "https://registry.yarnpkg.com/editions/-/editions-1.3.3.tgz#0907101bdda20fac3cbe334c27cbd0688dc99a5b"
+ version "1.3.4"
+ resolved "https://registry.yarnpkg.com/editions/-/editions-1.3.4.tgz#3662cb592347c3168eb8e498a0ff73271d67f50b"
ee-first@1.1.1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/ee-first/-/ee-first-1.1.1.tgz#590c61156b0ae2f4f0255732a158b266bc56b21d"
-electron-to-chromium@^1.3.28:
- version "1.3.28"
- resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.28.tgz#8dd4e6458086644e9f9f0a1cf32e2a1f9dffd9ee"
+electron-to-chromium@^1.3.30:
+ version "1.3.42"
+ resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.42.tgz#95c33bf01d0cc405556aec899fe61fd4d76ea0f9"
-ember-basic-dropdown@^1.0.0-beta.3:
- version "1.0.0-beta.3"
- resolved "https://registry.yarnpkg.com/ember-basic-dropdown/-/ember-basic-dropdown-1.0.0-beta.3.tgz#c6fb53d4cc8e4ddc1ec9f09e23207f15be7b1f04"
+ember-basic-dropdown@^1.0.0-beta.5:
+ version "1.0.0-beta.5"
+ resolved "https://registry.yarnpkg.com/ember-basic-dropdown/-/ember-basic-dropdown-1.0.0-beta.5.tgz#c59afd762985d9217be79ccb4e3192406a7ef432"
dependencies:
- ember-cli-babel "^6.11.0"
+ ember-cli-babel "^6.12.0"
ember-cli-htmlbars "^2.0.3"
- ember-maybe-in-element "^0.1.0"
- ember-native-dom-helpers "^0.5.10"
+ ember-maybe-in-element "^0.1.3"
-ember-cli-babel@^6.0.0, ember-cli-babel@^6.0.0-beta.4, ember-cli-babel@^6.0.0-beta.7, ember-cli-babel@^6.10.0, ember-cli-babel@^6.11.0, ember-cli-babel@^6.3.0, ember-cli-babel@^6.4.1, ember-cli-babel@^6.6.0, ember-cli-babel@^6.8.1, ember-cli-babel@^6.8.2, ember-cli-babel@^6.9.0:
- version "6.11.0"
- resolved "https://registry.yarnpkg.com/ember-cli-babel/-/ember-cli-babel-6.11.0.tgz#79cb184bac3c05bfe181ddc306bac100ab1f9493"
+ember-cli-babel@6.12.0, ember-cli-babel@^6.0.0, ember-cli-babel@^6.0.0-beta.4, ember-cli-babel@^6.0.0-beta.7, ember-cli-babel@^6.10.0, ember-cli-babel@^6.11.0, ember-cli-babel@^6.12.0, ember-cli-babel@^6.3.0, ember-cli-babel@^6.6.0, ember-cli-babel@^6.8.1, ember-cli-babel@^6.8.2, ember-cli-babel@^6.9.0:
+ version "6.12.0"
+ resolved "https://registry.yarnpkg.com/ember-cli-babel/-/ember-cli-babel-6.12.0.tgz#3adcdbe1278da1fcd0b9038f1360cb4ac5d4414c"
dependencies:
amd-name-resolver "0.0.7"
babel-plugin-debug-macros "^0.1.11"
@@ -2150,14 +2256,14 @@ ember-cli-blueprint-test-helpers@^0.18.3:
tmp-sync "^1.0.0"
ember-cli-broccoli-sane-watcher@^2.0.4:
- version "2.0.4"
- resolved "https://registry.yarnpkg.com/ember-cli-broccoli-sane-watcher/-/ember-cli-broccoli-sane-watcher-2.0.4.tgz#f43f42f75b7509c212fb926cd9aea86ae19264c6"
+ version "2.1.1"
+ resolved "https://registry.yarnpkg.com/ember-cli-broccoli-sane-watcher/-/ember-cli-broccoli-sane-watcher-2.1.1.tgz#1687adada9022de26053fba833dc7dd10f03dd08"
dependencies:
broccoli-slow-trees "^3.0.1"
heimdalljs "^0.2.1"
heimdalljs-logger "^0.1.7"
rsvp "^3.0.18"
- sane "^1.1.1"
+ sane "^2.4.1"
ember-cli-dependency-checker@^2.0.1:
version "2.1.0"
@@ -2181,10 +2287,6 @@ ember-cli-get-component-path-option@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/ember-cli-get-component-path-option/-/ember-cli-get-component-path-option-1.0.0.tgz#0d7b595559e2f9050abed804f1d8eff1b08bc771"
-ember-cli-get-dependency-depth@^1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/ember-cli-get-dependency-depth/-/ember-cli-get-dependency-depth-1.0.0.tgz#e0afecf82a2d52f00f28ab468295281aec368d11"
-
ember-cli-htmlbars-inline-precompile@^1.0.0, ember-cli-htmlbars-inline-precompile@^1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/ember-cli-htmlbars-inline-precompile/-/ember-cli-htmlbars-inline-precompile-1.0.2.tgz#5b544f664d5d9911f08cd979c5f70d8cb0ca2add"
@@ -2229,28 +2331,6 @@ ember-cli-is-package-missing@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/ember-cli-is-package-missing/-/ember-cli-is-package-missing-1.0.0.tgz#6e6184cafb92635dd93ca6c946b104292d4e3390"
-ember-cli-legacy-blueprints@^0.1.2:
- version "0.1.5"
- resolved "https://registry.yarnpkg.com/ember-cli-legacy-blueprints/-/ember-cli-legacy-blueprints-0.1.5.tgz#93c15ca242ec5107d62a8af7ec30f6ac538f3ad9"
- dependencies:
- chalk "^1.1.1"
- ember-cli-get-component-path-option "^1.0.0"
- ember-cli-get-dependency-depth "^1.0.0"
- ember-cli-is-package-missing "^1.0.0"
- ember-cli-lodash-subset "^1.0.7"
- ember-cli-normalize-entity-name "^1.0.0"
- ember-cli-path-utils "^1.0.0"
- ember-cli-string-utils "^1.0.0"
- ember-cli-test-info "^1.0.0"
- ember-cli-valid-component-name "^1.0.0"
- ember-cli-version-checker "^1.1.7"
- ember-router-generator "^1.0.0"
- exists-sync "0.0.3"
- fs-extra "^0.24.0"
- inflection "^1.7.1"
- rsvp "^3.0.17"
- silent-error "^1.0.0"
-
ember-cli-lodash-subset@^1.0.7:
version "1.0.12"
resolved "https://registry.yarnpkg.com/ember-cli-lodash-subset/-/ember-cli-lodash-subset-1.0.12.tgz#af2e77eba5dcb0d77f3308d3a6fd7d3450f6e537"
@@ -2259,12 +2339,13 @@ ember-cli-lodash-subset@^2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/ember-cli-lodash-subset/-/ember-cli-lodash-subset-2.0.1.tgz#20cb68a790fe0fde2488ddfd8efbb7df6fe766f2"
-ember-cli-mirage@^0.4.0:
- version "0.4.1"
- resolved "https://registry.yarnpkg.com/ember-cli-mirage/-/ember-cli-mirage-0.4.1.tgz#bfdfe61e5e74dc3881ed31f12112dae1a29f0d4c"
+ember-cli-mirage@^0.4.3:
+ version "0.4.3"
+ resolved "https://registry.yarnpkg.com/ember-cli-mirage/-/ember-cli-mirage-0.4.3.tgz#81470c2b9cdb2b88661c56be6aacb928945a9b3b"
dependencies:
broccoli-funnel "^1.0.2"
broccoli-merge-trees "^1.1.0"
+ broccoli-replace "^0.12.0"
broccoli-stew "^1.5.0"
chalk "^1.1.1"
ember-cli-babel "^6.8.2"
@@ -2319,15 +2400,14 @@ ember-cli-qunit@^4.3.2:
ember-cli-babel "^6.11.0"
ember-qunit "^3.3.2"
-ember-cli-sass@^7.1.0:
- version "7.1.2"
- resolved "https://registry.yarnpkg.com/ember-cli-sass/-/ember-cli-sass-7.1.2.tgz#5756a92a526754878b32f3be4367cfe4bf2b5514"
+ember-cli-sass@^7.1.7:
+ version "7.1.7"
+ resolved "https://registry.yarnpkg.com/ember-cli-sass/-/ember-cli-sass-7.1.7.tgz#66899134788ec8d2406a45f5346d4db47a2aa012"
dependencies:
broccoli-funnel "^1.0.0"
broccoli-merge-trees "^1.1.0"
broccoli-sass-source-maps "^2.1.0"
- ember-cli-babel "^6.6.0"
- ember-cli-version-checker "^1.0.2"
+ ember-cli-version-checker "^2.1.0"
ember-cli-string-utils@^1.0.0, ember-cli-string-utils@^1.1.0:
version "1.1.0"
@@ -2361,11 +2441,11 @@ ember-cli-test-loader@^2.2.0:
dependencies:
ember-cli-babel "^6.8.1"
-ember-cli-uglify@^2.0.0:
- version "2.0.0"
- resolved "https://registry.yarnpkg.com/ember-cli-uglify/-/ember-cli-uglify-2.0.0.tgz#b096727d7d1718acc9bfe5d1bc81ce26cafdf6ca"
+ember-cli-uglify@^2.1.0:
+ version "2.1.0"
+ resolved "https://registry.yarnpkg.com/ember-cli-uglify/-/ember-cli-uglify-2.1.0.tgz#4a0641fe4768d7ab7d4807aca9924cc77c544184"
dependencies:
- broccoli-uglify-sourcemap "^2.0.0"
+ broccoli-uglify-sourcemap "^2.1.1"
lodash.defaultsdeep "^4.6.0"
ember-cli-valid-component-name@^1.0.0:
@@ -2374,12 +2454,6 @@ ember-cli-valid-component-name@^1.0.0:
dependencies:
silent-error "^1.0.0"
-ember-cli-version-checker@^1.0.2, ember-cli-version-checker@^1.1.4, ember-cli-version-checker@^1.1.7, ember-cli-version-checker@^1.2.0:
- version "1.3.1"
- resolved "https://registry.yarnpkg.com/ember-cli-version-checker/-/ember-cli-version-checker-1.3.1.tgz#0bc2d134c830142da64bf9627a0eded10b61ae72"
- dependencies:
- semver "^5.3.0"
-
ember-cli-version-checker@^2.0.0, ember-cli-version-checker@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/ember-cli-version-checker/-/ember-cli-version-checker-2.1.0.tgz#fc79a56032f3717cf844ada7cbdec1a06fedb604"
@@ -2387,16 +2461,15 @@ ember-cli-version-checker@^2.0.0, ember-cli-version-checker@^2.1.0:
resolve "^1.3.3"
semver "^5.3.0"
-ember-cli@~2.17.1:
- version "2.17.1"
- resolved "https://registry.yarnpkg.com/ember-cli/-/ember-cli-2.17.1.tgz#915a140732cd28d6c3d5b2e890731864ea55ad5b"
+ember-cli@~3.1.2:
+ version "3.1.2"
+ resolved "https://registry.yarnpkg.com/ember-cli/-/ember-cli-3.1.2.tgz#bd8198b19f37b28d2ab7a795fe19efb7516a7e54"
dependencies:
- amd-name-resolver "1.0.0"
+ amd-name-resolver "^1.2.0"
babel-plugin-transform-es2015-modules-amd "^6.24.0"
bower-config "^1.3.0"
bower-endpoint-parser "0.2.2"
broccoli-babel-transpiler "^6.0.0"
- broccoli-brocfile-loader "^0.18.0"
broccoli-builder "^0.18.8"
broccoli-concat "^3.2.2"
broccoli-config-loader "^1.0.0"
@@ -2405,7 +2478,7 @@ ember-cli@~2.17.1:
broccoli-funnel "^2.0.0"
broccoli-funnel-reducer "^1.0.0"
broccoli-merge-trees "^2.0.0"
- broccoli-middleware "^1.0.0"
+ broccoli-middleware "^1.2.1"
broccoli-source "^1.1.0"
broccoli-stew "^1.2.0"
calculate-cache-key-for-tree "^1.0.0"
@@ -2414,32 +2487,31 @@ ember-cli@~2.17.1:
clean-base-url "^1.0.0"
compression "^1.4.4"
configstore "^3.0.0"
- console-ui "^2.0.0"
+ console-ui "^2.1.0"
core-object "^3.1.3"
dag-map "^2.0.2"
diff "^3.2.0"
ember-cli-broccoli-sane-watcher "^2.0.4"
ember-cli-is-package-missing "^1.0.0"
- ember-cli-legacy-blueprints "^0.1.2"
ember-cli-lodash-subset "^2.0.1"
ember-cli-normalize-entity-name "^1.0.0"
ember-cli-preprocess-registry "^3.1.0"
ember-cli-string-utils "^1.0.0"
- ember-try "^0.2.15"
ensure-posix-path "^1.0.2"
- execa "^0.8.0"
+ execa "^0.9.0"
exists-sync "0.0.4"
exit "^0.1.2"
express "^4.12.3"
filesize "^3.1.3"
find-up "^2.1.0"
- fs-extra "^4.0.0"
+ find-yarn-workspace-root "^1.0.0"
+ fs-extra "^5.0.0"
fs-tree-diff "^0.5.2"
get-caller-file "^1.0.0"
git-repo-info "^1.4.1"
- glob "7.1.1"
+ glob "^7.1.2"
heimdalljs "^0.2.3"
- heimdalljs-fs-monitor "^0.1.0"
+ heimdalljs-fs-monitor "^0.2.0"
heimdalljs-graph "^0.3.1"
heimdalljs-logger "^0.1.7"
http-proxy "^1.9.0"
@@ -2456,25 +2528,26 @@ ember-cli@~2.17.1:
morgan "^1.8.1"
node-modules-path "^1.0.0"
nopt "^3.0.6"
- npm-package-arg "^4.1.1"
+ npm-package-arg "^6.0.0"
portfinder "^1.0.7"
promise-map-series "^0.2.1"
quick-temp "^0.1.8"
resolve "^1.3.0"
rsvp "^4.7.0"
- sane "^1.6.0"
+ sane "^2.2.0"
semver "^5.1.1"
silent-error "^1.0.0"
sort-package-json "^1.4.0"
symlink-or-copy "^1.1.8"
temp "0.8.3"
- testem "^1.18.0"
+ testem "^2.0.0"
tiny-lr "^1.0.3"
tree-sync "^1.2.1"
uuid "^3.0.0"
validate-npm-package-name "^3.0.0"
walk-sync "^0.3.0"
- yam "0.0.22"
+ watch-detector "^0.1.0"
+ yam "^0.0.24"
ember-code-example-component@^0.2.0:
version "0.2.0"
@@ -2495,19 +2568,27 @@ ember-code-snippet@2.0.0:
es6-promise "^1.0.0"
glob "^4.0.4"
+ember-compatibility-helpers@^1.0.0-beta.2:
+ version "1.0.0-beta.2"
+ resolved "https://registry.yarnpkg.com/ember-compatibility-helpers/-/ember-compatibility-helpers-1.0.0-beta.2.tgz#00cb134af45f9562fa47a23f4da81a63aad41943"
+ dependencies:
+ babel-plugin-debug-macros "^0.1.11"
+ ember-cli-version-checker "^2.0.0"
+ semver "^5.4.1"
+
ember-concurrency@^0.8.12:
- version "0.8.12"
- resolved "https://registry.yarnpkg.com/ember-concurrency/-/ember-concurrency-0.8.12.tgz#fb91180e5efeb1024cfa2cfb99d2fe6721930c91"
+ version "0.8.17"
+ resolved "https://registry.yarnpkg.com/ember-concurrency/-/ember-concurrency-0.8.17.tgz#be47a90342f1960f4f57284c2fe5f7ce2396142a"
dependencies:
babel-core "^6.24.1"
ember-cli-babel "^6.8.2"
- ember-getowner-polyfill "^2.0.0"
ember-maybe-import-regenerator "^0.1.5"
-ember-data@^2.17.0:
- version "2.17.0"
- resolved "https://registry.yarnpkg.com/ember-data/-/ember-data-2.17.0.tgz#d952cf98d7461abf41ed6d248cf2a5836c623276"
+ember-data@^3.1.1:
+ version "3.1.1"
+ resolved "https://registry.yarnpkg.com/ember-data/-/ember-data-3.1.1.tgz#8c17c97a4932b0a0a405cc3e38c43140880366d2"
dependencies:
+ "@ember/ordered-set" "^1.0.0"
amd-name-resolver "0.0.7"
babel-plugin-ember-modules-api-polyfill "^1.4.2"
babel-plugin-feature-flags "^0.3.1"
@@ -2527,7 +2608,7 @@ ember-data@^2.17.0:
ember-cli-path-utils "^1.0.0"
ember-cli-string-utils "^1.0.0"
ember-cli-test-info "^1.0.0"
- ember-cli-version-checker "^1.1.4"
+ ember-cli-version-checker "^2.1.0"
ember-inflector "^2.0.0"
ember-runtime-enumerable-includes-polyfill "^2.0.0"
exists-sync "0.0.3"
@@ -2535,6 +2616,7 @@ ember-data@^2.17.0:
heimdalljs "^0.3.0"
inflection "^1.8.0"
npm-git-info "^1.0.0"
+ resolve "^1.5.0"
semver "^5.1.0"
silent-error "^1.0.0"
@@ -2554,14 +2636,14 @@ ember-factory-for-polyfill@^1.3.1:
dependencies:
ember-cli-version-checker "^2.1.0"
-ember-fetch@^3.4.0:
- version "3.4.3"
- resolved "https://registry.yarnpkg.com/ember-fetch/-/ember-fetch-3.4.3.tgz#fb8ba73148bb2399a82b037e4fdf9a953cd496ba"
+ember-fetch@^3.4.5:
+ version "3.4.5"
+ resolved "https://registry.yarnpkg.com/ember-fetch/-/ember-fetch-3.4.5.tgz#2967df9cbdbe0993402588216332580be3950b92"
dependencies:
broccoli-funnel "^1.2.0"
broccoli-stew "^1.4.2"
broccoli-templater "^1.0.0"
- ember-cli-babel "^6.8.1"
+ ember-cli-babel "^6.8.2"
node-fetch "^2.0.0-alpha.9"
whatwg-fetch "^2.0.3"
@@ -2572,7 +2654,7 @@ ember-get-config@^0.2.2:
broccoli-file-creator "^1.1.1"
ember-cli-babel "^6.3.0"
-ember-getowner-polyfill@^2.0.0, ember-getowner-polyfill@^2.0.1:
+ember-getowner-polyfill@^2.0.1:
version "2.2.0"
resolved "https://registry.yarnpkg.com/ember-getowner-polyfill/-/ember-getowner-polyfill-2.2.0.tgz#38e7dccbcac69d5ec694000329ec0b2be651d2b2"
dependencies:
@@ -2580,11 +2662,11 @@ ember-getowner-polyfill@^2.0.0, ember-getowner-polyfill@^2.0.1:
ember-factory-for-polyfill "^1.3.1"
ember-hash-helper-polyfill@^0.2.0:
- version "0.2.0"
- resolved "https://registry.yarnpkg.com/ember-hash-helper-polyfill/-/ember-hash-helper-polyfill-0.2.0.tgz#0913a06ad59147f345dff0edda04b112deba0f7e"
+ version "0.2.1"
+ resolved "https://registry.yarnpkg.com/ember-hash-helper-polyfill/-/ember-hash-helper-polyfill-0.2.1.tgz#73b074d8e2f7183d2e68c3df77e951097afa907c"
dependencies:
ember-cli-babel "^6.8.2"
- ember-cli-version-checker "^1.2.0"
+ ember-cli-version-checker "^2.1.0"
ember-href-to@1.15.1:
version "1.15.1"
@@ -2594,8 +2676,8 @@ ember-href-to@1.15.1:
ember-router-service-polyfill "^1.0.2"
ember-inflector@^2.0.0:
- version "2.1.0"
- resolved "https://registry.yarnpkg.com/ember-inflector/-/ember-inflector-2.1.0.tgz#afcb92d022a4eab58f08ff4578eafc3a1de2d09b"
+ version "2.2.0"
+ resolved "https://registry.yarnpkg.com/ember-inflector/-/ember-inflector-2.2.0.tgz#edd273dfd1a29be27f14b195e2f0ed70e812d9e0"
dependencies:
ember-cli-babel "^6.0.0"
@@ -2606,11 +2688,11 @@ ember-load-initializers@^1.0.0:
ember-cli-babel "^6.0.0-beta.7"
ember-lodash@^4.17.3:
- version "4.17.6"
- resolved "https://registry.yarnpkg.com/ember-lodash/-/ember-lodash-4.17.6.tgz#983b7a58da8ef7fcad50e82c77aa301195028445"
+ version "4.18.0"
+ resolved "https://registry.yarnpkg.com/ember-lodash/-/ember-lodash-4.18.0.tgz#45de700d6a4f68f1cd62888d90b50aa6477b9a83"
dependencies:
broccoli-debug "^0.6.1"
- broccoli-funnel "^1.1.0"
+ broccoli-funnel "^2.0.1"
broccoli-merge-trees "^2.0.0"
broccoli-string-replace "^0.1.1"
ember-cli-babel "^6.10.0"
@@ -2625,21 +2707,15 @@ ember-maybe-import-regenerator@^0.1.5, ember-maybe-import-regenerator@^0.1.6:
ember-cli-babel "^6.0.0-beta.4"
regenerator-runtime "^0.9.5"
-ember-maybe-in-element@^0.1.0:
+ember-maybe-in-element@^0.1.3:
version "0.1.3"
resolved "https://registry.yarnpkg.com/ember-maybe-in-element/-/ember-maybe-in-element-0.1.3.tgz#1c89be49246e580c1090336ad8be31e373f71b60"
dependencies:
ember-cli-babel "^6.11.0"
-ember-native-dom-event-dispatcher@^0.6.3:
- version "0.6.3"
- resolved "https://registry.yarnpkg.com/ember-native-dom-event-dispatcher/-/ember-native-dom-event-dispatcher-0.6.3.tgz#3b2f10dcf82f9aaa4dd211a704ac511fd8714720"
- dependencies:
- ember-cli-babel "^6.4.1"
-
-ember-native-dom-helpers@^0.5.10:
- version "0.5.10"
- resolved "https://registry.yarnpkg.com/ember-native-dom-helpers/-/ember-native-dom-helpers-0.5.10.tgz#9c7172e4ddfa5dd86830c46a936e2f8eca3e5896"
+ember-native-dom-helpers@^0.6.2:
+ version "0.6.2"
+ resolved "https://registry.yarnpkg.com/ember-native-dom-helpers/-/ember-native-dom-helpers-0.6.2.tgz#ad1f82d64ac9abdd612022f4f390bdb6653b3d39"
dependencies:
broccoli-funnel "^1.1.0"
ember-cli-babel "^6.6.0"
@@ -2652,8 +2728,8 @@ ember-qunit-assert-helpers@^0.2.1:
ember-cli-babel "^6.9.0"
ember-qunit@^3.3.2:
- version "3.3.2"
- resolved "https://registry.yarnpkg.com/ember-qunit/-/ember-qunit-3.3.2.tgz#cb48e9deaffa3b4c90983f28c5cf8590894c8ea3"
+ version "3.4.0"
+ resolved "https://registry.yarnpkg.com/ember-qunit/-/ember-qunit-3.4.0.tgz#47a60c2b889cd4b4a46380bf9da2b10115c0eae7"
dependencies:
"@ember/test-helpers" "^0.7.18"
broccoli-funnel "^2.0.1"
@@ -2664,8 +2740,8 @@ ember-qunit@^3.3.2:
qunit "^2.5.0"
ember-resolver@^4.0.0:
- version "4.5.0"
- resolved "https://registry.yarnpkg.com/ember-resolver/-/ember-resolver-4.5.0.tgz#9248bf534dfc197fafe3118fff538d436078bf99"
+ version "4.5.5"
+ resolved "https://registry.yarnpkg.com/ember-resolver/-/ember-resolver-4.5.5.tgz#6fef0597a42724e4960f37588df8a208ffd3365a"
dependencies:
"@glimmer/resolver" "^0.4.1"
babel-plugin-debug-macros "^0.1.10"
@@ -2675,15 +2751,15 @@ ember-resolver@^4.0.0:
ember-cli-version-checker "^2.0.0"
resolve "^1.3.3"
-ember-rfc176-data@^0.2.0:
+ember-rfc176-data@^0.2.0, ember-rfc176-data@^0.2.7:
version "0.2.7"
resolved "https://registry.yarnpkg.com/ember-rfc176-data/-/ember-rfc176-data-0.2.7.tgz#bd355bc9b473e08096b518784170a23388bc973b"
ember-rfc176-data@^0.3.0:
- version "0.3.1"
- resolved "https://registry.yarnpkg.com/ember-rfc176-data/-/ember-rfc176-data-0.3.1.tgz#6a5a4b8b82ec3af34f3010965fa96b936ca94519"
+ version "0.3.2"
+ resolved "https://registry.yarnpkg.com/ember-rfc176-data/-/ember-rfc176-data-0.3.2.tgz#bde5538939529b263c142b53a47402f8127f8dce"
-ember-router-generator@^1.0.0, ember-router-generator@^1.2.3:
+ember-router-generator@^1.2.3:
version "1.2.3"
resolved "https://registry.yarnpkg.com/ember-router-generator/-/ember-router-generator-1.2.3.tgz#8ed2ca86ff323363120fc14278191e9e8f1315ee"
dependencies:
@@ -2702,35 +2778,37 @@ ember-runtime-enumerable-includes-polyfill@^2.0.0:
ember-cli-babel "^6.9.0"
ember-cli-version-checker "^2.1.0"
-ember-source@~2.17.0:
- version "2.17.0"
- resolved "https://registry.yarnpkg.com/ember-source/-/ember-source-2.17.0.tgz#b78871dd49bd8d642b80176df4faf7fd7d059dac"
+ember-source-channel-url@^1.0.1:
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/ember-source-channel-url/-/ember-source-channel-url-1.1.0.tgz#73de5cc6ebc25b2120e932ec1d8f82677bfaf6ef"
dependencies:
- broccoli-funnel "^1.2.0"
+ got "^8.0.1"
+
+ember-source@~3.1.0:
+ version "3.1.0"
+ resolved "https://registry.yarnpkg.com/ember-source/-/ember-source-3.1.0.tgz#21902747801c747b615f60168712968db3b433fc"
+ dependencies:
+ broccoli-funnel "^2.0.1"
broccoli-merge-trees "^2.0.0"
ember-cli-get-component-path-option "^1.0.0"
ember-cli-is-package-missing "^1.0.0"
ember-cli-normalize-entity-name "^1.0.0"
ember-cli-path-utils "^1.0.0"
ember-cli-string-utils "^1.1.0"
- ember-cli-test-info "^1.0.0"
ember-cli-valid-component-name "^1.0.0"
ember-cli-version-checker "^2.1.0"
ember-router-generator "^1.2.3"
- fs-extra "^4.0.1"
inflection "^1.12.0"
- jquery "^3.2.1"
- resolve "^1.3.3"
+ jquery "^3.3.1"
+ resolve "^1.5.0"
ember-template-lint@^0.8.1:
- version "0.8.13"
- resolved "https://registry.yarnpkg.com/ember-template-lint/-/ember-template-lint-0.8.13.tgz#c714d7610c3658685b572151deb93bcacf22d923"
+ version "0.8.15"
+ resolved "https://registry.yarnpkg.com/ember-template-lint/-/ember-template-lint-0.8.15.tgz#558a2b1e2b55a51698bf6009d98f89f91bcdc12c"
dependencies:
- "@glimmer/compiler" "^0.30.1"
- "@glimmer/syntax" "^0.30.2"
+ "@glimmer/compiler" "^0.32.3"
chalk "^2.0.0"
glob "^7.0.0"
- lodash "^4.11.1"
minimatch "^3.0.4"
resolve "^1.1.3"
strip-bom "^3.0.0"
@@ -2756,9 +2834,9 @@ ember-try-config@^2.2.0:
rsvp "^3.2.1"
semver "^5.1.0"
-ember-try@^0.2.15:
- version "0.2.22"
- resolved "https://registry.yarnpkg.com/ember-try/-/ember-try-0.2.22.tgz#3989e9c013c1d5c209ec97f5dfcf4234e594d5e2"
+ember-try@^0.2.23:
+ version "0.2.23"
+ resolved "https://registry.yarnpkg.com/ember-try/-/ember-try-0.2.23.tgz#39b57141b4907541d0ac8b503d211e6946b08718"
dependencies:
chalk "^1.0.0"
cli-table2 "^0.2.0"
@@ -2773,9 +2851,9 @@ ember-try@^0.2.15:
rsvp "^3.0.17"
semver "^5.1.0"
-encodeurl@~1.0.1:
- version "1.0.1"
- resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-1.0.1.tgz#79e3d58655346909fe6f0f45a5de68103b294d20"
+encodeurl@~1.0.2:
+ version "1.0.2"
+ resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-1.0.2.tgz#ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59"
encoding@^0.1.11:
version "0.1.12"
@@ -2783,44 +2861,42 @@ encoding@^0.1.11:
dependencies:
iconv-lite "~0.4.13"
-engine.io-client@1.8.0:
- version "1.8.0"
- resolved "https://registry.yarnpkg.com/engine.io-client/-/engine.io-client-1.8.0.tgz#7b730e4127414087596d9be3c88d2bc5fdb6cf5c"
+engine.io-client@~3.2.0:
+ version "3.2.1"
+ resolved "https://registry.yarnpkg.com/engine.io-client/-/engine.io-client-3.2.1.tgz#6f54c0475de487158a1a7c77d10178708b6add36"
dependencies:
component-emitter "1.2.1"
component-inherit "0.0.3"
- debug "2.3.3"
- engine.io-parser "1.3.1"
+ debug "~3.1.0"
+ engine.io-parser "~2.1.1"
has-cors "1.1.0"
indexof "0.0.1"
- parsejson "0.0.3"
parseqs "0.0.5"
parseuri "0.0.5"
- ws "1.1.1"
- xmlhttprequest-ssl "1.5.3"
+ ws "~3.3.1"
+ xmlhttprequest-ssl "~1.5.4"
yeast "0.1.2"
-engine.io-parser@1.3.1:
- version "1.3.1"
- resolved "https://registry.yarnpkg.com/engine.io-parser/-/engine.io-parser-1.3.1.tgz#9554f1ae33107d6fbd170ca5466d2f833f6a07cf"
+engine.io-parser@~2.1.0, engine.io-parser@~2.1.1:
+ version "2.1.2"
+ resolved "https://registry.yarnpkg.com/engine.io-parser/-/engine.io-parser-2.1.2.tgz#4c0f4cff79aaeecbbdcfdea66a823c6085409196"
dependencies:
- after "0.8.1"
- arraybuffer.slice "0.0.6"
+ after "0.8.2"
+ arraybuffer.slice "~0.0.7"
base64-arraybuffer "0.1.5"
blob "0.0.4"
- has-binary "0.1.6"
- wtf-8 "1.0.0"
+ has-binary2 "~1.0.2"
-engine.io@1.8.0:
- version "1.8.0"
- resolved "https://registry.yarnpkg.com/engine.io/-/engine.io-1.8.0.tgz#3eeb5f264cb75dbbec1baaea26d61f5a4eace2aa"
+engine.io@~3.2.0:
+ version "3.2.0"
+ resolved "https://registry.yarnpkg.com/engine.io/-/engine.io-3.2.0.tgz#54332506f42f2edc71690d2f2a42349359f3bf7d"
dependencies:
- accepts "1.3.3"
- base64id "0.1.0"
+ accepts "~1.3.4"
+ base64id "1.0.0"
cookie "0.3.1"
- debug "2.3.3"
- engine.io-parser "1.3.1"
- ws "1.1.1"
+ debug "~3.1.0"
+ engine.io-parser "~2.1.0"
+ ws "~3.3.1"
ensure-posix-path@^1.0.0, ensure-posix-path@^1.0.1, ensure-posix-path@^1.0.2:
version "1.0.2"
@@ -2844,13 +2920,14 @@ error@^7.0.0:
xtend "~4.0.0"
es5-ext@^0.10.35, es5-ext@^0.10.9, es5-ext@~0.10.14:
- version "0.10.37"
- resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.37.tgz#0ee741d148b80069ba27d020393756af257defc3"
+ version "0.10.42"
+ resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.42.tgz#8c07dd33af04d5dcd1310b5cef13bea63a89ba8d"
dependencies:
- es6-iterator "~2.0.1"
+ es6-iterator "~2.0.3"
es6-symbol "~3.1.1"
+ next-tick "1"
-es6-iterator@~2.0.1:
+es6-iterator@~2.0.1, es6-iterator@~2.0.3:
version "2.0.3"
resolved "https://registry.yarnpkg.com/es6-iterator/-/es6-iterator-2.0.3.tgz#a7de889141a05a94b0854403b2d0a0fbfa98f3b7"
dependencies:
@@ -2898,15 +2975,26 @@ escape-string-regexp@1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.2.tgz#4dbc2fe674e71949caf3fb2695ce7f2dc1d9a8d1"
-escape-string-regexp@^1.0.0, escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5:
+escape-string-regexp@1.0.5, escape-string-regexp@^1.0.0, escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5:
version "1.0.5"
resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4"
-eslint-plugin-ember-suave@^1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/eslint-plugin-ember-suave/-/eslint-plugin-ember-suave-1.0.0.tgz#ea7d232a126562dcd8b1ee3aa2700ac3b626e514"
+eslint-plugin-ember@^5.0.0:
+ version "5.1.0"
+ resolved "https://registry.yarnpkg.com/eslint-plugin-ember/-/eslint-plugin-ember-5.1.0.tgz#fb96abd2d8bf105678a0aa81dadd99d7ca441ba1"
dependencies:
- requireindex "~1.1.0"
+ ember-rfc176-data "^0.2.7"
+ require-folder-tree "^1.4.5"
+ snake-case "^2.1.0"
+
+eslint-plugin-node@^6.0.1:
+ version "6.0.1"
+ resolved "https://registry.yarnpkg.com/eslint-plugin-node/-/eslint-plugin-node-6.0.1.tgz#bf19642298064379315d7a4b2a75937376fa05e4"
+ dependencies:
+ ignore "^3.3.6"
+ minimatch "^3.0.4"
+ resolve "^1.3.3"
+ semver "^5.4.1"
eslint-scope@^3.7.1:
version "3.7.1"
@@ -2915,21 +3003,25 @@ eslint-scope@^3.7.1:
esrecurse "^4.1.0"
estraverse "^4.1.1"
+eslint-visitor-keys@^1.0.0:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d"
+
eslint@^4.0.0:
- version "4.13.1"
- resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.13.1.tgz#0055e0014464c7eb7878caf549ef2941992b444f"
+ version "4.19.1"
+ resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.19.1.tgz#32d1d653e1d90408854bfb296f076ec7e186a300"
dependencies:
ajv "^5.3.0"
babel-code-frame "^6.22.0"
chalk "^2.1.0"
concat-stream "^1.6.0"
cross-spawn "^5.1.0"
- debug "^3.0.1"
- doctrine "^2.0.2"
+ debug "^3.1.0"
+ doctrine "^2.1.0"
eslint-scope "^3.7.1"
- espree "^3.5.2"
+ eslint-visitor-keys "^1.0.0"
+ espree "^3.5.4"
esquery "^1.0.0"
- estraverse "^4.2.0"
esutils "^2.0.2"
file-entry-cache "^2.0.0"
functional-red-black-tree "^1.0.1"
@@ -2950,18 +3042,19 @@ eslint@^4.0.0:
path-is-inside "^1.0.2"
pluralize "^7.0.0"
progress "^2.0.0"
+ regexpp "^1.0.1"
require-uncached "^1.0.3"
semver "^5.3.0"
strip-ansi "^4.0.0"
strip-json-comments "~2.0.1"
- table "^4.0.1"
+ table "4.0.2"
text-table "~0.2.0"
-espree@^3.5.2:
- version "3.5.2"
- resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.2.tgz#756ada8b979e9dcfcdb30aad8d1a9304a905e1ca"
+espree@^3.5.4:
+ version "3.5.4"
+ resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.4.tgz#b0f447187c8a8bed944b815a660bddf5deb5d1a7"
dependencies:
- acorn "^5.2.1"
+ acorn "^5.5.0"
acorn-jsx "^3.0.0"
esprima@^4.0.0:
@@ -2977,19 +3070,18 @@ esprima@~3.1.0:
resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.1.3.tgz#fdca51cee6133895e3c88d535ce49dbff62a4633"
esquery@^1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.0.tgz#cfba8b57d7fba93f17298a8a006a04cda13d80fa"
+ version "1.0.1"
+ resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708"
dependencies:
estraverse "^4.0.0"
esrecurse@^4.1.0:
- version "4.2.0"
- resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.2.0.tgz#fa9568d98d3823f9a41d91e902dcab9ea6e5b163"
+ version "4.2.1"
+ resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.2.1.tgz#007a3b9fdbc2b3bb87e4879ea19c92fdbd3942cf"
dependencies:
estraverse "^4.1.0"
- object-assign "^4.0.1"
-estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1, estraverse@^4.2.0:
+estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1:
version "4.2.0"
resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.2.0.tgz#0dee3fed31fcd469618ce7342099fc1afa0bdb13"
@@ -3016,15 +3108,35 @@ events-to-array@^1.0.1:
version "1.1.2"
resolved "https://registry.yarnpkg.com/events-to-array/-/events-to-array-1.1.2.tgz#2d41f563e1fe400ed4962fe1a4d5c6a7539df7f6"
+exec-file-sync@^2.0.0:
+ version "2.0.2"
+ resolved "https://registry.yarnpkg.com/exec-file-sync/-/exec-file-sync-2.0.2.tgz#58d441db46e40de6d1f30de5be022785bd89e328"
+ dependencies:
+ is-obj "^1.0.0"
+ object-assign "^4.0.1"
+ spawn-sync "^1.0.11"
+
exec-sh@^0.2.0:
version "0.2.1"
resolved "https://registry.yarnpkg.com/exec-sh/-/exec-sh-0.2.1.tgz#163b98a6e89e6b65b47c2a28d215bc1f63989c38"
dependencies:
merge "^1.1.3"
-execa@^0.8.0:
- version "0.8.0"
- resolved "https://registry.yarnpkg.com/execa/-/execa-0.8.0.tgz#d8d76bbc1b55217ed190fd6dd49d3c774ecfc8da"
+execa@^0.10.0:
+ version "0.10.0"
+ resolved "https://registry.yarnpkg.com/execa/-/execa-0.10.0.tgz#ff456a8f53f90f8eccc71a96d11bdfc7f082cb50"
+ dependencies:
+ cross-spawn "^6.0.0"
+ get-stream "^3.0.0"
+ is-stream "^1.1.0"
+ npm-run-path "^2.0.0"
+ p-finally "^1.0.0"
+ signal-exit "^3.0.0"
+ strip-eof "^1.0.0"
+
+execa@^0.9.0:
+ version "0.9.0"
+ resolved "https://registry.yarnpkg.com/execa/-/execa-0.9.0.tgz#adb7ce62cf985071f60580deb4a88b9e34712d01"
dependencies:
cross-spawn "^5.0.1"
get-stream "^3.0.0"
@@ -3078,12 +3190,6 @@ expand-range@^1.8.1:
dependencies:
fill-range "^2.1.0"
-expand-tilde@^1.2.2:
- version "1.2.2"
- resolved "https://registry.yarnpkg.com/expand-tilde/-/expand-tilde-1.2.2.tgz#0b81eba897e5a3d31d1c3d102f8f01441e559449"
- dependencies:
- os-homedir "^1.0.1"
-
expand-tilde@^2.0.0, expand-tilde@^2.0.2:
version "2.0.2"
resolved "https://registry.yarnpkg.com/expand-tilde/-/expand-tilde-2.0.2.tgz#97e801aa052df02454de46b02bf621642cdc8502"
@@ -3091,10 +3197,10 @@ expand-tilde@^2.0.0, expand-tilde@^2.0.2:
homedir-polyfill "^1.0.1"
express@^4.10.7, express@^4.12.3:
- version "4.16.2"
- resolved "https://registry.yarnpkg.com/express/-/express-4.16.2.tgz#e35c6dfe2d64b7dca0a5cd4f21781be3299e076c"
+ version "4.16.3"
+ resolved "https://registry.yarnpkg.com/express/-/express-4.16.3.tgz#6af8a502350db3246ecc4becf6b5a34d22f7ed53"
dependencies:
- accepts "~1.3.4"
+ accepts "~1.3.5"
array-flatten "1.1.1"
body-parser "1.18.2"
content-disposition "0.5.2"
@@ -3102,26 +3208,26 @@ express@^4.10.7, express@^4.12.3:
cookie "0.3.1"
cookie-signature "1.0.6"
debug "2.6.9"
- depd "~1.1.1"
- encodeurl "~1.0.1"
+ depd "~1.1.2"
+ encodeurl "~1.0.2"
escape-html "~1.0.3"
etag "~1.8.1"
- finalhandler "1.1.0"
+ finalhandler "1.1.1"
fresh "0.5.2"
merge-descriptors "1.0.1"
methods "~1.1.2"
on-finished "~2.3.0"
parseurl "~1.3.2"
path-to-regexp "0.1.7"
- proxy-addr "~2.0.2"
+ proxy-addr "~2.0.3"
qs "6.5.1"
range-parser "~1.2.0"
safe-buffer "5.1.1"
- send "0.16.1"
- serve-static "1.13.1"
+ send "0.16.2"
+ serve-static "1.13.2"
setprototypeof "1.1.0"
- statuses "~1.3.1"
- type-is "~1.6.15"
+ statuses "~1.4.0"
+ type-is "~1.6.16"
utils-merge "1.0.1"
vary "~1.1.2"
@@ -3151,8 +3257,8 @@ external-editor@^1.1.0:
tmp "^0.0.29"
external-editor@^2.0.4:
- version "2.1.0"
- resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-2.1.0.tgz#3d026a21b7f95b5726387d4200ac160d372c3b48"
+ version "2.2.0"
+ resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-2.2.0.tgz#045511cfd8d133f3846673d1047c154e214ad3d5"
dependencies:
chardet "^0.4.0"
iconv-lite "^0.4.17"
@@ -3194,8 +3300,8 @@ faker@^3.0.0:
resolved "https://registry.yarnpkg.com/faker/-/faker-3.1.0.tgz#0f908faf4e6ec02524e54a57e432c5c013e08c9f"
fast-deep-equal@^1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-1.0.0.tgz#96256a3bc975595eb36d82e9929d060d893439ff"
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-1.1.0.tgz#c053477817c86b51daa853c81e059b733d023614"
fast-json-stable-stringify@^2.0.0:
version "2.0.0"
@@ -3212,15 +3318,14 @@ fast-ordered-set@^1.0.0, fast-ordered-set@^1.0.2:
blank-object "^1.0.1"
fast-sourcemap-concat@^1.0.1:
- version "1.2.3"
- resolved "https://registry.yarnpkg.com/fast-sourcemap-concat/-/fast-sourcemap-concat-1.2.3.tgz#22f14e92d739e37920334376ec8433bf675eaa04"
+ version "1.2.5"
+ resolved "https://registry.yarnpkg.com/fast-sourcemap-concat/-/fast-sourcemap-concat-1.2.5.tgz#196db60ffefa9c616291512cd89113210e3cb747"
dependencies:
chalk "^0.5.1"
fs-extra "^0.30.0"
heimdalljs-logger "^0.1.7"
memory-streams "^0.1.0"
mkdirp "^0.5.0"
- rsvp "^3.0.14"
source-map "^0.4.2"
source-map-url "^0.3.0"
sourcemap-validator "^1.0.5"
@@ -3255,8 +3360,8 @@ filename-regex@^2.0.0:
resolved "https://registry.yarnpkg.com/filename-regex/-/filename-regex-2.0.1.tgz#c1c4b9bee3e09725ddb106b75c1e301fe2f18b26"
filesize@^3.1.3:
- version "3.5.11"
- resolved "https://registry.yarnpkg.com/filesize/-/filesize-3.5.11.tgz#1919326749433bb3cf77368bd158caabcc19e9ee"
+ version "3.6.1"
+ resolved "https://registry.yarnpkg.com/filesize/-/filesize-3.6.1.tgz#090bb3ee01b6f801a8a8be99d31710b3422bb317"
fill-range@^2.1.0:
version "2.2.3"
@@ -3277,16 +3382,16 @@ fill-range@^4.0.0:
repeat-string "^1.6.1"
to-regex-range "^2.1.0"
-finalhandler@1.1.0:
- version "1.1.0"
- resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.1.0.tgz#ce0b6855b45853e791b2fcc680046d88253dd7f5"
+finalhandler@1.1.1:
+ version "1.1.1"
+ resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.1.1.tgz#eebf4ed840079c83f4249038c9d703008301b105"
dependencies:
debug "2.6.9"
- encodeurl "~1.0.1"
+ encodeurl "~1.0.2"
escape-html "~1.0.3"
on-finished "~2.3.0"
parseurl "~1.3.2"
- statuses "~1.3.1"
+ statuses "~1.4.0"
unpipe "~1.0.0"
find-index@^1.1.0:
@@ -3306,6 +3411,13 @@ find-up@^2.1.0:
dependencies:
locate-path "^2.0.0"
+find-yarn-workspace-root@^1.0.0:
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/find-yarn-workspace-root/-/find-yarn-workspace-root-1.1.0.tgz#9817b6748cb90719f4dc37b4538bb200c697356f"
+ dependencies:
+ fs-extra "^4.0.3"
+ micromatch "^3.1.4"
+
findup-sync@2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/findup-sync/-/findup-sync-2.0.0.tgz#9326b1488c22d1a6088650a86901b2d9a90a2cbc"
@@ -3315,15 +3427,6 @@ findup-sync@2.0.0:
micromatch "^3.0.4"
resolve-dir "^1.0.1"
-findup-sync@^0.4.2:
- version "0.4.3"
- resolved "https://registry.yarnpkg.com/findup-sync/-/findup-sync-0.4.3.tgz#40043929e7bc60adf0b7f4827c4c6e75a0deca12"
- dependencies:
- detect-file "^0.1.0"
- is-glob "^2.0.1"
- micromatch "^2.3.7"
- resolve-dir "^0.1.0"
-
fireworm@^0.7.0:
version "0.7.1"
resolved "https://registry.yarnpkg.com/fireworm/-/fireworm-0.7.1.tgz#ccf20f7941f108883fcddb99383dbe6e1861c758"
@@ -3366,11 +3469,11 @@ form-data@~2.1.1:
mime-types "^2.1.12"
form-data@~2.3.1:
- version "2.3.1"
- resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.1.tgz#6fb94fbd71885306d73d15cc497fe4cc4ecd44bf"
+ version "2.3.2"
+ resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.2.tgz#4970498be604c20c005d4f5c23aecd21d6b49099"
dependencies:
asynckit "^0.4.0"
- combined-stream "^1.0.5"
+ combined-stream "1.0.6"
mime-types "^2.1.12"
forwarded@~0.1.2:
@@ -3387,9 +3490,12 @@ fresh@0.5.2:
version "0.5.2"
resolved "https://registry.yarnpkg.com/fresh/-/fresh-0.5.2.tgz#3d8cadd90d976569fa835ab1f8e4b23a105605a7"
-fs-exists-sync@^0.1.0:
- version "0.1.0"
- resolved "https://registry.yarnpkg.com/fs-exists-sync/-/fs-exists-sync-0.1.0.tgz#982d6893af918e72d08dec9e8673ff2b5a8d6add"
+from2@^2.1.1:
+ version "2.3.0"
+ resolved "https://registry.yarnpkg.com/from2/-/from2-2.3.0.tgz#8bfb5502bde4a4d36cfdeea007fcca21d7e382af"
+ dependencies:
+ inherits "^2.0.1"
+ readable-stream "^2.0.0"
fs-extra@^0.24.0:
version "0.24.0"
@@ -3435,7 +3541,7 @@ fs-extra@^2.0.0:
graceful-fs "^4.1.2"
jsonfile "^2.1.0"
-fs-extra@^4.0.0, fs-extra@^4.0.1:
+fs-extra@^4.0.0, fs-extra@^4.0.2, fs-extra@^4.0.3:
version "4.0.3"
resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-4.0.3.tgz#0d852122e5bc5beb453fb028e9c0c9bf36340c94"
dependencies:
@@ -3443,6 +3549,14 @@ fs-extra@^4.0.0, fs-extra@^4.0.1:
jsonfile "^4.0.0"
universalify "^0.1.0"
+fs-extra@^5.0.0:
+ version "5.0.0"
+ resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-5.0.0.tgz#414d0110cdd06705734d055652c5411260c31abd"
+ dependencies:
+ graceful-fs "^4.1.2"
+ jsonfile "^4.0.0"
+ universalify "^0.1.0"
+
fs-sync@^1.0.4:
version "1.0.4"
resolved "https://registry.yarnpkg.com/fs-sync/-/fs-sync-1.0.4.tgz#2f94eade31862ec0a9f33a1c2546dfb1a3f3d1ae"
@@ -3466,7 +3580,7 @@ fs.realpath@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f"
-fsevents@^1.0.0:
+fsevents@^1.0.0, fsevents@^1.1.1:
version "1.1.3"
resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.1.3.tgz#11f82318f5fe7bb2cd22965a108e9306208216d8"
dependencies:
@@ -3535,7 +3649,7 @@ get-stdin@^4.0.1:
version "4.0.1"
resolved "https://registry.yarnpkg.com/get-stdin/-/get-stdin-4.0.1.tgz#b968c6b0a04384324902e8bf1a5df32579a450fe"
-get-stream@^3.0.0:
+get-stream@3.0.0, get-stream@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-3.0.0.tgz#8e943d1358dc37555054ecbe2edb05aa174ede14"
@@ -3624,13 +3738,6 @@ glob@^7.0.0, glob@^7.0.3, glob@^7.0.4, glob@^7.0.5, glob@^7.1.0, glob@^7.1.2, gl
once "^1.3.0"
path-is-absolute "^1.0.0"
-global-modules@^0.2.3:
- version "0.2.3"
- resolved "https://registry.yarnpkg.com/global-modules/-/global-modules-0.2.3.tgz#ea5a3bed42c6d6ce995a4f8a1269b5dae223828d"
- dependencies:
- global-prefix "^0.1.4"
- is-windows "^0.2.0"
-
global-modules@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/global-modules/-/global-modules-1.0.0.tgz#6d770f0eb523ac78164d72b5e71a8877265cc3ea"
@@ -3639,15 +3746,6 @@ global-modules@^1.0.0:
is-windows "^1.0.1"
resolve-dir "^1.0.0"
-global-prefix@^0.1.4:
- version "0.1.5"
- resolved "https://registry.yarnpkg.com/global-prefix/-/global-prefix-0.1.5.tgz#8d3bc6b8da3ca8112a160d8d496ff0462bfef78f"
- dependencies:
- homedir-polyfill "^1.0.0"
- ini "^1.3.4"
- is-windows "^0.2.0"
- which "^1.2.12"
-
global-prefix@^1.0.1:
version "1.0.2"
resolved "https://registry.yarnpkg.com/global-prefix/-/global-prefix-1.0.2.tgz#dbf743c6c14992593c655568cb66ed32c0122ebe"
@@ -3659,8 +3757,8 @@ global-prefix@^1.0.1:
which "^1.2.14"
globals@^11.0.1:
- version "11.1.0"
- resolved "https://registry.yarnpkg.com/globals/-/globals-11.1.0.tgz#632644457f5f0e3ae711807183700ebf2e4633e4"
+ version "11.4.0"
+ resolved "https://registry.yarnpkg.com/globals/-/globals-11.4.0.tgz#b85c793349561c16076a3c13549238a27945f1bc"
globals@^9.18.0:
version "9.18.0"
@@ -3685,6 +3783,28 @@ globule@^1.0.0:
lodash "~4.17.4"
minimatch "~3.0.2"
+got@^8.0.1:
+ version "8.3.0"
+ resolved "https://registry.yarnpkg.com/got/-/got-8.3.0.tgz#6ba26e75f8a6cc4c6b3eb1fe7ce4fec7abac8533"
+ dependencies:
+ "@sindresorhus/is" "^0.7.0"
+ cacheable-request "^2.1.1"
+ decompress-response "^3.3.0"
+ duplexer3 "^0.1.4"
+ get-stream "^3.0.0"
+ into-stream "^3.1.0"
+ is-retry-allowed "^1.1.0"
+ isurl "^1.0.0-alpha5"
+ lowercase-keys "^1.0.0"
+ mimic-response "^1.0.0"
+ p-cancelable "^0.4.0"
+ p-timeout "^2.0.1"
+ pify "^3.0.0"
+ safe-buffer "^5.1.1"
+ timed-out "^4.0.1"
+ url-parse-lax "^3.0.0"
+ url-to-options "^1.0.1"
+
graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.3, graceful-fs@^4.1.6, graceful-fs@^4.1.9:
version "4.1.11"
resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.11.tgz#0e8bdfe4d1ddb8854d64e04ea7c00e2a026e5658"
@@ -3754,25 +3874,33 @@ has-ansi@^2.0.0:
dependencies:
ansi-regex "^2.0.0"
-has-binary@0.1.6:
- version "0.1.6"
- resolved "https://registry.yarnpkg.com/has-binary/-/has-binary-0.1.6.tgz#25326f39cfa4f616ad8787894e3af2cfbc7b6e10"
+has-binary2@~1.0.2:
+ version "1.0.2"
+ resolved "https://registry.yarnpkg.com/has-binary2/-/has-binary2-1.0.2.tgz#e83dba49f0b9be4d026d27365350d9f03f54be98"
dependencies:
- isarray "0.0.1"
-
-has-binary@0.1.7:
- version "0.1.7"
- resolved "https://registry.yarnpkg.com/has-binary/-/has-binary-0.1.7.tgz#68e61eb16210c9545a0a5cce06a873912fe1e68c"
- dependencies:
- isarray "0.0.1"
+ isarray "2.0.1"
has-cors@1.1.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/has-cors/-/has-cors-1.1.0.tgz#5e474793f7ea9843d1bb99c23eef49ff126fff39"
-has-flag@^2.0.0:
- version "2.0.0"
- resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-2.0.0.tgz#e8207af1cc7b30d446cc70b734b5e8be18f88d51"
+has-flag@^1.0.0:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-1.0.0.tgz#9d9e793165ce017a00f00418c43f942a7b1d11fa"
+
+has-flag@^3.0.0:
+ version "3.0.0"
+ resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd"
+
+has-symbol-support-x@^1.4.1:
+ version "1.4.2"
+ resolved "https://registry.yarnpkg.com/has-symbol-support-x/-/has-symbol-support-x-1.4.2.tgz#1409f98bc00247da45da67cee0a36f282ff26455"
+
+has-to-string-tag-x@^1.2.0:
+ version "1.4.1"
+ resolved "https://registry.yarnpkg.com/has-to-string-tag-x/-/has-to-string-tag-x-1.4.1.tgz#a045ab383d7b4b2012a00148ab0aa5f290044d4d"
+ dependencies:
+ has-symbol-support-x "^1.4.1"
has-unicode@^2.0.0:
version "2.0.1"
@@ -3832,18 +3960,24 @@ hawk@~6.0.2:
hoek "4.x.x"
sntp "2.x.x"
-heimdalljs-fs-monitor@^0.1.0:
- version "0.1.0"
- resolved "https://registry.yarnpkg.com/heimdalljs-fs-monitor/-/heimdalljs-fs-monitor-0.1.0.tgz#d404a65688c6714c485469ed3495da4853440272"
+he@1.1.1:
+ version "1.1.1"
+ resolved "https://registry.yarnpkg.com/he/-/he-1.1.1.tgz#93410fd21b009735151f8868c2f271f3427e23fd"
+
+heimdalljs-fs-monitor@^0.2.0:
+ version "0.2.0"
+ resolved "https://registry.yarnpkg.com/heimdalljs-fs-monitor/-/heimdalljs-fs-monitor-0.2.0.tgz#42504bc6da0e0016d0b7c8172fc71bb63185a518"
dependencies:
+ chai "^3.5.0"
heimdalljs "^0.2.0"
heimdalljs-logger "^0.1.7"
+ mocha "^3.2.0"
heimdalljs-graph@^0.3.1:
version "0.3.4"
resolved "https://registry.yarnpkg.com/heimdalljs-graph/-/heimdalljs-graph-0.3.4.tgz#0bd75797beeaa20b0ed59017aed3b2d95312acee"
-heimdalljs-logger@^0.1.7:
+heimdalljs-logger@^0.1.7, heimdalljs-logger@^0.1.9:
version "0.1.9"
resolved "https://registry.yarnpkg.com/heimdalljs-logger/-/heimdalljs-logger-0.1.9.tgz#d76ada4e45b7bb6f786fc9c010a68eb2e2faf176"
dependencies:
@@ -3867,8 +4001,8 @@ hoek@2.x.x:
resolved "https://registry.yarnpkg.com/hoek/-/hoek-2.16.3.tgz#20bb7403d3cea398e91dc4710a8ff1b8274a25ed"
hoek@4.x.x:
- version "4.2.0"
- resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.0.tgz#72d9d0754f7fe25ca2d01ad8f8f9a9449a89526d"
+ version "4.2.1"
+ resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.1.tgz#9634502aa12c445dd5a7c5734b572bb8738aacbb"
home-or-tmp@^2.0.0:
version "2.0.0"
@@ -3877,17 +4011,21 @@ home-or-tmp@^2.0.0:
os-homedir "^1.0.0"
os-tmpdir "^1.0.1"
-homedir-polyfill@^1.0.0, homedir-polyfill@^1.0.1:
+homedir-polyfill@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/homedir-polyfill/-/homedir-polyfill-1.0.1.tgz#4c2bbc8a758998feebf5ed68580f76d46768b4bc"
dependencies:
parse-passwd "^1.0.0"
-hosted-git-info@^2.1.4, hosted-git-info@^2.1.5:
- version "2.5.0"
- resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.5.0.tgz#6d60e34b3abbc8313062c3b798ef8d901a07af3c"
+hosted-git-info@^2.1.4, hosted-git-info@^2.6.0:
+ version "2.6.0"
+ resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.6.0.tgz#23235b29ab230c576aab0d4f13fc046b0b038222"
-http-errors@1.6.2, http-errors@~1.6.2:
+http-cache-semantics@3.8.1:
+ version "3.8.1"
+ resolved "https://registry.yarnpkg.com/http-cache-semantics/-/http-cache-semantics-3.8.1.tgz#39b0e16add9b605bf0a9ef3d9daaf4843b4cacd2"
+
+http-errors@1.6.2:
version "1.6.2"
resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-1.6.2.tgz#0a002cc85707192a7e7946ceedc11155f60ec736"
dependencies:
@@ -3896,9 +4034,18 @@ http-errors@1.6.2, http-errors@~1.6.2:
setprototypeof "1.0.3"
statuses ">= 1.3.1 < 2"
+http-errors@~1.6.2:
+ version "1.6.3"
+ resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-1.6.3.tgz#8b55680bb4be283a0b5bf4ea2e38580be1d9320d"
+ dependencies:
+ depd "~1.1.2"
+ inherits "2.0.3"
+ setprototypeof "1.1.0"
+ statuses ">= 1.4.0 < 2"
+
http-parser-js@>=0.4.0:
- version "0.4.9"
- resolved "https://registry.yarnpkg.com/http-parser-js/-/http-parser-js-0.4.9.tgz#ea1a04fb64adff0242e9974f297dd4c3cad271e1"
+ version "0.4.11"
+ resolved "https://registry.yarnpkg.com/http-parser-js/-/http-parser-js-0.4.11.tgz#5b720849c650903c27e521633d94696ee95f3529"
http-proxy@^1.13.1, http-proxy@^1.9.0:
version "1.16.2"
@@ -3923,11 +4070,17 @@ http-signature@~1.2.0:
jsprim "^1.2.2"
sshpk "^1.7.0"
-iconv-lite@0.4.19, iconv-lite@^0.4.13, iconv-lite@^0.4.17, iconv-lite@~0.4.13:
+iconv-lite@0.4.19:
version "0.4.19"
resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.19.tgz#f7468f60135f5e5dad3399c0a81be9a1603a082b"
-ignore@^3.3.3:
+iconv-lite@^0.4.13, iconv-lite@^0.4.17, iconv-lite@~0.4.13:
+ version "0.4.21"
+ resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.21.tgz#c47f8733d02171189ebc4a400f3218d348094798"
+ dependencies:
+ safer-buffer "^2.1.0"
+
+ignore@^3.3.3, ignore@^3.3.6:
version "3.3.7"
resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.7.tgz#612289bfb3c220e186a58118618d5be8c1bab021"
@@ -3953,7 +4106,7 @@ indexof@0.0.1:
version "0.0.1"
resolved "https://registry.yarnpkg.com/indexof/-/indexof-0.0.1.tgz#82dc336d232b9062179d05ab3293a66059fd435d"
-inflection@^1.12.0, inflection@^1.7.0, inflection@^1.7.1, inflection@^1.8.0:
+inflection@^1.12.0, inflection@^1.7.0, inflection@^1.8.0:
version "1.12.0"
resolved "https://registry.yarnpkg.com/inflection/-/inflection-1.12.0.tgz#a200935656d6f5f6bc4dc7502e1aecb703228416"
@@ -4020,9 +4173,16 @@ inquirer@^3.0.6:
strip-ansi "^4.0.0"
through "^2.3.6"
+into-stream@^3.1.0:
+ version "3.1.0"
+ resolved "https://registry.yarnpkg.com/into-stream/-/into-stream-3.1.0.tgz#96fb0a936c12babd6ff1752a17d05616abd094c6"
+ dependencies:
+ from2 "^2.1.1"
+ p-is-promise "^1.1.0"
+
invariant@^2.2.2:
- version "2.2.2"
- resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.2.tgz#9e1f56ac0acdb6bf303306f338be3b204ae60360"
+ version "2.2.4"
+ resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.4.tgz#610f3c92c9359ce1db616e538008d23ff35158e6"
dependencies:
loose-envify "^1.0.0"
@@ -4030,9 +4190,9 @@ invert-kv@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6"
-ipaddr.js@1.5.2:
- version "1.5.2"
- resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.5.2.tgz#d4b505bde9946987ccf0fc58d9010ff9607e3fa0"
+ipaddr.js@1.6.0:
+ version "1.6.0"
+ resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.6.0.tgz#e3fa357b773da619f26e95f049d055c72796f86b"
is-accessor-descriptor@^0.1.6:
version "0.1.6"
@@ -4154,12 +4314,17 @@ is-glob@^3.1.0:
dependencies:
is-extglob "^2.1.0"
+is-my-ip-valid@^1.0.0:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/is-my-ip-valid/-/is-my-ip-valid-1.0.0.tgz#7b351b8e8edd4d3995d4d066680e664d94696824"
+
is-my-json-valid@^2.12.4:
- version "2.16.1"
- resolved "https://registry.yarnpkg.com/is-my-json-valid/-/is-my-json-valid-2.16.1.tgz#5a846777e2c2620d1e69104e5d3a03b1f6088f11"
+ version "2.17.2"
+ resolved "https://registry.yarnpkg.com/is-my-json-valid/-/is-my-json-valid-2.17.2.tgz#6b2103a288e94ef3de5cf15d29dd85fc4b78d65c"
dependencies:
generate-function "^2.0.0"
generate-object-property "^1.1.0"
+ is-my-ip-valid "^1.0.0"
jsonpointer "^4.0.0"
xtend "^4.0.0"
@@ -4183,6 +4348,10 @@ is-obj@^1.0.0:
version "1.0.1"
resolved "https://registry.yarnpkg.com/is-obj/-/is-obj-1.0.1.tgz#3e4729ac1f5fde025cd7d83a896dab9f4f67db0f"
+is-object@^1.0.1:
+ version "1.0.1"
+ resolved "https://registry.yarnpkg.com/is-object/-/is-object-1.0.1.tgz#8952688c5ec2ffd6b03ecc85e769e02903083470"
+
is-odd@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/is-odd/-/is-odd-2.0.0.tgz#7646624671fd7ea558ccd9a2795182f2958f1b24"
@@ -4194,8 +4363,8 @@ is-path-cwd@^1.0.0:
resolved "https://registry.yarnpkg.com/is-path-cwd/-/is-path-cwd-1.0.0.tgz#d225ec23132e89edd38fda767472e62e65f1106d"
is-path-in-cwd@^1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/is-path-in-cwd/-/is-path-in-cwd-1.0.0.tgz#6477582b8214d602346094567003be8a9eac04dc"
+ version "1.0.1"
+ resolved "https://registry.yarnpkg.com/is-path-in-cwd/-/is-path-in-cwd-1.0.1.tgz#5ac48b345ef675339bd6c7a48a912110b241cf52"
dependencies:
is-path-inside "^1.0.0"
@@ -4236,8 +4405,12 @@ is-regexp@^1.0.0:
resolved "https://registry.yarnpkg.com/is-regexp/-/is-regexp-1.0.0.tgz#fd2d883545c46bac5a633e7b9a09e87fa2cb5069"
is-resolvable@^1.0.0:
- version "1.0.1"
- resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.0.1.tgz#acca1cd36dbe44b974b924321555a70ba03b1cf4"
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.1.0.tgz#fb18f87ce1feb925169c9a407c19318a3206ed88"
+
+is-retry-allowed@^1.1.0:
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/is-retry-allowed/-/is-retry-allowed-1.1.0.tgz#11a060568b67339444033d0125a61a20d564fb34"
is-stream@^1.0.1, is-stream@^1.1.0:
version "1.1.0"
@@ -4257,10 +4430,6 @@ is-utf8@^0.2.0:
version "0.2.1"
resolved "https://registry.yarnpkg.com/is-utf8/-/is-utf8-0.2.1.tgz#4b0da1442104d1b336340e80797e865cf39f7d72"
-is-windows@^0.2.0:
- version "0.2.0"
- resolved "https://registry.yarnpkg.com/is-windows/-/is-windows-0.2.0.tgz#de1aa6d63ea29dd248737b69f1ff8b8002d2108c"
-
is-windows@^1.0.1, is-windows@^1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/is-windows/-/is-windows-1.0.2.tgz#d1850eb9791ecd18e6182ce12a30f396634bb19d"
@@ -4273,6 +4442,10 @@ isarray@1.0.0, isarray@~1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11"
+isarray@2.0.1:
+ version "2.0.1"
+ resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.1.tgz#a37d94ed9cda2d59865c9f76fe596ee1f338741e"
+
isbinaryfile@^3.0.0:
version "3.0.2"
resolved "https://registry.yarnpkg.com/isbinaryfile/-/isbinaryfile-3.0.2.tgz#4a3e974ec0cba9004d3fc6cde7209ea69368a621"
@@ -4303,6 +4476,13 @@ istextorbinary@2.1.0:
editions "^1.1.1"
textextensions "1 || 2"
+isurl@^1.0.0-alpha5:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/isurl/-/isurl-1.0.0.tgz#b27f4f49f3cdaa3ea44a0a5b7f3462e6edc39d67"
+ dependencies:
+ has-to-string-tag-x "^1.2.0"
+ is-object "^1.0.1"
+
jade@0.26.3:
version "0.26.3"
resolved "https://registry.yarnpkg.com/jade/-/jade-0.26.3.tgz#8f10d7977d8d79f2f6ff862a81b0513ccb25686c"
@@ -4310,13 +4490,13 @@ jade@0.26.3:
commander "0.6.1"
mkdirp "0.3.0"
-jquery@^3.2.1:
- version "3.2.1"
- resolved "https://registry.yarnpkg.com/jquery/-/jquery-3.2.1.tgz#5c4d9de652af6cd0a770154a631bba12b015c787"
+jquery@^3.3.1:
+ version "3.3.1"
+ resolved "https://registry.yarnpkg.com/jquery/-/jquery-3.3.1.tgz#958ce29e81c9790f31be7792df5d4d95fc57fbca"
js-base64@^2.1.8:
- version "2.4.0"
- resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-2.4.0.tgz#9e566fee624751a1d720c966cd6226d29d4025aa"
+ version "2.4.3"
+ resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-2.4.3.tgz#2e545ec2b0f2957f41356510205214e98fad6582"
js-reporters@1.2.1:
version "1.2.1"
@@ -4326,9 +4506,9 @@ js-tokens@^3.0.0, js-tokens@^3.0.2:
version "3.0.2"
resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b"
-js-yaml@^3.2.5, js-yaml@^3.2.7, js-yaml@^3.6.1, js-yaml@^3.9.1:
- version "3.10.0"
- resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.10.0.tgz#2e78441646bd4682e963f22b6e92823c309c62dc"
+js-yaml@^3.2.5, js-yaml@^3.2.7, js-yaml@^3.3.0, js-yaml@^3.6.1, js-yaml@^3.9.1:
+ version "3.11.0"
+ resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.11.0.tgz#597c1a8bd57152f26d622ce4117851a51f5ebaef"
dependencies:
argparse "^1.0.7"
esprima "^4.0.0"
@@ -4353,6 +4533,10 @@ jsesc@~0.5.0:
version "0.5.0"
resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-0.5.0.tgz#e7dee66e35d6fc16f710fe91d5cf69f70f08911d"
+json-buffer@3.0.0:
+ version "3.0.0"
+ resolved "https://registry.yarnpkg.com/json-buffer/-/json-buffer-3.0.0.tgz#5b1f397afc75d677bde8bcfc0e47e1f9a3d9a898"
+
json-schema-traverse@^0.3.0:
version "0.3.1"
resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz#349a6d44c53a51de89b40805c5d5e59b417d3340"
@@ -4412,6 +4596,12 @@ jsprim@^1.2.2:
json-schema "0.2.3"
verror "1.10.0"
+keyv@3.0.0:
+ version "3.0.0"
+ resolved "https://registry.yarnpkg.com/keyv/-/keyv-3.0.0.tgz#44923ba39e68b12a7cec7df6c3268c031f2ef373"
+ dependencies:
+ json-buffer "3.0.0"
+
kind-of@^3.0.2, kind-of@^3.0.3, kind-of@^3.2.0:
version "3.2.2"
resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-3.2.2.tgz#31ea21a734bab9bbb0f32466d893aea51e4a3c64"
@@ -4442,12 +4632,6 @@ lazy-cache@^1.0.3:
version "1.0.4"
resolved "https://registry.yarnpkg.com/lazy-cache/-/lazy-cache-1.0.4.tgz#a1d78fc3a50474cb80845d3b3b6e1da49a446e8e"
-lazy-cache@^2.0.2:
- version "2.0.2"
- resolved "https://registry.yarnpkg.com/lazy-cache/-/lazy-cache-2.0.2.tgz#b9190a4f913354694840859f8a8f7084d8822264"
- dependencies:
- set-getter "^0.1.0"
-
lcid@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/lcid/-/lcid-1.0.0.tgz#308accafa0bc483a3867b4b6f2b9506251d1b835"
@@ -4475,9 +4659,9 @@ linkify-it@^2.0.0:
dependencies:
uc.micro "^1.0.1"
-liquid-fire@0.29.1:
- version "0.29.1"
- resolved "https://registry.yarnpkg.com/liquid-fire/-/liquid-fire-0.29.1.tgz#bcfea12db65799def263721a2b9dd6142d426bdf"
+liquid-fire@0.29.2:
+ version "0.29.2"
+ resolved "https://registry.yarnpkg.com/liquid-fire/-/liquid-fire-0.29.2.tgz#db3900c0d6554262e2c2f30a3f24681a3006f850"
dependencies:
broccoli-funnel "^1.0.1"
broccoli-merge-trees "^1.0.0"
@@ -4488,11 +4672,11 @@ liquid-fire@0.29.1:
ember-getowner-polyfill "^2.0.1"
ember-hash-helper-polyfill "^0.2.0"
match-media "^0.2.0"
- velocity-animate ">= 0.11.8"
+ velocity-animate "^1.5.1"
-livereload-js@^2.2.2:
- version "2.2.2"
- resolved "https://registry.yarnpkg.com/livereload-js/-/livereload-js-2.2.2.tgz#6c87257e648ab475bc24ea257457edcc1f8d0bc2"
+livereload-js@^2.3.0:
+ version "2.3.0"
+ resolved "https://registry.yarnpkg.com/livereload-js/-/livereload-js-2.3.0.tgz#c3ab22e8aaf5bf3505d80d098cbad67726548c9a"
load-json-file@^1.0.0:
version "1.1.0"
@@ -4505,8 +4689,8 @@ load-json-file@^1.0.0:
strip-bom "^2.0.0"
loader.js@^4.6.0:
- version "4.6.0"
- resolved "https://registry.yarnpkg.com/loader.js/-/loader.js-4.6.0.tgz#b965663ddbe2d80da482454cb865efe496e93e22"
+ version "4.7.0"
+ resolved "https://registry.yarnpkg.com/loader.js/-/loader.js-4.7.0.tgz#a1a52902001c83631efde9688b8ab3799325ef1f"
locate-path@^2.0.0:
version "2.0.0"
@@ -4516,8 +4700,8 @@ locate-path@^2.0.0:
path-exists "^3.0.0"
lodash-es@^4.17.4:
- version "4.17.4"
- resolved "https://registry.yarnpkg.com/lodash-es/-/lodash-es-4.17.4.tgz#dcc1d7552e150a0640073ba9cb31d70f032950e7"
+ version "4.17.8"
+ resolved "https://registry.yarnpkg.com/lodash-es/-/lodash-es-4.17.8.tgz#6fa8c8c5d337481df0bdf1c0d899d42473121e45"
lodash._baseassign@^3.0.0:
version "3.2.0"
@@ -4538,6 +4722,10 @@ lodash._basecopy@^3.0.0:
version "3.0.1"
resolved "https://registry.yarnpkg.com/lodash._basecopy/-/lodash._basecopy-3.0.1.tgz#8da0e6a876cf344c0ad8a54882111dd3c5c7ca36"
+lodash._basecreate@^3.0.0:
+ version "3.0.3"
+ resolved "https://registry.yarnpkg.com/lodash._basecreate/-/lodash._basecreate-3.0.3.tgz#1bc661614daa7fc311b7d03bf16806a0213cf821"
+
lodash._basecreate@~2.3.0:
version "2.3.0"
resolved "https://registry.yarnpkg.com/lodash._basecreate/-/lodash._basecreate-2.3.0.tgz#9b88a86a4dcff7b7f3c61d83a2fcfc0671ec9de0"
@@ -4689,10 +4877,22 @@ lodash.bind@~2.3.0:
lodash._renative "~2.3.0"
lodash._slice "~2.3.0"
+lodash.castarray@^4.4.0:
+ version "4.4.0"
+ resolved "https://registry.yarnpkg.com/lodash.castarray/-/lodash.castarray-4.4.0.tgz#c02513515e309daddd4c24c60cfddcf5976d9115"
+
lodash.clonedeep@^4.3.2, lodash.clonedeep@^4.4.1:
version "4.5.0"
resolved "https://registry.yarnpkg.com/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz#e23f3f9c4f8fbdde872529c1071857a086e5ccef"
+lodash.create@3.1.1:
+ version "3.1.1"
+ resolved "https://registry.yarnpkg.com/lodash.create/-/lodash.create-3.1.1.tgz#d7f2849f0dbda7e04682bb8cd72ab022461debe7"
+ dependencies:
+ lodash._baseassign "^3.0.0"
+ lodash._basecreate "^3.0.0"
+ lodash._isiterateecall "^3.0.0"
+
lodash.debounce@^3.1.1:
version "3.1.1"
resolved "https://registry.yarnpkg.com/lodash.debounce/-/lodash.debounce-3.1.1.tgz#812211c378a94cc29d5aa4e3346cf0bfce3a7df5"
@@ -4788,13 +4988,13 @@ lodash.keys@~2.3.0:
lodash._shimkeys "~2.3.0"
lodash.isobject "~2.3.0"
-lodash.merge@^4.3.0, lodash.merge@^4.4.0, lodash.merge@^4.6.0:
- version "4.6.0"
- resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.0.tgz#69884ba144ac33fe699737a6086deffadd0f89c5"
+lodash.merge@^4.3.0, lodash.merge@^4.6.0:
+ version "4.6.1"
+ resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.1.tgz#adc25d9cb99b9391c59624f379fbba60d7111d54"
lodash.mergewith@^4.6.0:
- version "4.6.0"
- resolved "https://registry.yarnpkg.com/lodash.mergewith/-/lodash.mergewith-4.6.0.tgz#150cf0a16791f5903b8891eab154609274bdea55"
+ version "4.6.1"
+ resolved "https://registry.yarnpkg.com/lodash.mergewith/-/lodash.mergewith-4.6.1.tgz#639057e726c3afbdb3e7d42741caa8d6e4335927"
lodash.noop@~2.3.0:
version "2.3.0"
@@ -4881,19 +5081,23 @@ lodash.values@~2.3.0:
dependencies:
lodash.keys "~2.3.0"
-lodash@^3.10.1:
+lodash@3.8.0:
+ version "3.8.0"
+ resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.8.0.tgz#376eb98bdcd9382a9365c33c4cb8250de1325b91"
+
+lodash@^3.10.0, lodash@^3.10.1:
version "3.10.1"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.10.1.tgz#5bf45e8e49ba4189e17d482789dfd15bd140b7b6"
-lodash@^4.0.0, lodash@^4.11.1, lodash@^4.14.0, lodash@^4.16.1, lodash@^4.17.2, lodash@^4.17.4, lodash@^4.3.0, lodash@^4.5.1, lodash@^4.6.1, lodash@~4.17.4:
- version "4.17.4"
- resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.4.tgz#78203a4d1c328ae1d86dca6460e369b57f4055ae"
+lodash@^4.0.0, lodash@^4.14.0, lodash@^4.16.1, lodash@^4.17.2, lodash@^4.17.4, lodash@^4.3.0, lodash@^4.5.1, lodash@^4.6.1, lodash@~4.17.4:
+ version "4.17.5"
+ resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.5.tgz#99a92d65c0272debe8c96b6057bc8fbfa3bed511"
-log-symbols@^1.0.2:
- version "1.0.2"
- resolved "https://registry.yarnpkg.com/log-symbols/-/log-symbols-1.0.2.tgz#376ff7b58ea3086a0f09facc74617eca501e1a18"
+log-symbols@^2.2.0:
+ version "2.2.0"
+ resolved "https://registry.yarnpkg.com/log-symbols/-/log-symbols-2.2.0.tgz#5740e1c5d6f0dfda4ad9323b5332107ef6b4c40a"
dependencies:
- chalk "^1.0.0"
+ chalk "^2.0.1"
longest@^1.0.1:
version "1.0.1"
@@ -4912,20 +5116,32 @@ loud-rejection@^1.0.0:
currently-unhandled "^0.4.1"
signal-exit "^3.0.0"
+lower-case@^1.1.1:
+ version "1.1.4"
+ resolved "https://registry.yarnpkg.com/lower-case/-/lower-case-1.1.4.tgz#9a2cabd1b9e8e0ae993a4bf7d5875c39c42e8eac"
+
+lowercase-keys@1.0.0:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/lowercase-keys/-/lowercase-keys-1.0.0.tgz#4e3366b39e7f5457e35f1324bdf6f88d0bfc7306"
+
+lowercase-keys@^1.0.0:
+ version "1.0.1"
+ resolved "https://registry.yarnpkg.com/lowercase-keys/-/lowercase-keys-1.0.1.tgz#6f9e30b47084d971a7c820ff15a6c5167b74c26f"
+
lru-cache@2:
version "2.7.3"
resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-2.7.3.tgz#6d4524e8b955f95d4f5b58851ce21dd72fb4e952"
lru-cache@^4.0.1:
- version "4.1.1"
- resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.1.tgz#622e32e82488b49279114a4f9ecf45e7cd6bba55"
+ version "4.1.2"
+ resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.2.tgz#45234b2e6e2f2b33da125624c4664929a0224c3f"
dependencies:
pseudomap "^1.0.2"
yallist "^2.1.2"
make-dir@^1.0.0:
- version "1.1.0"
- resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-1.1.0.tgz#19b4369fe48c116f53c2af95ad102c0e39e85d51"
+ version "1.2.0"
+ resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-1.2.0.tgz#6d6a49eead4aae296c53bbf3a1a008bd6c89469b"
dependencies:
pify "^3.0.0"
@@ -4960,14 +5176,14 @@ markdown-it-terminal@0.1.0:
markdown-it "^8.3.1"
markdown-it@^8.3.0, markdown-it@^8.3.1:
- version "8.4.0"
- resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-8.4.0.tgz#e2400881bf171f7018ed1bd9da441dac8af6306d"
+ version "8.4.1"
+ resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-8.4.1.tgz#206fe59b0e4e1b78a7c73250af9b34a4ad0aaf44"
dependencies:
argparse "^1.0.7"
entities "~1.1.1"
linkify-it "^2.0.0"
mdurl "^1.0.1"
- uc.micro "^1.0.3"
+ uc.micro "^1.0.5"
match-media@^0.2.0:
version "0.2.0"
@@ -5010,12 +5226,12 @@ memory-scroll@0.9.1:
ember-cli-babel "^6.8.2"
memory-streams@^0.1.0:
- version "0.1.2"
- resolved "https://registry.yarnpkg.com/memory-streams/-/memory-streams-0.1.2.tgz#273ff777ab60fec599b116355255282cca2c50c2"
+ version "0.1.3"
+ resolved "https://registry.yarnpkg.com/memory-streams/-/memory-streams-0.1.3.tgz#d9b0017b4b87f1d92f55f2745c9caacb1dc93ceb"
dependencies:
readable-stream "~1.0.2"
-meow@^3.7.0:
+meow@^3.4.0, meow@^3.7.0:
version "3.7.0"
resolved "https://registry.yarnpkg.com/meow/-/meow-3.7.0.tgz#72cb668b425228290abbfa856892587308a801fb"
dependencies:
@@ -5053,7 +5269,7 @@ methods@~1.1.2:
version "1.1.2"
resolved "https://registry.yarnpkg.com/methods/-/methods-1.1.2.tgz#5529a4d67654134edcc5266656835b0f851afcee"
-micromatch@^2.1.5, micromatch@^2.3.7:
+micromatch@^2.1.5:
version "2.3.11"
resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-2.3.11.tgz#86677c97d1720b363431d04d0d15293bd38c1565"
dependencies:
@@ -5071,9 +5287,9 @@ micromatch@^2.1.5, micromatch@^2.3.7:
parse-glob "^3.0.4"
regex-cache "^0.4.2"
-micromatch@^3.0.4:
- version "3.1.6"
- resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-3.1.6.tgz#8d7c043b48156f408ca07a4715182b79b99420bf"
+micromatch@^3.0.4, micromatch@^3.1.4:
+ version "3.1.10"
+ resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-3.1.10.tgz#70859bc95c9840952f359a068a3fc49f9ecfac23"
dependencies:
arr-diff "^4.0.0"
array-unique "^0.3.2"
@@ -5087,33 +5303,29 @@ micromatch@^3.0.4:
object.pick "^1.3.0"
regex-not "^1.0.0"
snapdragon "^0.8.1"
- to-regex "^3.0.1"
-
-"mime-db@>= 1.30.0 < 2":
- version "1.32.0"
- resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.32.0.tgz#485b3848b01a3cda5f968b4882c0771e58e09414"
+ to-regex "^3.0.2"
-mime-db@~1.30.0:
- version "1.30.0"
- resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.30.0.tgz#74c643da2dd9d6a45399963465b26d5ca7d71f01"
+"mime-db@>= 1.33.0 < 2", mime-db@~1.33.0:
+ version "1.33.0"
+ resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.33.0.tgz#a3492050a5cb9b63450541e39d9788d2272783db"
-mime-types@^2.1.12, mime-types@~2.1.11, mime-types@~2.1.15, mime-types@~2.1.16, mime-types@~2.1.17, mime-types@~2.1.7:
- version "2.1.17"
- resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.17.tgz#09d7a393f03e995a79f8af857b70a9e0ab16557a"
+mime-types@^2.1.12, mime-types@^2.1.18, mime-types@~2.1.17, mime-types@~2.1.18, mime-types@~2.1.7:
+ version "2.1.18"
+ resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.18.tgz#6f323f60a83d11146f831ff11fd66e2fe5503bb8"
dependencies:
- mime-db "~1.30.0"
+ mime-db "~1.33.0"
mime@1.4.1:
version "1.4.1"
resolved "https://registry.yarnpkg.com/mime/-/mime-1.4.1.tgz#121f9ebc49e3766f311a76e1fa1c8003c4b03aa6"
-mime@^1.2.11:
- version "1.6.0"
- resolved "https://registry.yarnpkg.com/mime/-/mime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1"
-
mimic-fn@^1.0.0:
- version "1.1.0"
- resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.1.0.tgz#e667783d92e89dbd342818b5230b9d62a672ad18"
+ version "1.2.0"
+ resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022"
+
+mimic-response@^1.0.0:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/mimic-response/-/mimic-response-1.0.0.tgz#df3d3652a73fded6b9b0b24146e6fd052353458e"
minimatch@0.3:
version "0.3.0"
@@ -5186,6 +5398,23 @@ mocha@2.5.3:
supports-color "1.2.0"
to-iso-string "0.0.2"
+mocha@^3.2.0:
+ version "3.5.3"
+ resolved "https://registry.yarnpkg.com/mocha/-/mocha-3.5.3.tgz#1e0480fe36d2da5858d1eb6acc38418b26eaa20d"
+ dependencies:
+ browser-stdout "1.3.0"
+ commander "2.9.0"
+ debug "2.6.8"
+ diff "3.2.0"
+ escape-string-regexp "1.0.5"
+ glob "7.1.1"
+ growl "1.9.2"
+ he "1.1.1"
+ json3 "3.3.2"
+ lodash.create "3.1.1"
+ mkdirp "0.5.1"
+ supports-color "3.1.2"
+
morgan@^1.8.1:
version "1.9.0"
resolved "https://registry.yarnpkg.com/morgan/-/morgan-1.9.0.tgz#d01fa6c65859b76fcf31b3cb53a3821a311d8051"
@@ -5204,10 +5433,6 @@ ms@0.7.1:
version "0.7.1"
resolved "https://registry.yarnpkg.com/ms/-/ms-0.7.1.tgz#9cd13c03adbff25b65effde7ce864ee952017098"
-ms@0.7.2:
- version "0.7.2"
- resolved "https://registry.yarnpkg.com/ms/-/ms-0.7.2.tgz#ae25cf2512b3885a1d95d7f037868d8431124765"
-
ms@2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8"
@@ -5224,9 +5449,9 @@ mute-stream@0.0.7:
version "0.0.7"
resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab"
-nan@^2.3.0, nan@^2.3.2:
- version "2.8.0"
- resolved "https://registry.yarnpkg.com/nan/-/nan-2.8.0.tgz#ed715f3fe9de02b57a5e6252d90a96675e1f085a"
+nan@^2.10.0, nan@^2.3.0:
+ version "2.10.0"
+ resolved "https://registry.yarnpkg.com/nan/-/nan-2.10.0.tgz#96d0cd610ebd58d4b4de9cc0c6828cda99c7548f"
nanomatch@^1.2.9:
version "1.2.9"
@@ -5253,6 +5478,20 @@ negotiator@0.6.1:
version "0.6.1"
resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.1.tgz#2b327184e8992101177b28563fb5e7102acd0ca9"
+next-tick@1:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.0.0.tgz#ca86d1fe8828169b0120208e3dc8424b9db8342c"
+
+nice-try@^1.0.4:
+ version "1.0.4"
+ resolved "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.4.tgz#d93962f6c52f2c1558c0fbda6d512819f1efe1c4"
+
+no-case@^2.2.0:
+ version "2.3.2"
+ resolved "https://registry.yarnpkg.com/no-case/-/no-case-2.3.2.tgz#60b813396be39b3f1288a4c1ed5d1e7d28b464ac"
+ dependencies:
+ lower-case "^1.1.1"
+
node-fetch@^1.3.3:
version "1.7.3"
resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-1.7.3.tgz#980f6f72d85211a5347c6b2bc18c5b84c3eb47ef"
@@ -5261,8 +5500,8 @@ node-fetch@^1.3.3:
is-stream "^1.0.1"
node-fetch@^2.0.0-alpha.9:
- version "2.0.0-alpha.9"
- resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.0.0-alpha.9.tgz#990c0634f510f76449a0d6f6eaec96b22f273628"
+ version "2.1.2"
+ resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.1.2.tgz#ab884e8e7e57e38a944753cec706f788d1768bb5"
node-gyp@^3.3.1:
version "3.6.2"
@@ -5291,13 +5530,13 @@ node-modules-path@^1.0.0, node-modules-path@^1.0.1:
resolved "https://registry.yarnpkg.com/node-modules-path/-/node-modules-path-1.0.1.tgz#40096b08ce7ad0ea14680863af449c7c75a5d1c8"
node-notifier@^5.0.1:
- version "5.1.2"
- resolved "https://registry.yarnpkg.com/node-notifier/-/node-notifier-5.1.2.tgz#2fa9e12605fa10009d44549d6fcd8a63dde0e4ff"
+ version "5.2.1"
+ resolved "https://registry.yarnpkg.com/node-notifier/-/node-notifier-5.2.1.tgz#fa313dd08f5517db0e2502e5758d664ac69f9dea"
dependencies:
growly "^1.3.0"
- semver "^5.3.0"
- shellwords "^0.1.0"
- which "^1.2.12"
+ semver "^5.4.1"
+ shellwords "^0.1.1"
+ which "^1.3.0"
node-pre-gyp@^0.6.39:
version "0.6.39"
@@ -5315,9 +5554,9 @@ node-pre-gyp@^0.6.39:
tar "^2.2.1"
tar-pack "^3.4.0"
-node-sass@^4.1.0:
- version "4.7.2"
- resolved "https://registry.yarnpkg.com/node-sass/-/node-sass-4.7.2.tgz#9366778ba1469eb01438a9e8592f4262bcb6794e"
+node-sass@^4.7.2:
+ version "4.8.3"
+ resolved "https://registry.yarnpkg.com/node-sass/-/node-sass-4.8.3.tgz#d077cc20a08ac06f661ca44fb6f19cd2ed41debb"
dependencies:
async-foreach "^0.1.3"
chalk "^1.1.1"
@@ -5331,7 +5570,7 @@ node-sass@^4.1.0:
lodash.mergewith "^4.6.0"
meow "^3.7.0"
mkdirp "^0.5.1"
- nan "^2.3.2"
+ nan "^2.10.0"
node-gyp "^3.3.1"
npmlog "^4.0.0"
request "~2.79.0"
@@ -5361,22 +5600,32 @@ normalize-package-data@^2.3.2, normalize-package-data@^2.3.4:
semver "2 || 3 || 4 || 5"
validate-npm-package-license "^3.0.1"
-normalize-path@^2.0.0, normalize-path@^2.0.1:
+normalize-path@^2.0.0, normalize-path@^2.0.1, normalize-path@^2.1.1:
version "2.1.1"
resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-2.1.1.tgz#1ab28b556e198363a8c1a6f7e6fa20137fe6aed9"
dependencies:
remove-trailing-separator "^1.0.1"
+normalize-url@2.0.1:
+ version "2.0.1"
+ resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-2.0.1.tgz#835a9da1551fa26f70e92329069a23aa6574d7e6"
+ dependencies:
+ prepend-http "^2.0.0"
+ query-string "^5.0.1"
+ sort-keys "^2.0.0"
+
npm-git-info@^1.0.0:
version "1.0.3"
resolved "https://registry.yarnpkg.com/npm-git-info/-/npm-git-info-1.0.3.tgz#a933c42ec321e80d3646e0d6e844afe94630e1d5"
-npm-package-arg@^4.1.1:
- version "4.2.1"
- resolved "https://registry.yarnpkg.com/npm-package-arg/-/npm-package-arg-4.2.1.tgz#593303fdea85f7c422775f17f9eb7670f680e3ec"
+npm-package-arg@^6.0.0:
+ version "6.1.0"
+ resolved "https://registry.yarnpkg.com/npm-package-arg/-/npm-package-arg-6.1.0.tgz#15ae1e2758a5027efb4c250554b85a737db7fcc1"
dependencies:
- hosted-git-info "^2.1.5"
- semver "^5.1.0"
+ hosted-git-info "^2.6.0"
+ osenv "^0.1.5"
+ semver "^5.5.0"
+ validate-npm-package-name "^3.0.0"
npm-run-path@^2.0.0:
version "2.0.2"
@@ -5401,10 +5650,6 @@ oauth-sign@~0.8.1, oauth-sign@~0.8.2:
version "0.8.2"
resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.8.2.tgz#46a6ab7f0aead8deae9ec0565780b7d4efeb9d43"
-object-assign@4.1.0:
- version "4.1.0"
- resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.0.tgz#7a3b3d0e98063d43f4c03f2e8ae6cd51a86883a0"
-
object-assign@4.1.1, object-assign@^4.0.1, object-assign@^4.1.0:
version "4.1.1"
resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863"
@@ -5462,7 +5707,7 @@ once@^1.3.0, once@^1.3.3:
onetime@^1.0.0:
version "1.1.0"
- resolved "https://registry.yarnpkg.com/onetime/-/onetime-1.1.0.tgz#a1f7838f8314c516f05ecefcbc4ccfe04b4ed789"
+ resolved "http://registry.npmjs.org/onetime/-/onetime-1.1.0.tgz#a1f7838f8314c516f05ecefcbc4ccfe04b4ed789"
onetime@^2.0.0:
version "2.0.1"
@@ -5488,18 +5733,16 @@ optionator@^0.8.2:
type-check "~0.3.2"
wordwrap "~1.0.0"
-options@>=0.0.5:
- version "0.0.6"
- resolved "https://registry.yarnpkg.com/options/-/options-0.0.6.tgz#ec22d312806bb53e731773e7cdaefcf1c643128f"
-
-ora@^1.3.0:
- version "1.3.0"
- resolved "https://registry.yarnpkg.com/ora/-/ora-1.3.0.tgz#80078dd2b92a934af66a3ad72a5b910694ede51a"
+ora@^2.0.0:
+ version "2.0.0"
+ resolved "https://registry.yarnpkg.com/ora/-/ora-2.0.0.tgz#8ec3a37fa7bffb54a3a0c188a1f6798e7e1827cd"
dependencies:
- chalk "^1.1.1"
+ chalk "^2.3.1"
cli-cursor "^2.1.0"
- cli-spinners "^1.0.0"
- log-symbols "^1.0.2"
+ cli-spinners "^1.1.0"
+ log-symbols "^2.2.0"
+ strip-ansi "^4.0.0"
+ wcwidth "^1.0.1"
os-homedir@^1.0.0, os-homedir@^1.0.1:
version "1.0.2"
@@ -5519,20 +5762,30 @@ os-tmpdir@^1.0.0, os-tmpdir@^1.0.1, os-tmpdir@~1.0.1, os-tmpdir@~1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274"
-osenv@0, osenv@^0.1.0, osenv@^0.1.3, osenv@^0.1.4:
- version "0.1.4"
- resolved "https://registry.yarnpkg.com/osenv/-/osenv-0.1.4.tgz#42fe6d5953df06c8064be6f176c3d05aaaa34644"
+osenv@0, osenv@^0.1.0, osenv@^0.1.3, osenv@^0.1.4, osenv@^0.1.5:
+ version "0.1.5"
+ resolved "https://registry.yarnpkg.com/osenv/-/osenv-0.1.5.tgz#85cdfafaeb28e8677f416e287592b5f3f49ea410"
dependencies:
os-homedir "^1.0.0"
os-tmpdir "^1.0.0"
+p-cancelable@^0.4.0:
+ version "0.4.1"
+ resolved "https://registry.yarnpkg.com/p-cancelable/-/p-cancelable-0.4.1.tgz#35f363d67d52081c8d9585e37bcceb7e0bbcb2a0"
+
p-finally@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae"
-p-limit@^1.1.0:
+p-is-promise@^1.1.0:
version "1.1.0"
- resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-1.1.0.tgz#b07ff2d9a5d88bec806035895a2bab66a27988bc"
+ resolved "https://registry.yarnpkg.com/p-is-promise/-/p-is-promise-1.1.0.tgz#9c9456989e9f6588017b0434d56097675c3da05e"
+
+p-limit@^1.1.0:
+ version "1.2.0"
+ resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-1.2.0.tgz#0e92b6bedcb59f022c13d0f1949dc82d15909f1c"
+ dependencies:
+ p-try "^1.0.0"
p-locate@^2.0.0:
version "2.0.0"
@@ -5540,6 +5793,16 @@ p-locate@^2.0.0:
dependencies:
p-limit "^1.1.0"
+p-timeout@^2.0.1:
+ version "2.0.1"
+ resolved "https://registry.yarnpkg.com/p-timeout/-/p-timeout-2.0.1.tgz#d8dd1979595d2dc0139e1fe46b8b646cb3cdf038"
+ dependencies:
+ p-finally "^1.0.0"
+
+p-try@^1.0.0:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/p-try/-/p-try-1.0.0.tgz#cbc79cdbaf8fd4228e13f621f2b1a237c1b207b3"
+
parse-glob@^3.0.4:
version "3.0.4"
resolved "https://registry.yarnpkg.com/parse-glob/-/parse-glob-3.0.4.tgz#b2c376cfb11f35513badd173ef0bb6e3a388391c"
@@ -5559,12 +5822,6 @@ parse-passwd@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/parse-passwd/-/parse-passwd-1.0.0.tgz#6d5b934a456993b23d37f40a382d6f1666a8e5c6"
-parsejson@0.0.3:
- version "0.0.3"
- resolved "https://registry.yarnpkg.com/parsejson/-/parsejson-0.0.3.tgz#ab7e3759f209ece99437973f7d0f1f64ae0e64ab"
- dependencies:
- better-assert "~1.0.0"
-
parseqs@0.0.5:
version "0.0.5"
resolved "https://registry.yarnpkg.com/parseqs/-/parseqs-0.0.5.tgz#d5208a3738e46766e291ba2ea173684921a8b89d"
@@ -5585,6 +5842,12 @@ pascalcase@^0.1.1:
version "0.1.1"
resolved "https://registry.yarnpkg.com/pascalcase/-/pascalcase-0.1.1.tgz#b363e55e8006ca6fe21784d2db22bd15d7917f14"
+passwd-user@^1.2.1:
+ version "1.2.1"
+ resolved "https://registry.yarnpkg.com/passwd-user/-/passwd-user-1.2.1.tgz#a01a5dc639ef007dc56364b8178569080ad3a7b8"
+ dependencies:
+ exec-file-sync "^2.0.0"
+
path-exists@^2.0.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-2.1.0.tgz#0feb6c64f0fc518d9a754dd5efb62c7022761f4b"
@@ -5603,7 +5866,7 @@ path-is-inside@^1.0.1, path-is-inside@^1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/path-is-inside/-/path-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53"
-path-key@^2.0.0:
+path-key@^2.0.0, path-key@^2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40"
@@ -5677,6 +5940,10 @@ prelude-ls@~1.1.2:
version "1.1.2"
resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54"
+prepend-http@^2.0.0:
+ version "2.0.0"
+ resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-2.0.0.tgz#e92434bfa5ea8c19f41cdfd401d741a3c819d897"
+
preserve@^0.2.0:
version "0.2.0"
resolved "https://registry.yarnpkg.com/preserve/-/preserve-0.2.0.tgz#815ed1f6ebc65926f865b310c0713bcb3315ce4b"
@@ -5696,9 +5963,9 @@ private@^0.1.6, private@^0.1.7, private@~0.1.5:
version "0.1.8"
resolved "https://registry.yarnpkg.com/private/-/private-0.1.8.tgz#2381edb3689f7a53d653190060fcf822d2f368ff"
-process-nextick-args@~1.0.6:
- version "1.0.7"
- resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-1.0.7.tgz#150e20b756590ad3f91093f25a4f2ad8bff30ba3"
+process-nextick-args@~2.0.0:
+ version "2.0.0"
+ resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.0.tgz#a37d732f4271b4ab1ad070d35508e8290788ffaa"
process-relative-require@^1.0.0:
version "1.0.0"
@@ -5716,12 +5983,12 @@ promise-map-series@^0.2.1:
dependencies:
rsvp "^3.0.14"
-proxy-addr@~2.0.2:
- version "2.0.2"
- resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.2.tgz#6571504f47bb988ec8180253f85dd7e14952bdec"
+proxy-addr@~2.0.3:
+ version "2.0.3"
+ resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.3.tgz#355f262505a621646b3130a728eb647e22055341"
dependencies:
forwarded "~0.1.2"
- ipaddr.js "1.5.2"
+ ipaddr.js "1.6.0"
pseudomap@^1.0.2:
version "1.0.2"
@@ -5743,6 +6010,14 @@ qs@~6.4.0:
version "6.4.0"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.4.0.tgz#13e26d28ad6b0ffaa91312cd3bf708ed351e7233"
+query-string@^5.0.1:
+ version "5.1.1"
+ resolved "https://registry.yarnpkg.com/query-string/-/query-string-5.1.1.tgz#a78c012b71c17e05f2e3fa2319dd330682efb3cb"
+ dependencies:
+ decode-uri-component "^0.2.0"
+ object-assign "^4.1.0"
+ strict-uri-encode "^1.0.0"
+
quibble@^0.5.1:
version "0.5.3"
resolved "https://registry.yarnpkg.com/quibble/-/quibble-0.5.3.tgz#3dfd53206fc6873f61c96f3bece63b69747b4d0c"
@@ -5759,8 +6034,8 @@ quick-temp@^0.1.0, quick-temp@^0.1.2, quick-temp@^0.1.3, quick-temp@^0.1.5, quic
underscore.string "~3.3.4"
qunit@^2.5.0:
- version "2.5.0"
- resolved "https://registry.yarnpkg.com/qunit/-/qunit-2.5.0.tgz#64cbe30a1193ef02edc5b278efcdf1d0bae96b22"
+ version "2.6.0"
+ resolved "https://registry.yarnpkg.com/qunit/-/qunit-2.6.0.tgz#347b34686e2aa67a9f81f81d39f0771603ed628c"
dependencies:
chokidar "1.7.0"
commander "2.12.2"
@@ -5768,7 +6043,6 @@ qunit@^2.5.0:
findup-sync "2.0.0"
js-reporters "1.2.1"
resolve "1.5.0"
- shelljs "^0.2.6"
walk-sync "0.3.2"
randomatic@^1.1.3:
@@ -5799,8 +6073,8 @@ raw-body@~1.1.0:
string_decoder "0.10"
rc@^1.1.7:
- version "1.2.2"
- resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.2.tgz#d8ce9cb57e8d64d9c7badd9876c7c34cbe3c7077"
+ version "1.2.6"
+ resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.6.tgz#eb18989c6d4f4f162c399f79ddd29f3835568092"
dependencies:
deep-extend "~0.4.0"
ini "~1.3.0"
@@ -5822,16 +6096,16 @@ read-pkg@^1.0.0:
normalize-package-data "^2.3.2"
path-type "^1.0.0"
-readable-stream@^2, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.6, readable-stream@^2.1.4, readable-stream@^2.2.2:
- version "2.3.3"
- resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.3.tgz#368f2512d79f9d46fdfc71349ae7878bbc1eb95c"
+readable-stream@^2, readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.6, readable-stream@^2.1.4, readable-stream@^2.2.2:
+ version "2.3.6"
+ resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.6.tgz#b11c27d88b8ff1fbe070643cf94b0c79ae1b0aaf"
dependencies:
core-util-is "~1.0.0"
inherits "~2.0.3"
isarray "~1.0.0"
- process-nextick-args "~1.0.6"
+ process-nextick-args "~2.0.0"
safe-buffer "~5.1.1"
- string_decoder "~1.0.3"
+ string_decoder "~1.1.1"
util-deprecate "~1.0.1"
readable-stream@~1.0.2:
@@ -5904,13 +6178,17 @@ regex-cache@^0.4.2:
dependencies:
is-equal-shallow "^0.1.3"
-regex-not@^1.0.0:
+regex-not@^1.0.0, regex-not@^1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/regex-not/-/regex-not-1.0.2.tgz#1f4ece27e00b0b65e0247a6810e6a85d83a5752c"
dependencies:
extend-shallow "^3.0.2"
safe-regex "^1.1.0"
+regexpp@^1.0.1:
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-1.1.0.tgz#0e3516dd0b7904f413d2d4193dce4618c3a689ab"
+
regexpu-core@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-2.0.0.tgz#49d038837b8dcf8bfa5b9a42139938e6ea2ae240"
@@ -5948,8 +6226,8 @@ repeating@^2.0.0:
is-finite "^1.0.0"
request@2:
- version "2.83.0"
- resolved "https://registry.yarnpkg.com/request/-/request-2.83.0.tgz#ca0b65da02ed62935887808e6f510381034e3356"
+ version "2.85.0"
+ resolved "https://registry.yarnpkg.com/request/-/request-2.85.0.tgz#5a03615a47c61420b3eb99b7dba204f83603e1fa"
dependencies:
aws-sign2 "~0.7.0"
aws4 "^1.6.0"
@@ -6030,6 +6308,12 @@ require-directory@^2.1.1:
version "2.1.1"
resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42"
+require-folder-tree@^1.4.5:
+ version "1.4.5"
+ resolved "https://registry.yarnpkg.com/require-folder-tree/-/require-folder-tree-1.4.5.tgz#dfe553cbab98cc88e1c56a3f2f358f06ef85bcb0"
+ dependencies:
+ lodash "3.8.0"
+
require-main-filename@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-1.0.1.tgz#97f717b69d48784f5f526a6c5aa8ffdda055a4d1"
@@ -6041,21 +6325,10 @@ require-uncached@^1.0.3:
caller-path "^0.1.0"
resolve-from "^1.0.0"
-requireindex@~1.1.0:
- version "1.1.0"
- resolved "https://registry.yarnpkg.com/requireindex/-/requireindex-1.1.0.tgz#e5404b81557ef75db6e49c5a72004893fe03e162"
-
requires-port@1.x.x:
version "1.0.0"
resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff"
-resolve-dir@^0.1.0:
- version "0.1.1"
- resolved "https://registry.yarnpkg.com/resolve-dir/-/resolve-dir-0.1.1.tgz#b219259a5602fac5c5c496ad894a6e8cc430261e"
- dependencies:
- expand-tilde "^1.2.2"
- global-modules "^0.2.3"
-
resolve-dir@^1.0.0, resolve-dir@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/resolve-dir/-/resolve-dir-1.0.1.tgz#79a40644c362be82f26effe739c9bb5382046f43"
@@ -6071,12 +6344,24 @@ resolve-url@^0.2.1:
version "0.2.1"
resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a"
-resolve@1.5.0, resolve@^1.1.3, resolve@^1.1.6, resolve@^1.1.7, resolve@^1.3.0, resolve@^1.3.3, resolve@^1.4.0, resolve@^1.5.0:
+resolve@1.5.0:
version "1.5.0"
resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.5.0.tgz#1f09acce796c9a762579f31b2c1cc4c3cddf9f36"
dependencies:
path-parse "^1.0.5"
+resolve@^1.1.3, resolve@^1.1.6, resolve@^1.1.7, resolve@^1.3.0, resolve@^1.3.3, resolve@^1.4.0, resolve@^1.5.0:
+ version "1.7.1"
+ resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.7.1.tgz#aadd656374fd298aee895bc026b8297418677fd3"
+ dependencies:
+ path-parse "^1.0.5"
+
+responselike@1.0.2:
+ version "1.0.2"
+ resolved "https://registry.yarnpkg.com/responselike/-/responselike-1.0.2.tgz#918720ef3b631c5642be068f15ade5a46f4ba1e7"
+ dependencies:
+ lowercase-keys "^1.0.0"
+
restore-cursor@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-1.0.1.tgz#34661f46886327fed2991479152252df92daa541"
@@ -6130,8 +6415,8 @@ rsvp@^3.0.14, rsvp@^3.0.16, rsvp@^3.0.17, rsvp@^3.0.18, rsvp@^3.0.21, rsvp@^3.0.
resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-3.6.2.tgz#2e96491599a96cde1b515d5674a8f7a91452926a"
rsvp@^4.6.1, rsvp@^4.7.0:
- version "4.7.0"
- resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-4.7.0.tgz#dc1b0b1a536f7dec9d2be45e0a12ad4197c9fd96"
+ version "4.8.2"
+ resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-4.8.2.tgz#9d5647108735784eb13418cdddb56f75b919d722"
rsvp@~3.0.6:
version "3.0.21"
@@ -6175,17 +6460,23 @@ safe-regex@^1.1.0:
dependencies:
ret "~0.1.10"
-sane@^1.1.1, sane@^1.6.0:
- version "1.7.0"
- resolved "https://registry.yarnpkg.com/sane/-/sane-1.7.0.tgz#b3579bccb45c94cf20355cc81124990dfd346e30"
+safer-buffer@^2.1.0:
+ version "2.1.2"
+ resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a"
+
+sane@^2.2.0, sane@^2.4.1:
+ version "2.5.0"
+ resolved "https://registry.yarnpkg.com/sane/-/sane-2.5.0.tgz#6359cd676f5efd9988b264d8ce3b827dd6b27bec"
dependencies:
- anymatch "^1.3.0"
+ anymatch "^2.0.0"
exec-sh "^0.2.0"
fb-watchman "^2.0.0"
- minimatch "^3.0.2"
+ micromatch "^3.1.4"
minimist "^1.1.1"
walker "~1.0.5"
- watch "~0.10.0"
+ watch "~0.18.0"
+ optionalDependencies:
+ fsevents "^1.1.1"
sass-graph@^2.2.4:
version "2.2.4"
@@ -6203,22 +6494,22 @@ scss-tokenizer@^0.2.3:
js-base64 "^2.1.8"
source-map "^0.4.2"
-"semver@2 || 3 || 4 || 5", semver@^5.1.0, semver@^5.1.1, semver@^5.3.0, semver@^5.4.1:
- version "5.4.1"
- resolved "https://registry.yarnpkg.com/semver/-/semver-5.4.1.tgz#e059c09d8571f0540823733433505d3a2f00b18e"
+"semver@2 || 3 || 4 || 5", semver@^5.1.0, semver@^5.1.1, semver@^5.3.0, semver@^5.4.1, semver@^5.5.0:
+ version "5.5.0"
+ resolved "https://registry.yarnpkg.com/semver/-/semver-5.5.0.tgz#dc4bbc7a6ca9d916dee5d43516f0092b58f7b8ab"
semver@~5.3.0:
version "5.3.0"
resolved "https://registry.yarnpkg.com/semver/-/semver-5.3.0.tgz#9b2ce5d3de02d17c6012ad326aa6b4d0cf54f94f"
-send@0.16.1:
- version "0.16.1"
- resolved "https://registry.yarnpkg.com/send/-/send-0.16.1.tgz#a70e1ca21d1382c11d0d9f6231deb281080d7ab3"
+send@0.16.2:
+ version "0.16.2"
+ resolved "https://registry.yarnpkg.com/send/-/send-0.16.2.tgz#6ecca1e0f8c156d141597559848df64730a6bbc1"
dependencies:
debug "2.6.9"
- depd "~1.1.1"
+ depd "~1.1.2"
destroy "~1.0.4"
- encodeurl "~1.0.1"
+ encodeurl "~1.0.2"
escape-html "~1.0.3"
etag "~1.8.1"
fresh "0.5.2"
@@ -6227,27 +6518,21 @@ send@0.16.1:
ms "2.0.0"
on-finished "~2.3.0"
range-parser "~1.2.0"
- statuses "~1.3.1"
+ statuses "~1.4.0"
-serve-static@1.13.1:
- version "1.13.1"
- resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.13.1.tgz#4c57d53404a761d8f2e7c1e8a18a47dbf278a719"
+serve-static@1.13.2:
+ version "1.13.2"
+ resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.13.2.tgz#095e8472fd5b46237db50ce486a43f4b86c6cec1"
dependencies:
- encodeurl "~1.0.1"
+ encodeurl "~1.0.2"
escape-html "~1.0.3"
parseurl "~1.3.2"
- send "0.16.1"
+ send "0.16.2"
set-blocking@^2.0.0, set-blocking@~2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7"
-set-getter@^0.1.0:
- version "0.1.0"
- resolved "https://registry.yarnpkg.com/set-getter/-/set-getter-0.1.0.tgz#d769c182c9d5a51f409145f2fba82e5e86e80376"
- dependencies:
- to-object-path "^0.3.0"
-
set-immediate-shim@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/set-immediate-shim/-/set-immediate-shim-1.0.1.tgz#4b2b1b27eb808a9f8dcc481a58e5e56f599f3f61"
@@ -6288,11 +6573,7 @@ shebang-regex@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3"
-shelljs@^0.2.6:
- version "0.2.6"
- resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.2.6.tgz#90492d72ffcc8159976baba62fb0f6884f0c3378"
-
-shellwords@^0.1.0:
+shellwords@^0.1.1:
version "0.1.1"
resolved "https://registry.yarnpkg.com/shellwords/-/shellwords-0.1.1.tgz#d6b9181c1a48d397324c84871efbcfc73fc0654b"
@@ -6311,8 +6592,8 @@ silent-error@^1.0.0, silent-error@^1.0.1, silent-error@^1.1.0:
debug "^2.2.0"
simple-git@^1.10.0:
- version "1.85.0"
- resolved "https://registry.yarnpkg.com/simple-git/-/simple-git-1.85.0.tgz#563ad291efc8a127735e8fbcd796967377614cd4"
+ version "1.92.0"
+ resolved "https://registry.yarnpkg.com/simple-git/-/simple-git-1.92.0.tgz#6061468eb7d19f0141078fc742e62457e910f547"
dependencies:
debug "^3.1.0"
@@ -6330,6 +6611,12 @@ slice-ansi@1.0.0:
dependencies:
is-fullwidth-code-point "^2.0.0"
+snake-case@^2.1.0:
+ version "2.1.0"
+ resolved "https://registry.yarnpkg.com/snake-case/-/snake-case-2.1.0.tgz#41bdb1b73f30ec66a04d4e2cad1b76387d4d6d9f"
+ dependencies:
+ no-case "^2.2.0"
+
snapdragon-node@^2.0.1:
version "2.1.1"
resolved "https://registry.yarnpkg.com/snapdragon-node/-/snapdragon-node-2.1.1.tgz#6c175f86ff14bdb0724563e8f3c1b021a286853b"
@@ -6345,8 +6632,8 @@ snapdragon-util@^3.0.1:
kind-of "^3.2.0"
snapdragon@^0.8.1:
- version "0.8.1"
- resolved "https://registry.yarnpkg.com/snapdragon/-/snapdragon-0.8.1.tgz#e12b5487faded3e3dea0ac91e9400bf75b401370"
+ version "0.8.2"
+ resolved "https://registry.yarnpkg.com/snapdragon/-/snapdragon-0.8.2.tgz#64922e7c565b0e14204ba1aa7d6964278d25182d"
dependencies:
base "^0.11.1"
debug "^2.2.0"
@@ -6355,7 +6642,7 @@ snapdragon@^0.8.1:
map-cache "^0.2.2"
source-map "^0.5.6"
source-map-resolve "^0.5.0"
- use "^2.0.0"
+ use "^3.1.0"
sntp@1.x.x:
version "1.0.9"
@@ -6369,57 +6656,61 @@ sntp@2.x.x:
dependencies:
hoek "4.x.x"
-socket.io-adapter@0.5.0:
- version "0.5.0"
- resolved "https://registry.yarnpkg.com/socket.io-adapter/-/socket.io-adapter-0.5.0.tgz#cb6d4bb8bec81e1078b99677f9ced0046066bb8b"
- dependencies:
- debug "2.3.3"
- socket.io-parser "2.3.1"
+socket.io-adapter@~1.1.0:
+ version "1.1.1"
+ resolved "https://registry.yarnpkg.com/socket.io-adapter/-/socket.io-adapter-1.1.1.tgz#2a805e8a14d6372124dd9159ad4502f8cb07f06b"
-socket.io-client@1.6.0:
- version "1.6.0"
- resolved "https://registry.yarnpkg.com/socket.io-client/-/socket.io-client-1.6.0.tgz#5b668f4f771304dfeed179064708386fa6717853"
+socket.io-client@2.1.0:
+ version "2.1.0"
+ resolved "https://registry.yarnpkg.com/socket.io-client/-/socket.io-client-2.1.0.tgz#0d0b21d460dc4ed36e57085136f2be0137ff20ff"
dependencies:
backo2 "1.0.2"
+ base64-arraybuffer "0.1.5"
component-bind "1.0.0"
component-emitter "1.2.1"
- debug "2.3.3"
- engine.io-client "1.8.0"
- has-binary "0.1.7"
+ debug "~3.1.0"
+ engine.io-client "~3.2.0"
+ has-binary2 "~1.0.2"
+ has-cors "1.1.0"
indexof "0.0.1"
object-component "0.0.3"
+ parseqs "0.0.5"
parseuri "0.0.5"
- socket.io-parser "2.3.1"
+ socket.io-parser "~3.2.0"
to-array "0.1.4"
-socket.io-parser@2.3.1:
- version "2.3.1"
- resolved "https://registry.yarnpkg.com/socket.io-parser/-/socket.io-parser-2.3.1.tgz#dd532025103ce429697326befd64005fcfe5b4a0"
+socket.io-parser@~3.2.0:
+ version "3.2.0"
+ resolved "https://registry.yarnpkg.com/socket.io-parser/-/socket.io-parser-3.2.0.tgz#e7c6228b6aa1f814e6148aea325b51aa9499e077"
dependencies:
- component-emitter "1.1.2"
- debug "2.2.0"
- isarray "0.0.1"
- json3 "3.3.2"
+ component-emitter "1.2.1"
+ debug "~3.1.0"
+ isarray "2.0.1"
-socket.io@1.6.0:
- version "1.6.0"
- resolved "https://registry.yarnpkg.com/socket.io/-/socket.io-1.6.0.tgz#3e40d932637e6bd923981b25caf7c53e83b6e2e1"
+socket.io@^2.1.0:
+ version "2.1.0"
+ resolved "https://registry.yarnpkg.com/socket.io/-/socket.io-2.1.0.tgz#de77161795b6303e7aefc982ea04acb0cec17395"
+ dependencies:
+ debug "~3.1.0"
+ engine.io "~3.2.0"
+ has-binary2 "~1.0.2"
+ socket.io-adapter "~1.1.0"
+ socket.io-client "2.1.0"
+ socket.io-parser "~3.2.0"
+
+sort-keys@^2.0.0:
+ version "2.0.0"
+ resolved "https://registry.yarnpkg.com/sort-keys/-/sort-keys-2.0.0.tgz#658535584861ec97d730d6cf41822e1f56684128"
dependencies:
- debug "2.3.3"
- engine.io "1.8.0"
- has-binary "0.1.7"
- object-assign "4.1.0"
- socket.io-adapter "0.5.0"
- socket.io-client "1.6.0"
- socket.io-parser "2.3.1"
+ is-plain-obj "^1.0.0"
sort-object-keys@^1.1.1:
version "1.1.2"
resolved "https://registry.yarnpkg.com/sort-object-keys/-/sort-object-keys-1.1.2.tgz#d3a6c48dc2ac97e6bc94367696e03f6d09d37952"
sort-package-json@^1.4.0:
- version "1.7.1"
- resolved "https://registry.yarnpkg.com/sort-package-json/-/sort-package-json-1.7.1.tgz#f2e5fbffe8420cc1bb04485f4509f05e73b4c0f2"
+ version "1.12.0"
+ resolved "https://registry.yarnpkg.com/sort-package-json/-/sort-package-json-1.12.0.tgz#cb5c8b583270e23624f1780cf4ba025299403a96"
dependencies:
sort-object-keys "^1.1.1"
@@ -6453,7 +6744,7 @@ source-map@0.4.x, source-map@^0.4.2, source-map@^0.4.4:
dependencies:
amdefine ">=0.0.4"
-source-map@^0.5.6, source-map@~0.5.0, source-map@~0.5.1:
+source-map@^0.5.6, source-map@^0.5.7, source-map@~0.5.0, source-map@~0.5.1:
version "0.5.7"
resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc"
@@ -6468,8 +6759,8 @@ source-map@~0.6.1:
resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263"
sourcemap-validator@^1.0.5:
- version "1.0.6"
- resolved "https://registry.yarnpkg.com/sourcemap-validator/-/sourcemap-validator-1.0.6.tgz#abd2f1ecdae6a3c46c2c96c5f256705b2147c9c0"
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/sourcemap-validator/-/sourcemap-validator-1.1.0.tgz#00454547d1682186e1498a7208e022e8dfa8738f"
dependencies:
jsesc "~0.3.x"
lodash.foreach "~2.3.x"
@@ -6480,26 +6771,34 @@ spawn-args@^0.2.0:
version "0.2.0"
resolved "https://registry.yarnpkg.com/spawn-args/-/spawn-args-0.2.0.tgz#fb7d0bd1d70fd4316bd9e3dec389e65f9d6361bb"
-spawn-sync@^1.0.15:
+spawn-sync@^1.0.11, spawn-sync@^1.0.15:
version "1.0.15"
resolved "https://registry.yarnpkg.com/spawn-sync/-/spawn-sync-1.0.15.tgz#b00799557eb7fb0c8376c29d44e8a1ea67e57476"
dependencies:
concat-stream "^1.4.7"
os-shim "^0.1.2"
-spdx-correct@~1.0.0:
- version "1.0.2"
- resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-1.0.2.tgz#4b3073d933ff51f3912f03ac5519498a4150db40"
+spdx-correct@^3.0.0:
+ version "3.0.0"
+ resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.0.0.tgz#05a5b4d7153a195bc92c3c425b69f3b2a9524c82"
dependencies:
- spdx-license-ids "^1.0.2"
+ spdx-expression-parse "^3.0.0"
+ spdx-license-ids "^3.0.0"
-spdx-expression-parse@~1.0.0:
- version "1.0.4"
- resolved "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-1.0.4.tgz#9bdf2f20e1f40ed447fbe273266191fced51626c"
+spdx-exceptions@^2.1.0:
+ version "2.1.0"
+ resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.1.0.tgz#2c7ae61056c714a5b9b9b2b2af7d311ef5c78fe9"
-spdx-license-ids@^1.0.2:
- version "1.2.2"
- resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-1.2.2.tgz#c9df7a3424594ade6bd11900d596696dc06bac57"
+spdx-expression-parse@^3.0.0:
+ version "3.0.0"
+ resolved "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz#99e119b7a5da00e05491c9fa338b7904823b41d0"
+ dependencies:
+ spdx-exceptions "^2.1.0"
+ spdx-license-ids "^3.0.0"
+
+spdx-license-ids@^3.0.0:
+ version "3.0.0"
+ resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.0.tgz#7a7cd28470cc6d3a1cfe6d66886f6bc430d3ac87"
split-string@^3.0.1, split-string@^3.0.2:
version "3.1.0"
@@ -6516,8 +6815,8 @@ sprintf-js@~1.0.2:
resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c"
sshpk@^1.7.0:
- version "1.13.1"
- resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.13.1.tgz#512df6da6287144316dc4c18fe1cf1d940739be3"
+ version "1.14.1"
+ resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.14.1.tgz#130f5975eddad963f1d56f92b9ac6c51fa9f83eb"
dependencies:
asn1 "~0.2.3"
assert-plus "^1.0.0"
@@ -6536,20 +6835,24 @@ static-extend@^0.1.1:
define-property "^0.2.5"
object-copy "^0.1.0"
-"statuses@>= 1.3.1 < 2":
+"statuses@>= 1.3.1 < 2", "statuses@>= 1.4.0 < 2":
+ version "1.5.0"
+ resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.5.0.tgz#161c7dac177659fd9811f43771fa99381478628c"
+
+statuses@~1.4.0:
version "1.4.0"
resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.4.0.tgz#bb73d446da2796106efcc1b601a253d6c46bd087"
-statuses@~1.3.1:
- version "1.3.1"
- resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.3.1.tgz#faf51b9eb74aaef3b3acf4ad5f61abf24cb7b93e"
-
stdout-stream@^1.4.0:
version "1.4.0"
resolved "https://registry.yarnpkg.com/stdout-stream/-/stdout-stream-1.4.0.tgz#a2c7c8587e54d9427ea9edb3ac3f2cd522df378b"
dependencies:
readable-stream "^2.0.1"
+strict-uri-encode@^1.0.0:
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/strict-uri-encode/-/strict-uri-encode-1.1.0.tgz#279b225df1d582b1f54e65addd4352e18faa0713"
+
string-template@~0.2.1:
version "0.2.1"
resolved "https://registry.yarnpkg.com/string-template/-/string-template-0.2.1.tgz#42932e598a352d01fc22ec3367d9d84eec6c9add"
@@ -6573,9 +6876,9 @@ string_decoder@0.10, string_decoder@~0.10.x:
version "0.10.31"
resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94"
-string_decoder@~1.0.3:
- version "1.0.3"
- resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.0.3.tgz#0fc67d7c141825de94282dd536bec6b9bce860ab"
+string_decoder@~1.1.1:
+ version "1.1.1"
+ resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8"
dependencies:
safe-buffer "~5.1.0"
@@ -6646,6 +6949,12 @@ supports-color@1.2.0:
version "1.2.0"
resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-1.2.0.tgz#ff1ed1e61169d06b3cf2d588e188b18d8847e17e"
+supports-color@3.1.2:
+ version "3.1.2"
+ resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-3.1.2.tgz#72a262894d9d408b956ca05ff37b2ed8a6e2a2d5"
+ dependencies:
+ has-flag "^1.0.0"
+
supports-color@^0.2.0:
version "0.2.0"
resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-0.2.0.tgz#d92de2694eb3f67323973d7ae3d8b55b4c22190a"
@@ -6654,17 +6963,17 @@ supports-color@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7"
-supports-color@^4.0.0:
- version "4.5.0"
- resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-4.5.0.tgz#be7a0de484dec5c5cddf8b3d59125044912f635b"
+supports-color@^5.3.0:
+ version "5.3.0"
+ resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.3.0.tgz#5b24ac15db80fa927cf5227a4a33fd3c4c7676c0"
dependencies:
- has-flag "^2.0.0"
+ has-flag "^3.0.0"
symlink-or-copy@^1.0.0, symlink-or-copy@^1.0.1, symlink-or-copy@^1.1.8:
- version "1.1.8"
- resolved "https://registry.yarnpkg.com/symlink-or-copy/-/symlink-or-copy-1.1.8.tgz#cabe61e0010c1c023c173b25ee5108b37f4b4aa3"
+ version "1.2.0"
+ resolved "https://registry.yarnpkg.com/symlink-or-copy/-/symlink-or-copy-1.2.0.tgz#5d49108e2ab824a34069b68974486c290020b393"
-table@^4.0.1:
+table@4.0.2:
version "4.0.2"
resolved "https://registry.yarnpkg.com/table/-/table-4.0.2.tgz#a33447375391e766ad34d3486e6e2aedc84d2e36"
dependencies:
@@ -6713,31 +7022,31 @@ temp@0.8.3:
rimraf "~2.2.6"
testdouble@^3.2.6:
- version "3.2.6"
- resolved "https://registry.yarnpkg.com/testdouble/-/testdouble-3.2.6.tgz#8fc47149c59f1becc795bf80f02b41de30ea4035"
+ version "3.7.0"
+ resolved "https://registry.yarnpkg.com/testdouble/-/testdouble-3.7.0.tgz#8547a07c472e250265919ab9745107a042429d15"
dependencies:
es6-map "^0.1.5"
lodash "^4.17.4"
quibble "^0.5.1"
- resolve "^1.3.3"
stringify-object-es5 "^2.5.0"
-testem@^1.18.0:
- version "1.18.4"
- resolved "https://registry.yarnpkg.com/testem/-/testem-1.18.4.tgz#e45fed922bec2f54a616c43f11922598ac97eb41"
+testem@^2.0.0:
+ version "2.2.1"
+ resolved "https://registry.yarnpkg.com/testem/-/testem-2.2.1.tgz#7bcda44eeb34287d918b3c8b9c6863d26a616557"
dependencies:
backbone "^1.1.2"
bluebird "^3.4.6"
charm "^1.0.0"
commander "^2.6.0"
consolidate "^0.14.0"
- cross-spawn "^5.1.0"
+ execa "^0.10.0"
express "^4.10.7"
fireworm "^0.7.0"
glob "^7.0.4"
http-proxy "^1.13.1"
js-yaml "^3.2.5"
lodash.assignin "^4.1.0"
+ lodash.castarray "^4.4.0"
lodash.clonedeep "^4.4.1"
lodash.find "^4.5.1"
lodash.uniqby "^4.7.0"
@@ -6747,7 +7056,7 @@ testem@^1.18.0:
npmlog "^4.0.0"
printf "^0.2.3"
rimraf "^2.4.4"
- socket.io "1.6.0"
+ socket.io "^2.1.0"
spawn-args "^0.2.0"
styled_string "0.0.1"
tap-parser "^5.1.0"
@@ -6758,21 +7067,25 @@ text-table@~0.2.0:
resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4"
"textextensions@1 || 2":
- version "2.1.0"
- resolved "https://registry.yarnpkg.com/textextensions/-/textextensions-2.1.0.tgz#1be0dc2a0dc244d44be8a09af6a85afb93c4dbc3"
+ version "2.2.0"
+ resolved "https://registry.yarnpkg.com/textextensions/-/textextensions-2.2.0.tgz#38ac676151285b658654581987a0ce1a4490d286"
through@^2.3.6, through@^2.3.8:
version "2.3.8"
resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5"
+timed-out@^4.0.1:
+ version "4.0.1"
+ resolved "https://registry.yarnpkg.com/timed-out/-/timed-out-4.0.1.tgz#f32eacac5a175bea25d7fab565ab3ed8741ef56f"
+
tiny-lr@^1.0.3:
- version "1.0.5"
- resolved "https://registry.yarnpkg.com/tiny-lr/-/tiny-lr-1.0.5.tgz#21f40bf84ebd1f853056680375eef1670c334112"
+ version "1.1.1"
+ resolved "https://registry.yarnpkg.com/tiny-lr/-/tiny-lr-1.1.1.tgz#9fa547412f238fedb068ee295af8b682c98b2aab"
dependencies:
body "^5.1.0"
- debug "~2.6.7"
+ debug "^3.1.0"
faye-websocket "~0.10.0"
- livereload-js "^2.2.2"
+ livereload-js "^2.3.0"
object-assign "^4.1.0"
qs "^6.4.0"
@@ -6830,17 +7143,18 @@ to-regex-range@^2.1.0:
is-number "^3.0.0"
repeat-string "^1.6.1"
-to-regex@^3.0.1:
- version "3.0.1"
- resolved "https://registry.yarnpkg.com/to-regex/-/to-regex-3.0.1.tgz#15358bee4a2c83bd76377ba1dc049d0f18837aae"
+to-regex@^3.0.1, to-regex@^3.0.2:
+ version "3.0.2"
+ resolved "https://registry.yarnpkg.com/to-regex/-/to-regex-3.0.2.tgz#13cfdd9b336552f30b51f33a8ae1b42a7a7599ce"
dependencies:
- define-property "^0.2.5"
- extend-shallow "^2.0.1"
- regex-not "^1.0.0"
+ define-property "^2.0.2"
+ extend-shallow "^3.0.2"
+ regex-not "^1.0.2"
+ safe-regex "^1.1.0"
tough-cookie@~2.3.0, tough-cookie@~2.3.3:
- version "2.3.3"
- resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.3.tgz#0b618a5565b6dea90bf3425d04d55edc475a7561"
+ version "2.3.4"
+ resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.4.tgz#ec60cee38ac675063ffc97a5c18970578ee83655"
dependencies:
punycode "^1.4.1"
@@ -6897,29 +7211,29 @@ type-detect@^1.0.0:
resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-1.0.0.tgz#762217cc06db258ec48908a1298e8b95121e8ea2"
type-detect@^4.0.0:
- version "4.0.5"
- resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.5.tgz#d70e5bc81db6de2a381bcaca0c6e0cbdc7635de2"
+ version "4.0.8"
+ resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c"
-type-is@~1.6.15:
- version "1.6.15"
- resolved "https://registry.yarnpkg.com/type-is/-/type-is-1.6.15.tgz#cab10fb4909e441c82842eafe1ad646c81804410"
+type-is@~1.6.15, type-is@~1.6.16:
+ version "1.6.16"
+ resolved "https://registry.yarnpkg.com/type-is/-/type-is-1.6.16.tgz#f89ce341541c672b25ee7ae3c73dee3b2be50194"
dependencies:
media-typer "0.3.0"
- mime-types "~2.1.15"
+ mime-types "~2.1.18"
typedarray@^0.0.6:
version "0.0.6"
resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"
-uc.micro@^1.0.1, uc.micro@^1.0.3:
- version "1.0.3"
- resolved "https://registry.yarnpkg.com/uc.micro/-/uc.micro-1.0.3.tgz#7ed50d5e0f9a9fb0a573379259f2a77458d50192"
+uc.micro@^1.0.1, uc.micro@^1.0.5:
+ version "1.0.5"
+ resolved "https://registry.yarnpkg.com/uc.micro/-/uc.micro-1.0.5.tgz#0c65f15f815aa08b560a61ce8b4db7ffc3f45376"
uglify-es@^3.1.3:
- version "3.2.2"
- resolved "https://registry.yarnpkg.com/uglify-es/-/uglify-es-3.2.2.tgz#15c62b7775002c81b7987a1c49ecd3f126cace73"
+ version "3.3.9"
+ resolved "https://registry.yarnpkg.com/uglify-es/-/uglify-es-3.3.9.tgz#0c1c4f0700bed8dbc124cdb304d2592ca203e677"
dependencies:
- commander "~2.12.1"
+ commander "~2.13.0"
source-map "~0.6.1"
uglify-js@^2.6:
@@ -6939,9 +7253,9 @@ uid-number@^0.0.6:
version "0.0.6"
resolved "https://registry.yarnpkg.com/uid-number/-/uid-number-0.0.6.tgz#0ea10e8035e8eb5b8e4449f06da1c730663baa81"
-ultron@1.0.x:
- version "1.0.2"
- resolved "https://registry.yarnpkg.com/ultron/-/ultron-1.0.2.tgz#ace116ab557cd197386a4e88f4685378c8b2e4fa"
+ultron@~1.1.0:
+ version "1.1.1"
+ resolved "https://registry.yarnpkg.com/ultron/-/ultron-1.1.1.tgz#9fe1536a10a664a65266a1e3ccf85fd36302bc9c"
underscore.string@~3.3.4:
version "3.3.4"
@@ -6994,18 +7308,40 @@ urix@^0.1.0:
version "0.1.0"
resolved "https://registry.yarnpkg.com/urix/-/urix-0.1.0.tgz#da937f7a62e21fec1fd18d49b35c2935067a6c72"
-use@^2.0.0:
- version "2.0.2"
- resolved "https://registry.yarnpkg.com/use/-/use-2.0.2.tgz#ae28a0d72f93bf22422a18a2e379993112dec8e8"
+url-parse-lax@^3.0.0:
+ version "3.0.0"
+ resolved "https://registry.yarnpkg.com/url-parse-lax/-/url-parse-lax-3.0.0.tgz#16b5cafc07dbe3676c1b1999177823d6503acb0c"
dependencies:
- define-property "^0.2.5"
- isobject "^3.0.0"
- lazy-cache "^2.0.2"
+ prepend-http "^2.0.0"
+
+url-to-options@^1.0.1:
+ version "1.0.1"
+ resolved "https://registry.yarnpkg.com/url-to-options/-/url-to-options-1.0.1.tgz#1505a03a289a48cbd7a434efbaeec5055f5633a9"
+
+use@^3.1.0:
+ version "3.1.0"
+ resolved "https://registry.yarnpkg.com/use/-/use-3.1.0.tgz#14716bf03fdfefd03040aef58d8b4b85f3a7c544"
+ dependencies:
+ kind-of "^6.0.2"
+
+user-info@^1.0.0:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/user-info/-/user-info-1.0.0.tgz#81c82b7ed63e674c2475667653413b3c76fde239"
+ dependencies:
+ os-homedir "^1.0.1"
+ passwd-user "^1.2.1"
+ username "^1.0.1"
username-sync@1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/username-sync/-/username-sync-1.0.1.tgz#1cde87eefcf94b8822984d938ba2b797426dae1f"
+username@^1.0.1:
+ version "1.0.1"
+ resolved "https://registry.yarnpkg.com/username/-/username-1.0.1.tgz#e1f72295e3e58e06f002c6327ce06897a99cd67f"
+ dependencies:
+ meow "^3.4.0"
+
util-deprecate@^1.0.2, util-deprecate@~1.0.1:
version "1.0.2"
resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf"
@@ -7015,15 +7351,15 @@ utils-merge@1.0.1:
resolved "https://registry.yarnpkg.com/utils-merge/-/utils-merge-1.0.1.tgz#9f95710f50a267947b2ccc124741c1028427e713"
uuid@^3.0.0, uuid@^3.1.0:
- version "3.1.0"
- resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.1.0.tgz#3dd3d3e790abc24d7b0d3a034ffababe28ebbc04"
+ version "3.2.1"
+ resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.2.1.tgz#12c528bb9d58d0b9265d9a2f6f0fe8be17ff1f14"
validate-npm-package-license@^3.0.1:
- version "3.0.1"
- resolved "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.1.tgz#2804babe712ad3379459acfbe24746ab2c303fbc"
+ version "3.0.3"
+ resolved "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.3.tgz#81643bcbef1bdfecd4623793dc4648948ba98338"
dependencies:
- spdx-correct "~1.0.0"
- spdx-expression-parse "~1.0.0"
+ spdx-correct "^3.0.0"
+ spdx-expression-parse "^3.0.0"
validate-npm-package-name@^3.0.0:
version "3.0.0"
@@ -7035,9 +7371,9 @@ vary@~1.1.2:
version "1.1.2"
resolved "https://registry.yarnpkg.com/vary/-/vary-1.1.2.tgz#2299f02c6ded30d4a5961b0b9f74524a18f634fc"
-"velocity-animate@>= 0.11.8":
- version "1.5.0"
- resolved "https://registry.yarnpkg.com/velocity-animate/-/velocity-animate-1.5.0.tgz#fc8771d8dfe1136ff02a707e10fbb0957c4b030f"
+velocity-animate@^1.5.1:
+ version "1.5.1"
+ resolved "https://registry.yarnpkg.com/velocity-animate/-/velocity-animate-1.5.1.tgz#606837047bab8fbfb59a636d1d82ecc3f7bd71a6"
verror@1.10.0:
version "1.10.0"
@@ -7071,9 +7407,28 @@ walker@~1.0.5:
dependencies:
makeerror "1.0.x"
-watch@~0.10.0:
- version "0.10.0"
- resolved "https://registry.yarnpkg.com/watch/-/watch-0.10.0.tgz#77798b2da0f9910d595f1ace5b0c2258521f21dc"
+watch-detector@^0.1.0:
+ version "0.1.0"
+ resolved "https://registry.yarnpkg.com/watch-detector/-/watch-detector-0.1.0.tgz#e37b410d149e2a8bf263a4f8b71e2f667633dbf8"
+ dependencies:
+ heimdalljs-logger "^0.1.9"
+ quick-temp "^0.1.8"
+ rsvp "^4.7.0"
+ semver "^5.4.1"
+ silent-error "^1.1.0"
+
+watch@~0.18.0:
+ version "0.18.0"
+ resolved "https://registry.yarnpkg.com/watch/-/watch-0.18.0.tgz#28095476c6df7c90c963138990c0a5423eb4b986"
+ dependencies:
+ exec-sh "^0.2.0"
+ minimist "^1.2.0"
+
+wcwidth@^1.0.1:
+ version "1.0.1"
+ resolved "https://registry.yarnpkg.com/wcwidth/-/wcwidth-1.0.1.tgz#f0b0dcf915bc5ff1528afadb2c0e17b532da2fe8"
+ dependencies:
+ defaults "^1.0.3"
websocket-driver@>=0.5.1:
version "0.7.0"
@@ -7087,14 +7442,14 @@ websocket-extensions@>=0.1.1:
resolved "https://registry.yarnpkg.com/websocket-extensions/-/websocket-extensions-0.1.3.tgz#5d2ff22977003ec687a4b87073dfbbac146ccf29"
whatwg-fetch@^2.0.3:
- version "2.0.3"
- resolved "https://registry.yarnpkg.com/whatwg-fetch/-/whatwg-fetch-2.0.3.tgz#9c84ec2dcf68187ff00bc64e1274b442176e1c84"
+ version "2.0.4"
+ resolved "https://registry.yarnpkg.com/whatwg-fetch/-/whatwg-fetch-2.0.4.tgz#dde6a5df315f9d39991aa17621853d720b85566f"
which-module@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/which-module/-/which-module-1.0.0.tgz#bba63ca861948994ff307736089e3b96026c2a4f"
-which@1, which@^1.2.12, which@^1.2.14, which@^1.2.9:
+which@1, which@^1.2.14, which@^1.2.9, which@^1.3.0:
version "1.3.0"
resolved "https://registry.yarnpkg.com/which/-/which-1.3.0.tgz#ff04bdfc010ee547d780bec38e1ac1c2777d253a"
dependencies:
@@ -7122,7 +7477,7 @@ wordwrap@~1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb"
-workerpool@^2.2.1:
+workerpool@^2.3.0:
version "2.3.0"
resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-2.3.0.tgz#86c5cbe946b55e7dc9d12b1936c8801a6e2d744d"
dependencies:
@@ -7153,16 +7508,13 @@ write@^0.2.1:
dependencies:
mkdirp "^0.5.1"
-ws@1.1.1:
- version "1.1.1"
- resolved "https://registry.yarnpkg.com/ws/-/ws-1.1.1.tgz#082ddb6c641e85d4bb451f03d52f06eabdb1f018"
+ws@~3.3.1:
+ version "3.3.3"
+ resolved "https://registry.yarnpkg.com/ws/-/ws-3.3.3.tgz#f1cf84fe2d5e901ebce94efaece785f187a228f2"
dependencies:
- options ">=0.0.5"
- ultron "1.0.x"
-
-wtf-8@1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/wtf-8/-/wtf-8-1.0.0.tgz#392d8ba2d0f1c34d1ee2d630f15d0efb68e1048a"
+ async-limiter "~1.0.0"
+ safe-buffer "~5.1.0"
+ ultron "~1.1.0"
xdg-basedir@^3.0.0:
version "3.0.0"
@@ -7172,9 +7524,9 @@ xmldom@^0.1.19:
version "0.1.27"
resolved "https://registry.yarnpkg.com/xmldom/-/xmldom-0.1.27.tgz#d501f97b3bdb403af8ef9ecc20573187aadac0e9"
-xmlhttprequest-ssl@1.5.3:
- version "1.5.3"
- resolved "https://registry.yarnpkg.com/xmlhttprequest-ssl/-/xmlhttprequest-ssl-1.5.3.tgz#185a888c04eca46c3e4070d99f7b49de3528992d"
+xmlhttprequest-ssl@~1.5.4:
+ version "1.5.5"
+ resolved "https://registry.yarnpkg.com/xmlhttprequest-ssl/-/xmlhttprequest-ssl-1.5.5.tgz#c2876b06168aadc40e57d97e81191ac8f4398b3e"
xtend@^4.0.0, xtend@~4.0.0:
version "4.0.1"
@@ -7188,12 +7540,12 @@ yallist@^2.1.2:
version "2.1.2"
resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52"
-yam@0.0.22:
- version "0.0.22"
- resolved "https://registry.yarnpkg.com/yam/-/yam-0.0.22.tgz#38a76cb79a19284d9206ed49031e359a1340bd06"
+yam@^0.0.24:
+ version "0.0.24"
+ resolved "https://registry.yarnpkg.com/yam/-/yam-0.0.24.tgz#11e9630444735f66a561d29221407de6d037cd95"
dependencies:
- fs-extra "^0.30.0"
- lodash.merge "^4.4.0"
+ fs-extra "^4.0.2"
+ lodash.merge "^4.6.0"
yargs-parser@^5.0.0:
version "5.0.0"
From 26ccb1250a39cf654750ddb6633d79e522a34626 Mon Sep 17 00:00:00 2001
From: Miguel Camba
Date: Sun, 15 Apr 2018 23:07:01 +0200
Subject: [PATCH 09/34] Modernize test suite part 1 (#1089)
---
package.json | 1 +
tests/acceptance/all-public-pages-test.js | 2 +-
tests/acceptance/helpers-test.js | 105 +++++++------
.../components/power-select/a11y-test.js | 7 +-
.../power-select/custom-search-test.js | 9 +-
.../customization-with-components-test.js | 9 +-
.../components/power-select/disabled-test.js | 41 ++---
.../power-select/general-behaviour-test.js | 145 +++++++++---------
.../components/power-select/groups-test.js | 7 +-
.../power-select/keyboard-control-test.js | 139 ++++++++---------
yarn.lock | 7 +
11 files changed, 243 insertions(+), 229 deletions(-)
diff --git a/package.json b/package.json
index e113e758c..ecf439ba1 100644
--- a/package.json
+++ b/package.json
@@ -83,6 +83,7 @@
"loader.js": "^4.6.0",
"memory-scroll": "0.9.1",
"mocha": "2.5.3",
+ "qunit-dom": "^0.6.2",
"simple-git": "^1.10.0",
"testdouble": "^3.2.6"
},
diff --git a/tests/acceptance/all-public-pages-test.js b/tests/acceptance/all-public-pages-test.js
index 45d0165a0..3ae9733ce 100644
--- a/tests/acceptance/all-public-pages-test.js
+++ b/tests/acceptance/all-public-pages-test.js
@@ -1,7 +1,7 @@
import { test, module } from 'qunit';
import { setupApplicationTest } from 'ember-qunit';
import { visit, click, currentURL } from '@ember/test-helpers';
-import { find } from 'ember-native-dom-helpers';
+import { find } from '@ember/test-helpers';
module('Acceptance | All Public Pages', function(hooks) {
setupApplicationTest(hooks);
diff --git a/tests/acceptance/helpers-test.js b/tests/acceptance/helpers-test.js
index e027bde0c..ba09bfa46 100644
--- a/tests/acceptance/helpers-test.js
+++ b/tests/acceptance/helpers-test.js
@@ -1,7 +1,6 @@
import { test, module } from 'qunit';
import { setupApplicationTest } from 'ember-qunit';
import { click, visit, currentURL } from '@ember/test-helpers';
-import { find, findAll } from 'ember-native-dom-helpers';
import { selectChoose, selectSearch, removeMultipleOption, clearSelected } from 'ember-power-select/test-support/helpers';
module('Acceptance | helpers | selectChoose', function(hooks) {
@@ -13,9 +12,9 @@ module('Acceptance | helpers | selectChoose', function(hooks) {
assert.equal(currentURL(), '/helpers-testing');
await selectChoose('.select-choose', 'three');
- assert.equal(find('.select-choose .ember-power-select-trigger').textContent.trim(), 'three', 'The proper value has been selected');
- assert.notOk(find('.ember-power-select-options'), 'The selectis closed');
- assert.equal(find('.select-choose-target').textContent.trim(), 'You\'ve selected: three');
+ assert.dom('.select-choose .ember-power-select-trigger').hasText('three', 'The proper value has been selected');
+ assert.dom('.ember-power-select-options').doesNotExist('The selectis closed');
+ assert.dom('.select-choose-target').hasText('You\'ve selected: three');
});
test('selectChoose selects the option with the given text on an already opened select', async function(assert) {
@@ -25,9 +24,9 @@ module('Acceptance | helpers | selectChoose', function(hooks) {
await click('.select-choose .ember-power-select-trigger');
await selectChoose('.select-choose', 'three');
- assert.equal(find('.select-choose .ember-power-select-trigger').textContent.trim(), 'three', 'The proper value has been selected');
- assert.notOk(find('.ember-power-select-options'), 'The selectis closed');
- assert.equal(find('.select-choose-target').textContent.trim(), 'You\'ve selected: three');
+ assert.dom('.select-choose .ember-power-select-trigger').hasText('three', 'The proper value has been selected');
+ assert.dom('.ember-power-select-options').doesNotExist('The selectis closed');
+ assert.dom('.select-choose-target').hasText('You\'ve selected: three');
});
test('the selectChoose helper works with an onopen function that fetches data async on single selects', async function(assert) {
@@ -35,9 +34,9 @@ module('Acceptance | helpers | selectChoose', function(hooks) {
assert.equal(currentURL(), '/helpers-testing');
await selectChoose('.select-choose-onopen', 'three');
- assert.equal(find('.select-choose-onopen .ember-power-select-trigger').textContent.trim().split(' ')[0].trim(), 'three', 'The proper value has been selected');
- assert.notOk(find('.ember-power-select-options'), 'The select is closed');
- assert.equal(find('.select-choose-target').textContent.trim(), 'You\'ve selected: three');
+ assert.dom('.select-choose-onopen .ember-power-select-trigger').containsText('three', 'The proper value has been selected');
+ assert.dom('.ember-power-select-options').doesNotExist('The select is closed');
+ assert.dom('.select-choose-target').hasText('You\'ve selected: three');
});
test('the selectChoose helper works with an onopen function that fetches data async on multiple selects', async function(assert) {
@@ -45,9 +44,9 @@ module('Acceptance | helpers | selectChoose', function(hooks) {
assert.equal(currentURL(), '/helpers-testing');
await selectChoose('.select-choose-onopen-multiple', 'three');
- assert.equal(findAll('.select-choose-onopen-multiple .ember-power-select-multiple-option').length, 1, 'One options has been selected');
- assert.ok(/three/.test(find('.select-choose-onopen-multiple .ember-power-select-multiple-option').textContent.trim()), 'The proper value has been selected');
- assert.notOk(find('.ember-power-select-options'), 'The selectis closed');
+ assert.dom('.select-choose-onopen-multiple .ember-power-select-multiple-option').exists({ count: 1 }, 'One options has been selected');
+ assert.dom('.select-choose-onopen-multiple .ember-power-select-multiple-option').containsText('three', 'The proper value has been selected');
+ assert.dom('.ember-power-select-options').doesNotExist('The selectis closed');
});
test('the selectChoose helper works when it receives the class of the trigger', async function(assert) {
@@ -55,9 +54,9 @@ module('Acceptance | helpers | selectChoose', function(hooks) {
assert.equal(currentURL(), '/helpers-testing');
await selectChoose('.select-with-class-in-trigger', 'three');
- assert.equal(find('.select-with-class-in-trigger').textContent.trim(), 'three', 'The proper value has been selected');
- assert.notOk(find('.ember-power-select-options'), 'The selectis closed');
- assert.equal(find('.select-choose-target').textContent.trim(), 'You\'ve selected: three');
+ assert.dom('.select-with-class-in-trigger').hasText('three', 'The proper value has been selected');
+ assert.dom('.ember-power-select-options').doesNotExist('The selectis closed');
+ assert.dom('.select-choose-target').hasText('You\'ve selected: three');
});
test('the selectChoose helper works when it receives the css selector of the chosen option as second arguments', async function(assert) {
@@ -65,9 +64,9 @@ module('Acceptance | helpers | selectChoose', function(hooks) {
assert.equal(currentURL(), '/helpers-testing');
await selectChoose('.select-with-class-in-trigger', '.ember-power-select-option:nth-child(3)');
- assert.equal(find('.select-choose').textContent.trim(), 'three', 'The proper value has been selected');
- assert.notOk(find('.ember-power-select-options'), 'The selectis closed');
- assert.equal(find('.select-choose-target').textContent.trim(), 'You\'ve selected: three');
+ assert.dom('.select-choose').hasText('three', 'The proper value has been selected');
+ assert.dom('.ember-power-select-options').doesNotExist('The selectis closed');
+ assert.dom('.select-choose-target').hasText('You\'ve selected: three');
});
test('the selectChoose helper works when it receives a wildcard css class', async function(assert) {
@@ -75,29 +74,29 @@ module('Acceptance | helpers | selectChoose', function(hooks) {
assert.equal(currentURL(), '/helpers-testing-single-power-select');
await selectChoose('*', 'three');
- assert.equal(find('.select-choose').textContent.trim(), 'three', 'The proper value has been selected');
- assert.notOk(find('.ember-power-select-options'), 'The selectis closed');
- assert.equal(find('.select-choose-target').textContent.trim(), 'You\'ve selected: three');
+ assert.dom('.select-choose').hasText('three', 'The proper value has been selected');
+ assert.dom('.ember-power-select-options').doesNotExist('The selectis closed');
+ assert.dom('.select-choose-target').hasText('You\'ve selected: three');
});
test('the selectChoose helper works when it receives a HTMLElement as first argument', async function(assert) {
await visit('/helpers-testing');
assert.equal(currentURL(), '/helpers-testing');
- await selectChoose(find('.select-with-class-in-trigger'), 'three');
- assert.equal(find('.select-choose').textContent.trim(), 'three', 'The proper value has been selected');
- assert.notOk(find('.ember-power-select-options'), 'The selectis closed');
- assert.equal(find('.select-choose-target').textContent.trim(), 'You\'ve selected: three');
+ await selectChoose(this.element.querySelector('.select-with-class-in-trigger'), 'three');
+ assert.dom('.select-choose').hasText('three', 'The proper value has been selected');
+ assert.dom('.ember-power-select-options').doesNotExist('The selectis closed');
+ assert.dom('.select-choose-target').hasText('You\'ve selected: three');
});
test('the selectChoose helper can receive a number as third argument to select the :nth option', async function(assert) {
await visit('/helpers-testing');
assert.equal(currentURL(), '/helpers-testing');
- await selectChoose(find('.select-with-class-in-trigger'), '.ember-power-select-option', 2);
- assert.equal(find('.select-choose').textContent.trim(), 'three', 'The proper value has been selected');
- assert.notOk(find('.ember-power-select-options'), 'The selectis closed');
- assert.equal(find('.select-choose-target').textContent.trim(), 'You\'ve selected: three');
+ await selectChoose(this.element.querySelector('.select-with-class-in-trigger'), '.ember-power-select-option', 2);
+ assert.dom('.select-choose').hasText('three', 'The proper value has been selected');
+ assert.dom('.ember-power-select-options').doesNotExist('The selectis closed');
+ assert.dom('.select-choose-target').hasText('You\'ve selected: three');
});
test('selectChoose helper throws an explicative error when no select is found in the given scope', async function(assert) {
@@ -134,7 +133,7 @@ module('Acceptance | helpers | selectSearch', function(hooks) {
await click('.select-async .ember-power-select-trigger');
await selectSearch('.select-async', 'three');
- assert.equal(find('.ember-power-select-options').textContent.trim(), 'three');
+ assert.dom('.ember-power-select-options').hasText('three');
});
test('selectSearch helper searches an opened select if using a wildcard css selector', async function(assert) {
@@ -143,7 +142,7 @@ module('Acceptance | helpers | selectSearch', function(hooks) {
await click('.ember-power-select-trigger');
await selectSearch('*', 'three');
- assert.equal(find('.ember-power-select-options').textContent.trim(), 'three');
+ assert.dom('.ember-power-select-options').hasText('three');
});
test('selectSearch helper opens and searches select if using a wildcard css selector', async function(assert) {
@@ -152,7 +151,7 @@ module('Acceptance | helpers | selectSearch', function(hooks) {
await click('.ember-power-select-trigger');
await selectSearch('*', 'three');
- assert.equal(find('.ember-power-select-options').textContent.trim(), 'three');
+ assert.dom('.ember-power-select-options').hasText('three');
});
test('selectSearch helper searches in the given single select, opening it if needed', async function(assert) {
@@ -160,7 +159,7 @@ module('Acceptance | helpers | selectSearch', function(hooks) {
assert.equal(currentURL(), '/helpers-testing');
await selectSearch('.select-async', 'three');
- assert.equal(find('.ember-power-select-options').textContent.trim(), 'three');
+ assert.dom('.ember-power-select-options').hasText('three');
});
test('selectSearch helper searches in the given multiple select opened', async function(assert) {
@@ -169,14 +168,14 @@ module('Acceptance | helpers | selectSearch', function(hooks) {
await click('.select-multiple .ember-power-select-trigger');
await selectSearch('.select-multiple', 'three');
- assert.equal(find('.ember-power-select-options').textContent.trim(), 'three');
+ assert.dom('.ember-power-select-options').hasText('three');
});
test('selectSearch helper searches in the given multiple select closed', async function(assert) {
await visit('/helpers-testing');
assert.equal(currentURL(), '/helpers-testing');
await selectSearch('.select-multiple', 'three');
- assert.equal(find('.ember-power-select-options').textContent.trim(), 'three');
+ assert.dom('.ember-power-select-options').hasText('three');
});
test('selectSearch helper works even with custom components as long as the input has [type=search]', async function(assert) {
@@ -184,22 +183,22 @@ module('Acceptance | helpers | selectSearch', function(hooks) {
assert.equal(currentURL(), '/helpers-testing');
await click('.select-custom-search .ember-power-select-trigger');
await selectSearch('.select-custom-search', 'three');
- assert.equal(find('.ember-power-select-options').textContent.trim(), 'three');
+ assert.dom('.ember-power-select-options').hasText('three');
});
test('selectSearch helper can receive the HTMLElement of the trigger as first arguments', async function(assert) {
await visit('/helpers-testing');
assert.equal(currentURL(), '/helpers-testing');
- await selectSearch(find('.select-multiple .ember-power-select-trigger'), 'three');
- assert.equal(find('.ember-power-select-options').textContent.trim(), 'three');
+ await selectSearch(this.element.querySelector('.select-multiple .ember-power-select-trigger'), 'three');
+ assert.dom('.ember-power-select-options').hasText('three');
});
test('the selectSearch helper works when it receives the class of the trigger', async function(assert) {
await visit('/helpers-testing');
assert.equal(currentURL(), '/helpers-testing');
await selectSearch('.select-with-class-in-trigger', 'three');
- assert.equal(find('.ember-power-select-options').textContent.trim(), 'three');
+ assert.dom('.ember-power-select-options').hasText('three');
});
test('the selectSearch helper throws an explicative error when no select is found in the given scope', async function(assert) {
@@ -222,13 +221,13 @@ module('Acceptance | helpers | removeMultipleOption', function(hooks) {
await selectChoose('.select-choose-onopen-multiple', 'three');
await selectChoose('.select-choose-onopen-multiple', 'four');
- assert.equal(findAll('.select-choose-onopen-multiple .ember-power-select-trigger > .ember-power-select-multiple-options > li').length, 2, 'Multiple options selected');
+ assert.dom('.select-choose-onopen-multiple .ember-power-select-trigger > .ember-power-select-multiple-options > li').exists({ count: 2 }, 'Multiple options selected');
await removeMultipleOption('.select-choose-onopen-multiple', 'three');
- assert.equal(findAll('.select-choose-onopen-multiple .ember-power-select-trigger > .ember-power-select-multiple-options > li').length, 1, 'One option removed');
+ assert.dom('.select-choose-onopen-multiple .ember-power-select-trigger > .ember-power-select-multiple-options > li').exists({ count: 1 }, 'One option removed');
await removeMultipleOption('.select-choose-onopen-multiple', 'four');
- assert.equal(findAll('.select-choose-onopen-multiple .ember-power-select-trigger > .ember-power-select-multiple-options > li').length, 0, 'Last option removed');
+ assert.dom('.select-choose-onopen-multiple .ember-power-select-trigger > .ember-power-select-multiple-options > li').exists({ count: 0 }, 'Last option removed');
});
test('removeMultipleOption works with async onchange action', async function(assert) {
@@ -236,10 +235,10 @@ module('Acceptance | helpers | removeMultipleOption', function(hooks) {
await selectChoose('#select-multiple-async', 'three');
await selectChoose('#select-multiple-async', 'four');
- assert.equal(findAll('#select-multiple-async .ember-power-select-multiple-option').length, 2, 'Multiple options selected');
+ assert.dom('#select-multiple-async .ember-power-select-multiple-option').exists({ count: 2 }, 'Multiple options selected');
await removeMultipleOption('#select-multiple-async', 'three');
- assert.equal(findAll('#select-multiple-async .ember-power-select-multiple-option').length, 1, 'One option removed');
+ assert.dom('#select-multiple-async .ember-power-select-multiple-option').exists({ count: 1 }, 'One option removed');
});
});
@@ -248,26 +247,26 @@ module('Acceptance | helpers | clearSelected', function(hooks) {
test('clearSelected removes selected option', async function(assert) {
await visit('/helpers-testing');
- assert.notOk(find('.select-choose-onopen .ember-power-select-clear-btn'));
+ assert.dom('.select-choose-onopen .ember-power-select-clear-btn').doesNotExist();
await selectChoose('.select-choose-onopen', 'three');
- assert.ok(find('.select-choose-onopen .ember-power-select-clear-btn'));
- assert.ok(find('.select-choose-onopen .ember-power-select-selected-item').textContent.trim(), 'three', 'The proper value has been selected');
+ assert.dom('.select-choose-onopen .ember-power-select-clear-btn').exists();
+ assert.dom('.select-choose-onopen .ember-power-select-selected-item').hasText('three', 'The proper value has been selected');
await clearSelected('.select-choose-onopen', 'three');
- assert.notOk(find('.select-choose-onopen .ember-power-select-clear-btn'));
+ assert.dom('.select-choose-onopen .ember-power-select-clear-btn').doesNotExist();
});
test('clearSelected works with async onchange action', async function(assert) {
await visit('/helpers-testing');
- assert.notOk(find('.select-deselect-async .ember-power-select-clear-btn'));
+ assert.dom('.select-deselect-async .ember-power-select-clear-btn').doesNotExist();
await selectChoose('.select-deselect-async', 'three');
- assert.ok(find('.select-deselect-async .ember-power-select-clear-btn'));
- assert.ok(find('.select-deselect-async .ember-power-select-selected-item').textContent.trim(), 'three', 'The proper value has been selected');
+ assert.dom('.select-deselect-async .ember-power-select-clear-btn').exists();
+ assert.dom('.select-deselect-async .ember-power-select-selected-item').hasText('three', 'The proper value has been selected');
await clearSelected('.select-deselect-async', 'three');
- assert.notOk(find('.select-deselect-async .ember-power-select-clear-btn'));
+ assert.dom('.select-deselect-async .ember-power-select-clear-btn').doesNotExist();
});
});
diff --git a/tests/integration/components/power-select/a11y-test.js b/tests/integration/components/power-select/a11y-test.js
index b926eca4b..5dbe13168 100644
--- a/tests/integration/components/power-select/a11y-test.js
+++ b/tests/integration/components/power-select/a11y-test.js
@@ -4,7 +4,8 @@ import { render } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { numbers, groupedNumbers, countriesWithDisabled } from '../constants';
import { clickTrigger, findContains } from 'ember-power-select/test-support/helpers';
-import { find, findAll, keyEvent } from 'ember-native-dom-helpers';
+import { triggerKeyEvent } from '@ember/test-helpers';
+import { find, findAll } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (Accesibility)', function(hooks) {
setupRenderingTest(hooks);
@@ -117,7 +118,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
clickTrigger();
assert.equal(findContains('.ember-power-select-option', 'one').attributes['aria-current'].value, 'true', 'the highlighted option has aria-current=true');
assert.equal(findAll('.ember-power-select-option[aria-current="false"]').length, numbers.length - 1, 'All other options have aria-current=false');
- keyEvent('.ember-power-select-search-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
assert.equal(findContains('.ember-power-select-option', 'one').attributes['aria-current'].value, 'false', 'the first option has now aria-current=false');
assert.equal(findContains('.ember-power-select-option', 'two').attributes['aria-current'].value, 'true', 'the second option has now aria-current=false');
});
@@ -135,7 +136,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
clickTrigger();
assert.equal(findContains('.ember-power-select-option', 'one').attributes['aria-current'].value, 'true', 'the highlighted option has aria-current=true');
assert.equal(findAll('.ember-power-select-option[aria-current="false"]').length, numbers.length - 1, 'All other options have aria-current=false');
- keyEvent('.ember-power-select-search-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
assert.equal(findContains('.ember-power-select-option', 'one').attributes['aria-current'].value, 'false', 'the first option has now aria-current=false');
assert.equal(findContains('.ember-power-select-option', 'two').attributes['aria-current'].value, 'true', 'the second option has now aria-current=false');
});
diff --git a/tests/integration/components/power-select/custom-search-test.js b/tests/integration/components/power-select/custom-search-test.js
index 395cdd7e1..e594ed703 100644
--- a/tests/integration/components/power-select/custom-search-test.js
+++ b/tests/integration/components/power-select/custom-search-test.js
@@ -7,7 +7,8 @@ import { render, settled } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
import { numbers, countries } from '../constants';
-import { find, findAll, click } from 'ember-native-dom-helpers';
+import { click } from '@ember/test-helpers';
+import { find, findAll } from 'ember-native-dom-helpers';
import RSVP from 'rsvp';
module('Integration | Component | Ember Power Select (Custom search function)', function(hooks) {
@@ -320,13 +321,13 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
assert.equal(findAll('.ember-power-select-option').length, 7, 'Results are filtered');
assert.equal(find('.ember-power-select-search-input').value, 'teen');
- click('#different-node');
+ await click('#different-node');
- clickTrigger();
+ await clickTrigger();
assert.equal(findAll('.ember-power-select-option').length, 1, 'Results have been cleared');
assert.equal(find('.ember-power-select-option').textContent.trim(), 'Type to search');
assert.equal(find('.ember-power-select-search-input').value, '', 'The searchbox was cleared');
diff --git a/tests/integration/components/power-select/customization-with-components-test.js b/tests/integration/components/power-select/customization-with-components-test.js
index db908422e..211ea5874 100644
--- a/tests/integration/components/power-select/customization-with-components-test.js
+++ b/tests/integration/components/power-select/customization-with-components-test.js
@@ -5,7 +5,8 @@ import hbs from 'htmlbars-inline-precompile';
import { countries } from '../constants';
import { groupedNumbers } from '../constants';
import { clickTrigger } from 'ember-power-select/test-support/helpers';
-import { find, findAll, click, focus } from 'ember-native-dom-helpers';
+import { click, focus } from '@ember/test-helpers';
+import { find, findAll } from 'ember-native-dom-helpers';
import { get } from '@ember/object';
import Component from '@ember/component';
import { isPresent } from '@ember/utils';
@@ -161,9 +162,9 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{/power-select}}
`);
- clickTrigger();
- click('.custom-before-options2-button');
- click('.custom-after-options2-button');
+ await clickTrigger();
+ await click('.custom-before-options2-button');
+ await click('.custom-after-options2-button');
assert.equal(counter, 2, 'The action inside the extra hash has been called twice');
});
diff --git a/tests/integration/components/power-select/disabled-test.js b/tests/integration/components/power-select/disabled-test.js
index 765485131..0d5cb7ee7 100644
--- a/tests/integration/components/power-select/disabled-test.js
+++ b/tests/integration/components/power-select/disabled-test.js
@@ -5,7 +5,8 @@ import hbs from 'htmlbars-inline-precompile';
import { run } from '@ember/runloop';
import { clickTrigger, typeInSearch } from 'ember-power-select/test-support/helpers';
import { numbers, countriesWithDisabled } from '../constants';
-import { find, findAll, triggerEvent, keyEvent, click, focus } from 'ember-native-dom-helpers';
+import { triggerEvent, triggerKeyEvent, click, focus } from '@ember/test-helpers';
+import { find, findAll } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (Disabled)', function(hooks) {
setupRenderingTest(hooks);
@@ -22,9 +23,9 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
let trigger = find('.ember-power-select-trigger');
assert.ok(trigger.attributes['aria-disabled'].value, 'true', 'The trigger has `aria-disabled=true`');
- clickTrigger();
+ await clickTrigger();
assert.notOk(find('.ember-power-select-dropdown'), 'The select is still closed');
- keyEvent('.ember-power-select-trigger', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
assert.notOk(find('.ember-power-select-dropdown'), 'The select is still closed');
});
@@ -50,8 +51,8 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select}}
`);
- clickTrigger();
- triggerEvent('.ember-power-select-option[aria-disabled="true"]', 'mouseover');
+ await clickTrigger();
+ await triggerEvent('.ember-power-select-option[aria-disabled="true"]', 'mouseover');
assert.equal(find('.ember-power-select-option[aria-disabled="true"]').attributes['aria-current'].value, 'false', 'The hovered option was not highlighted because it\'s disabled');
});
@@ -65,9 +66,9 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select}}
`);
- clickTrigger();
- keyEvent('.ember-power-select-search-input', 'keydown', 40);
- keyEvent('.ember-power-select-search-input', 'keydown', 40);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'LV: Latvia', 'The hovered option was not highlighted because it\'s disabled');
});
@@ -129,10 +130,10 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('Br');
assert.notOk(find('.ember-power-select-option[aria-current="true"]'), 'Nothing is highlighted');
- keyEvent('.ember-power-select-search-input', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing was selected');
});
@@ -147,7 +148,7 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('o'); // Finds ["Portugal", "United Kingdom"]
assert.equal(findAll('.ember-power-select-option').length, 2, 'There is two results');
assert.equal(findAll('.ember-power-select-option[aria-disabled="true"]').length, 1, 'One is disabled');
@@ -167,9 +168,9 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
`);
let trigger = find('.ember-power-select-trigger');
- focus(trigger);
+ await focus(trigger);
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- keyEvent(trigger, 'keydown', 85); // u
+ await triggerKeyEvent(trigger, 'keydown', 85); // u
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
assert.equal(trigger.textContent.trim(), 'United Kingdom', '"United Kingdom" has been selected');
});
@@ -199,7 +200,7 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(findAll('.ember-power-select-group[aria-disabled="true"]').length, 1, 'one group is disabled');
typeInSearch('fiv');
assert.equal(findAll('.ember-power-select-group[aria-disabled="true"]').length, 1, 'one group is still disabled');
@@ -231,12 +232,12 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one');
assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'No option is selected');
- triggerEvent(findAll('.ember-power-select-option')[8], 'mouseover');
+ await triggerEvent(findAll('.ember-power-select-option')[8], 'mouseover');
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one');
- click(findAll('.ember-power-select-option')[9]);
+ await click(findAll('.ember-power-select-option')[9]);
assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'Noting was selected');
});
@@ -268,7 +269,7 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The select is open');
run(() => this.set('isDisabled', true));
assert.notOk(find('.ember-power-select-dropdown'), 'The select is now closed');
@@ -284,8 +285,8 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select}}
`);
- clickTrigger();
- click(findAll('.ember-power-select-option')[1]);
+ await clickTrigger();
+ await click(findAll('.ember-power-select-option')[1]);
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'two', 'The option is selected');
assert.equal(find('.ember-power-select-trigger').attributes['aria-disabled'].value, 'true');
});
diff --git a/tests/integration/components/power-select/general-behaviour-test.js b/tests/integration/components/power-select/general-behaviour-test.js
index 9efc2855c..79748e67e 100644
--- a/tests/integration/components/power-select/general-behaviour-test.js
+++ b/tests/integration/components/power-select/general-behaviour-test.js
@@ -14,7 +14,8 @@ import {
} from '../constants';
import PromiseProxyMixin from '@ember/object/promise-proxy-mixin';
import ArrayProxy from '@ember/array/proxy';
-import { find, findAll, click, keyEvent, triggerEvent, focus } from 'ember-native-dom-helpers';
+import { click, triggerKeyEvent, triggerEvent, focus } from '@ember/test-helpers';
+import { find, findAll } from 'ember-native-dom-helpers';
const PromiseArrayProxy = ArrayProxy.extend(PromiseProxyMixin);
@@ -33,7 +34,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
});
@@ -47,10 +48,10 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
- clickTrigger();
+ await clickTrigger();
assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
});
@@ -64,7 +65,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-search'), 'The search box is rendered');
});
@@ -78,7 +79,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
assert.notOk(find('.ember-power-select-search'), 'The search box NOT rendered');
});
@@ -99,7 +100,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-search-input') !== document.activeElement, 'The search box is not focused after opening select');
});
@@ -113,7 +114,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
let options = findAll('.ember-power-select-option');
assert.equal(options.length, numbers.length, 'There is as many options in the markup as in the supplied array');
assert.equal(options[0].textContent.trim(), 'one');
@@ -184,8 +185,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
assert.equal(find('.ember-power-select-trigger .ember-power-select-placeholder').textContent.trim(), 'abracadabra', 'The placeholder is rendered when there is no element');
- clickTrigger();
- click(findAll('.ember-power-select-option')[3]);
+ await clickTrigger();
+ await click(findAll('.ember-power-select-option')[3]);
assert.notOk(find('.ember-power-select-trigger .ember-power-select-placeholder'), 'The placeholder is gone');
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', 'The selected item replaced it');
});
@@ -200,7 +201,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-search-input').attributes.placeholder.value, 'foobar yo!', 'The searchbox has the proper placeholder');
});
@@ -221,7 +222,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
run(() => this.set('selected', 'three'));
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'three', 'The `three` element is selected');
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'three', 'The proper option gets highlighed');
assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'three', 'The proper option gets selected');
});
@@ -238,8 +239,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing is selected');
- clickTrigger();
- click(findAll('.ember-power-select-option')[3]);
+ await clickTrigger();
+ await click(findAll('.ember-power-select-option')[3]);
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', '"four" has been selected');
run(() => this.set('selected', 'three'));
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'three', '"three" has been selected because a change came from the outside');
@@ -255,7 +256,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is inside the component');
});
@@ -270,9 +271,9 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
- click(findAll('.ember-power-select-option')[3]);
+ await click(findAll('.ember-power-select-option')[3]);
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', '"four" has been selected');
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
});
@@ -288,9 +289,9 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
- keyEvent('.ember-power-select-search-input', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'one', '"one" has been selected');
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
});
@@ -314,7 +315,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
hbs`{{#power-select options=proxy search=(action search) onchange=(action (mut foo)) as |option|}} {{option}} {{/power-select}}`
);
- clickTrigger();
+ await clickTrigger();
typeInSearch('o');
setTimeout(function() {
@@ -343,7 +344,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
hbs`{{#power-select options=proxy search=(action search) onchange=(action (mut foo)) as |option|}} {{option}} {{/power-select}}`
);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-option'), 'The dropdown is opened and results shown with initial proxy contents');
assert.equal(find('.ember-power-select-option').textContent.trim(), 'one');
@@ -367,8 +368,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{option}}
{{/power-select}}
`);
- clickTrigger();
- keyEvent('.ember-power-select-search-input', 'keydown', 40);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'two', 'The second options is highlighted');
run(() => this.set('numbers', ['foo', 'bar', 'baz']));
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'foo', 'The first element is highlighted');
@@ -383,7 +384,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{option}}
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown').classList.contains('this-is-a-test-class'), 'dropdownClass can be customized');
});
@@ -397,11 +398,11 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
- typeInSearch('th');
+ await clickTrigger();
+ await typeInSearch('th');
assert.equal(findAll('.ember-power-select-option').length, 2, 'the dropdown has filtered the results');
- triggerEvent('#outside-div', 'mousedown');
- clickTrigger();
+ await triggerEvent('#outside-div', 'mousedown');
+ await clickTrigger();
assert.equal(findAll('.ember-power-select-option').length, numbers.length, 'the dropdown has shows all results');
});
@@ -414,11 +415,11 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('tw');
assert.equal(findAll('.ember-power-select-option')[0].textContent.trim(), 'tw:two', 'Each option receives the public API');
- click(findAll('.ember-power-select-option')[0]);
- clickTrigger();
+ await click(findAll('.ember-power-select-option')[0]);
+ await clickTrigger();
typeInSearch('thr');
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'thr:two', 'The trigger also receives the public API');
});
@@ -430,7 +431,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{option}}
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(findAll('.ember-power-select-option').length, 1);
assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found');
assert.ok(find('.ember-power-select-option').classList.contains('ember-power-select-option--no-matches-message'), 'The row has a special class to differentiate it from regular options');
@@ -444,7 +445,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{option}}
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(findAll('.ember-power-select-option').length, 1);
assert.equal(find('.ember-power-select-option').textContent.trim(), 'Type to search');
typeInSearch('foo');
@@ -459,7 +460,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{option}}
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(findAll('.ember-power-select-option').length, 1);
assert.equal(find('.ember-power-select-option').textContent.trim(), 'Nope');
});
@@ -472,7 +473,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{option}}
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(findAll('.ember-power-select-option').length, 0);
typeInSearch('foo');
assert.equal(findAll('.ember-power-select-option').length, 1);
@@ -488,7 +489,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
Foo bar
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.notOk(find('.ember-power-select-option'), 'No list elements, just the given alternate block');
assert.ok(find('.empty-option-foo'));
});
@@ -503,7 +504,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
assert.equal(findAll('.ember-power-select-option[aria-current="true"]').length, 1, 'One element is highlighted');
assert.equal(findAll('.ember-power-select-option')[0].attributes['aria-current'].value, 'true', 'The first one to be precise');
@@ -539,7 +540,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
let highlightedOption = find('.ember-power-select-option[aria-current="true"]');
assert.ok(highlightedOption, 'One element is highlighted');
assert.equal(highlightedOption.textContent.trim(), 'three', 'The third option is highlighted');
@@ -555,7 +556,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
let selectedOption = findAll('.ember-power-select-option')[2];
assert.equal(selectedOption.attributes['aria-selected'].value, 'true', 'The third option is marked as selected');
});
@@ -570,7 +571,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('mar');
let options = findAll('.ember-power-select-option');
assert.equal(options.length, 2, 'Only 2 results match the search');
@@ -601,7 +602,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('on');
assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found', 'No number ends in "on"');
typeInSearch('teen');
@@ -618,7 +619,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
assert.equal(findAll('.ember-power-select-option[aria-current="true"]').length, 1, 'One element is highlighted');
assert.equal(findAll('.ember-power-select-option')[0].attributes['aria-current'].value, 'true', 'The first one to be precise');
@@ -649,7 +650,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
let highlightedOption = find('.ember-power-select-option[aria-current="true"]');
assert.ok(highlightedOption, 'One element is highlighted');
assert.equal(highlightedOption.textContent.trim(), 'ES: Spain', 'The second option is highlighted');
@@ -666,7 +667,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
let selectedOption = findContains('.ember-power-select-option', 'ES: Spain');
assert.equal(selectedOption.attributes['aria-selected'].value, 'true', 'The second option is marked as selected');
});
@@ -689,7 +690,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('mar');
let options = findAll('.ember-power-select-option');
assert.equal(options.length, 2, 'Only 2 results match the search');
@@ -728,7 +729,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('s');
let options = findAll('.ember-power-select-option');
assert.equal(options.length, 3, 'Only 3 results match the search');
@@ -748,12 +749,12 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'three', 'The third element is highlighted');
- keyEvent('.ember-power-select-search-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The forth element is highlighted');
- clickTrigger();
- clickTrigger();
+ await clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'three', 'The third element is highlighted again');
});
@@ -767,12 +768,12 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first element is highlighted');
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 40);
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'two', 'The second element is highlighted');
- clickTrigger();
- clickTrigger();
+ await clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first element is highlighted again');
});
@@ -850,7 +851,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', 'The trigger has the proper content');
@@ -941,7 +942,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
// {{/power-select}}
// `);
- // clickTrigger();
+ // await clickTrigger();
// assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
// assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing is selected yet');
@@ -979,7 +980,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
// {{/power-select}}
// `);
- // clickTrigger();
+ // await clickTrigger();
// assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
// assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing is selected yet');
@@ -1008,7 +1009,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
assert.ok(!find('.ember-power-select-trigger').classList.contains('ember-power-select-trigger--active'), 'The select doesn\'t have the class yet');
- clickTrigger();
+ await clickTrigger();
focus('.ember-power-select-search-input');
assert.ok(find('.ember-power-select-trigger').classList.contains('ember-power-select-trigger--active'), 'The select has the class now');
});
@@ -1023,7 +1024,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'nine');
assert.ok(findAll('.ember-power-select-options')[0].scrollTop > 0, 'The list has scrolled');
});
@@ -1041,7 +1042,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
- clickTrigger();
+ await clickTrigger();
assert.ok(find('#alternative-destination .ember-power-select-dropdown'), 'Dropdown is rendered inside the destination element');
});
@@ -1057,8 +1058,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
- keyEvent('.ember-power-select-search-input', 'keydown', 40);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'two');
run(() => this.set('numbers', ['one', 'three', 'five', 'seven', 'nine']));
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one');
@@ -1075,7 +1076,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'five', 'the given element is highlighted instead of the first, as usual');
});
@@ -1103,7 +1104,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'five', 'the given element is highlighted instead of the first, as usual');
});
@@ -1134,14 +1135,14 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('M');
- click(findAll('.ember-power-select-option')[1]);
- clickTrigger();
+ await click(findAll('.ember-power-select-option')[1]);
+ await clickTrigger();
typeInSearch('i');
let firstOption = findAll('.ember-power-select-option')[0];
assert.equal(firstOption.attributes['aria-selected'].value, 'true', 'The item in the list is marked as selected');
- click(firstOption);
+ await click(firstOption);
assert.equal(onChangeInvocationsCount, 1);
});
@@ -1175,15 +1176,15 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
let dropdownContent = find('.ember-power-select-dropdown');
assert.ok(dropdownContent.classList.contains('ember-basic-dropdown-content--above'), 'The dropdown is above');
assert.ok(dropdownContent.classList.contains('ember-basic-dropdown-content--right'), 'The dropdown is in the right');
assert.equal(dropdownContent.attributes.style.value, 'top: 111px;right: 222px;', 'The style attribute is the expected one');
- clickTrigger();
+ await clickTrigger();
run(() => this.set('renderInPlace', true));
- clickTrigger();
+ await clickTrigger();
dropdownContent = find('.ember-power-select-dropdown');
assert.ok(dropdownContent.classList.contains('ember-basic-dropdown-content--below'), 'The dropdown is below');
assert.ok(dropdownContent.classList.contains('ember-basic-dropdown-content--left'), 'The dropdown is in the left');
@@ -1205,7 +1206,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
setTimeout(() => resolve(pets[2]), 40);
}));
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'Toby', 'The first element is highlighted');
assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing is selected yet');
diff --git a/tests/integration/components/power-select/groups-test.js b/tests/integration/components/power-select/groups-test.js
index 368a9be00..f8cf6908a 100644
--- a/tests/integration/components/power-select/groups-test.js
+++ b/tests/integration/components/power-select/groups-test.js
@@ -4,7 +4,8 @@ import { render } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
import { groupedNumbers } from '../constants';
-import { find, findAll, click } from 'ember-native-dom-helpers';
+import { click } from '@ember/test-helpers';
+import { find, findAll } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (Groups)', function(hooks) {
setupRenderingTest(hooks);
@@ -89,9 +90,9 @@ module('Integration | Component | Ember Power Select (Groups)', function(hooks)
{{option}}
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
let option = findAll('.ember-power-select-option').find((e) => e.textContent.indexOf('four') > -1);
- click(option);
+ await click(option);
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', 'The clicked option was selected');
assert.notOk(find('.ember-power-select-options'), 'The dropdown has dissapeared');
});
diff --git a/tests/integration/components/power-select/keyboard-control-test.js b/tests/integration/components/power-select/keyboard-control-test.js
index 584509670..53c4166bc 100644
--- a/tests/integration/components/power-select/keyboard-control-test.js
+++ b/tests/integration/components/power-select/keyboard-control-test.js
@@ -4,7 +4,8 @@ import { render } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { triggerKeydown, clickTrigger, typeInSearch } from 'ember-power-select/test-support/helpers';
import { numbers, numerals, countries, countriesWithDisabled, groupedNumbers, groupedNumbersWithDisabled } from '../constants';
-import { find, keyEvent, focus } from 'ember-native-dom-helpers';
+import { triggerKeyEvent, focus } from '@ember/test-helpers';
+import { find } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (Keyboard control)', function(hooks) {
setupRenderingTest(hooks);
@@ -19,9 +20,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one');
- keyEvent('.ember-power-select-search-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'two', 'The next options is highlighted now');
});
@@ -35,9 +36,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'three');
- keyEvent('.ember-power-select-search-input', 'keydown', 38);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 38);
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'two', 'The previous options is highlighted now');
});
@@ -52,9 +53,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'twenty');
- keyEvent('.ember-power-select-search-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'twenty', 'The last option is still the highlighted one');
});
@@ -69,9 +70,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one');
- keyEvent('.ember-power-select-search-input', 'keydown', 38);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 38);
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first option is still the highlighted one');
});
@@ -85,10 +86,10 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'seven');
assert.equal(find('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
- keyEvent('.ember-power-select-search-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'eight', 'The next option is highlighted now');
assert.ok(find('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
});
@@ -109,9 +110,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
- keyEvent('.ember-power-select-search-input', 'keydown', 40);
- keyEvent('.ember-power-select-search-input', 'keydown', 13);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'two', 'The highlighted element was selected');
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigger is focused');
@@ -133,9 +134,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
- keyEvent('.ember-power-select-trigger', 'keydown', 40);
- keyEvent('.ember-power-select-trigger', 'keydown', 13);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'two', 'The highlighted element was selected');
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigger is focused');
@@ -154,11 +155,11 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('asjdnah');
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'two', 'Two is selected');
assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found');
- keyEvent('.ember-power-select-search-input', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigger is focused');
});
@@ -180,9 +181,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
- keyEvent('.ember-power-select-trigger', 'keydown', 40);
- keyEvent('.ember-power-select-trigger', 'keydown', 32); // Space
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 32); // Space
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'two', 'The highlighted element was selected');
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigger is focused');
@@ -198,9 +199,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
- keyEvent('.ember-power-select-search-input', 'keydown', 40);
- keyEvent('.ember-power-select-search-input', 'keydown', 9);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 9);
assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'The highlighted element wasn\'t selected');
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigges is focused');
@@ -230,9 +231,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
focus('.ember-power-select-trigger');
assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
- keyEvent('.ember-power-select-trigger', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
- keyEvent('.ember-power-select-trigger', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed again');
});
@@ -248,9 +249,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
focus('.ember-power-select-trigger');
assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
- keyEvent('.ember-power-select-trigger', 'keydown', 32);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 32);
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
- keyEvent('.ember-power-select-trigger', 'keydown', 32);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 32);
assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed again');
});
@@ -266,7 +267,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
focus('.ember-power-select-trigger');
assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
- keyEvent('.ember-power-select-trigger', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
});
@@ -282,7 +283,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
focus('.ember-power-select-trigger');
assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
- keyEvent('.ember-power-select-trigger', 'keydown', 38);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 38);
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
});
@@ -296,9 +297,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
- keyEvent('.ember-power-select-trigger', 'keydown', 27);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 27);
assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The select is focused');
});
@@ -324,9 +325,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
- keyEvent('.ember-power-select-search-input', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
});
@@ -351,9 +352,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
- keyEvent('.ember-power-select-search-input', 'keydown', 32);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 32);
assert.ok(find('.ember-power-select-dropdown'), 'The select is still opened');
assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing was selected');
});
@@ -379,9 +380,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 32);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 32);
assert.ok(find('.ember-power-select-dropdown'), 'The select is still opened');
assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing was selected');
});
@@ -401,9 +402,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
- keyEvent('.ember-power-select-search-input', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
assert.ok(find('.ember-power-select-dropdown'), 'The select is still opened');
});
@@ -428,9 +429,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
});
@@ -447,9 +448,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
assert.ok(find('.ember-power-select-dropdown'), 'The select is still opened');
});
@@ -464,11 +465,11 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
let trigger = find('.ember-power-select-trigger');
- focus(trigger);
+ await focus(trigger);
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- keyEvent(trigger, 'keydown', 78); // n
- keyEvent(trigger, 'keydown', 73); // i
- keyEvent(trigger, 'keydown', 78); // n
+ triggerKeyEvent(trigger, 'keydown', 78); // n
+ triggerKeyEvent(trigger, 'keydown', 73); // i
+ await triggerKeyEvent(trigger, 'keydown', 78); // n
assert.equal(trigger.textContent.trim(), 'nine', '"nine" has been selected');
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
});
@@ -486,7 +487,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
let trigger = find('.ember-power-select-trigger');
focus(trigger);
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- keyEvent(trigger, 'keydown', 82, { ctrlKey: true }); // r
+ await triggerKeyEvent(trigger, 'keydown', 82, { ctrlKey: true }); // r
assert.notEqual(trigger.textContent.trim(), 'three', '"three" is not selected');
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
});
@@ -509,7 +510,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
let trigger = find('.ember-power-select-trigger');
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
assert.equal(find('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
triggerKeydown(trigger, 78); // n
@@ -532,7 +533,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
let trigger = find('.ember-power-select-trigger');
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
assert.equal(find('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
triggerKeydown(trigger, 104); // Numpad 8
@@ -553,7 +554,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
let trigger = find('.ember-power-select-trigger');
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
assert.equal(find('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
triggerKeydown(trigger, 78); // n
@@ -624,7 +625,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
let trigger = find('.ember-power-select-trigger');
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
triggerKeydown(trigger, 80); // p
triggerKeydown(trigger, 79); // o
@@ -644,7 +645,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
let trigger = find('.ember-power-select-trigger');
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
triggerKeydown(trigger, 69); // e
triggerKeydown(trigger, 76); // l
@@ -665,7 +666,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
let trigger = find('.ember-power-select-trigger');
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
triggerKeydown(trigger, 85); // u
assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
@@ -684,7 +685,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
let trigger = find('.ember-power-select-trigger');
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
triggerKeydown(trigger, 84); // t
triggerKeydown(trigger, 87); // w
@@ -710,9 +711,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- keyEvent('.ember-power-select-trigger', 'keydown', 40);
- clickTrigger();
- keyEvent('.ember-power-select-trigger', 'keydown', 38);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 38);
setTimeout(function() {
assert.ok(events[0].defaultPrevented, 'The first event was default prevented');
@@ -739,9 +740,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- keyEvent('.ember-power-select-trigger', 'keydown', 40);
- clickTrigger();
- keyEvent('.ember-power-select-trigger', 'keydown', 38);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 38);
setTimeout(function() {
assert.ok(!events[0].defaultPrevented, 'The first event was default prevented');
@@ -767,9 +768,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select-multiple}}
`);
- keyEvent('.ember-power-select-trigger', 'keydown', 40);
- clickTrigger();
- keyEvent('.ember-power-select-trigger', 'keydown', 38);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 38);
setTimeout(function() {
assert.ok(events[0].defaultPrevented, 'The first event was default prevented');
@@ -796,9 +797,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select-multiple}}
`);
- keyEvent('.ember-power-select-trigger', 'keydown', 40);
- clickTrigger();
- keyEvent('.ember-power-select-trigger', 'keydown', 38);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 38);
setTimeout(function() {
assert.ok(!events[0].defaultPrevented, 'The first event was default prevented');
diff --git a/yarn.lock b/yarn.lock
index 7bca8a3a4..bd0b2dfe2 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -6033,6 +6033,13 @@ quick-temp@^0.1.0, quick-temp@^0.1.2, quick-temp@^0.1.3, quick-temp@^0.1.5, quic
rimraf "^2.5.4"
underscore.string "~3.3.4"
+qunit-dom@^0.6.2:
+ version "0.6.2"
+ resolved "https://registry.yarnpkg.com/qunit-dom/-/qunit-dom-0.6.2.tgz#0b37012cbbc838f09eba760b3d39924ad5ccbccb"
+ dependencies:
+ broccoli-funnel "^2.0.0"
+ broccoli-merge-trees "^2.0.0"
+
qunit@^2.5.0:
version "2.6.0"
resolved "https://registry.yarnpkg.com/qunit/-/qunit-2.6.0.tgz#347b34686e2aa67a9f81f81d39f0771603ed628c"
From 0327ffc8706bf8e5ff03a9b4330274dde8fb42f1 Mon Sep 17 00:00:00 2001
From: Miguel Camba
Date: Mon, 16 Apr 2018 00:34:42 +0200
Subject: [PATCH 10/34] Modernize test suite part 2 (#1090)
---
.../power-select/ember-data-test.js | 34 ++--
.../power-select/touch-control-test.js | 27 ++-
.../power-select/type-ahead-test.js | 179 +++++++++---------
3 files changed, 115 insertions(+), 125 deletions(-)
diff --git a/tests/integration/components/power-select/ember-data-test.js b/tests/integration/components/power-select/ember-data-test.js
index 1a45891c5..bb5ee63fe 100644
--- a/tests/integration/components/power-select/ember-data-test.js
+++ b/tests/integration/components/power-select/ember-data-test.js
@@ -4,7 +4,7 @@ import { render, settled } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
import emberDataInitializer from '../../../../initializers/ember-data';
-import { find, findAll, click } from 'ember-native-dom-helpers';
+import { click } from '@ember/test-helpers';
import setupMirage from 'ember-cli-mirage/test-support/setup-mirage';
module('Integration | Component | Ember Power Select (Ember-data integration)', function(hooks) {
@@ -29,13 +29,11 @@ module('Integration | Component | Ember Power Select (Ember-data integration)',
this.set('users', this.store.findAll('user'));
clickTrigger();
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'Loading options...', 'The loading message appears while the promise is pending');
-
- return settled().then(function() {
- assert.equal(findAll('.ember-power-select-option').length, 10, 'Once the collection resolves the options render normally');
- typeInSearch('2');
- assert.equal(findAll('.ember-power-select-option').length, 1, 'Filtering works');
- });
+ assert.dom('.ember-power-select-option').hasText('Loading options...', 'The loading message appears while the promise is pending');
+ await settled();
+ assert.dom('.ember-power-select-option').exists({ count: 10 }, 'Once the collection resolves the options render normally');
+ typeInSearch('2');
+ assert.dom('.ember-power-select-option').exists({ count: 1 }, 'Filtering works');
});
test('Passing as options the result of `store.query` works', async function(assert) {
@@ -50,13 +48,12 @@ module('Integration | Component | Ember Power Select (Ember-data integration)',
this.set('users', this.store.query('user', { foo: 'bar' }));
clickTrigger();
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'Loading options...', 'The loading message appears while the promise is pending');
+ assert.dom('.ember-power-select-option').hasText('Loading options...', 'The loading message appears while the promise is pending')
+ await settled();
- return settled().then(function() {
- assert.equal(findAll('.ember-power-select-option').length, 10, 'Once the collection resolves the options render normally');
- typeInSearch('2');
- assert.equal(findAll('.ember-power-select-option').length, 1, 'Filtering works');
- });
+ assert.dom('.ember-power-select-option').exists({ count: 10 }, 'Once the collection resolves the options render normally');
+ typeInSearch('2');
+ assert.dom('.ember-power-select-option').exists({ count: 1 }, 'Filtering works');
});
test('Delete an item in a multiple selection', async function(assert) {
@@ -69,11 +66,8 @@ module('Integration | Component | Ember Power Select (Ember-data integration)',
`);
this.set('users', this.store.findAll('user'));
- return settled().then(function() {
- click('.ember-power-select-multiple-remove-btn');
- return settled().then(function() {
- assert.equal(findAll('.ember-power-select-multiple-remove-btn').length, 9, 'Once the collection resolves the options render normally');
- });
- });
+ await settled()
+ await click('.ember-power-select-multiple-remove-btn');
+ assert.dom('.ember-power-select-multiple-remove-btn').exists({ count: 9 }, 'Once the collection resolves the options render normally');
});
});
diff --git a/tests/integration/components/power-select/touch-control-test.js b/tests/integration/components/power-select/touch-control-test.js
index 55a561881..82f1189af 100644
--- a/tests/integration/components/power-select/touch-control-test.js
+++ b/tests/integration/components/power-select/touch-control-test.js
@@ -2,9 +2,8 @@ import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
import { render } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
-import { touchTrigger } from 'ember-power-select/test-support/helpers';
import { numbers } from '../constants';
-import { find, findAll, tap } from 'ember-native-dom-helpers';
+import { tap } from '@ember/test-helpers';
module('Integration | Component | Ember Power Select (Touch control)', function(hooks) {
setupRenderingTest(hooks);
@@ -19,8 +18,8 @@ module('Integration | Component | Ember Power Select (Touch control)', function(
{{/power-select}}
`);
- touchTrigger();
- assert.ok(find('.ember-power-select-options'), 'The dropdown is shown');
+ await tap('.ember-power-select-trigger');
+ assert.dom('.ember-power-select-options').exists('The dropdown is shown');
});
test('Touch on option should select it', async function(assert) {
@@ -33,11 +32,9 @@ module('Integration | Component | Ember Power Select (Touch control)', function(
{{/power-select}}
`);
- touchTrigger();
-
- tap(findAll('.ember-power-select-option')[3]);
-
- assert.equal(find('.ember-power-select-selected-item').textContent.trim(), 'four');
+ await tap('.ember-power-select-trigger');
+ await tap(document.querySelectorAll('.ember-power-select-option')[3]);
+ assert.dom('.ember-power-select-selected-item').hasText('four');
});
test('Touch on custom option should select it', async function(assert) {
@@ -50,10 +47,9 @@ module('Integration | Component | Ember Power Select (Touch control)', function(
{{/power-select}}
`);
- touchTrigger();
- tap(findAll('.super-fancy')[3]);
-
- assert.equal(find('.ember-power-select-selected-item').textContent.trim(), 'four');
+ await tap('.ember-power-select-trigger');
+ await tap(document.querySelectorAll('.super-fancy')[3]);
+ assert.dom('.ember-power-select-selected-item').hasText('four');
});
test('Touch on clear button should deselect it', async function(assert) {
@@ -67,8 +63,7 @@ module('Integration | Component | Ember Power Select (Touch control)', function(
{{/power-select}}
`);
- tap('.ember-power-select-clear-btn');
-
- assert.notOk(find('.ember-power-select-selected-item'), '');
+ await tap('.ember-power-select-clear-btn');
+ assert.dom('.ember-power-select-selected-item').doesNotExist();
});
});
diff --git a/tests/integration/components/power-select/type-ahead-test.js b/tests/integration/components/power-select/type-ahead-test.js
index dd8ae175f..fa925a0ea 100644
--- a/tests/integration/components/power-select/type-ahead-test.js
+++ b/tests/integration/components/power-select/type-ahead-test.js
@@ -1,21 +1,22 @@
-import { moduleForComponent, test } from 'ember-qunit';
+import { module, test } from 'qunit';
+import { setupRenderingTest } from 'ember-qunit';
import hbs from 'htmlbars-inline-precompile';
import { optionAtIndex } from 'ember-power-select/utils/group-utils';
import { triggerKeydown, clickTrigger } from 'ember-power-select/test-support/helpers';
import { charCode, namesStartingWithA } from '../constants';
-import { find, focus } from 'ember-native-dom-helpers';
+import { render, focus } from '@ember/test-helpers';
const WITH_EPS_CLOSED = {
beforeInteraction(trigger, assert) {
focus(trigger);
- assert.equal(trigger.textContent.trim(), '', 'no value selected');
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
+ assert.dom(trigger).hasText('', 'no value selected');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
},
checkSelectedValue(value, trigger, assert) {
// -1 adjust the position for the implicit placeholder
- assert.equal(trigger.textContent.trim(), value);
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
+ assert.dom(trigger).hasText(value);
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is still closed');
},
valueAt(coll, _idx, isGrouped = false) {
@@ -27,13 +28,13 @@ const WITH_EPS_CLOSED = {
const WITH_EPS_OPEN = {
beforeInteraction(trigger, assert) {
clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
+ assert.dom('.ember-power-select-dropdown').exists('The dropdown is open');
},
checkSelectedValue(value, trigger, assert) {
- assert.equal(trigger.textContent.trim(), '', 'nothing is selected');
- assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), value);
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is still open');
+ assert.dom(trigger).hasText('', 'nothing is selected');
+ assert.dom('.ember-power-select-option[aria-current=true]').hasText(value);
+ assert.dom('.ember-power-select-dropdown').exists('The dropdown is still open');
},
valueAt(coll, _idx, isGrouped = false) {
@@ -50,90 +51,90 @@ function typeString(trigger, str, times = 1) {
}
}
-moduleForComponent('ember-power-select', 'Integration | Component | Ember Power Select (Type Ahead Native Behaviour)', {
- integration: true
-});
-
-[['Closed', WITH_EPS_CLOSED], ['Open', WITH_EPS_OPEN]].forEach(([state, helpers]) => {
- test(`(${state}) Repeating the first character cycles through the results`, function(assert) {
- this.names = namesStartingWithA;
- this.render(hbs`
- {{#power-select options=names onchange=(action (mut selected)) selected=selected searchEnabled=false as |option|}}
- {{option}}
- {{/power-select}}
- `);
-
- let trigger = find('.ember-power-select-trigger');
- helpers.beforeInteraction(trigger, assert);
- typeString(trigger, 'aaa');
- helpers.checkSelectedValue(helpers.valueAt(this.names, 'aaa'.length), trigger, assert);
- });
-
- test(`(${state}) When going over all the possible results, it goes back to the first`, function(assert) {
- this.names = namesStartingWithA;
- this.render(hbs`
- {{#power-select options=names onchange=(action (mut selected)) selected=selected searchEnabled=false as |option|}}
- {{option}}
- {{/power-select}}
- `);
-
- let trigger = find('.ember-power-select-trigger');
- helpers.beforeInteraction(trigger, assert);
- let { length } = namesStartingWithA;
- typeString(trigger, 'a', length + 1);
- helpers.checkSelectedValue(helpers.valueAt(this.names, length + 1), trigger, assert);
- });
+module('Integration | Component | Ember Power Select (Type Ahead Native Behaviour)', function(hooks) {
+ setupRenderingTest(hooks);
- test(`(${state}) Though repeating the first char, the whole search term is remembered`, function(assert) {
- this.names = namesStartingWithA;
- this.render(hbs`
+ [['Closed', WITH_EPS_CLOSED], ['Open', WITH_EPS_OPEN]].forEach(([state, helpers]) => {
+ test(`(${state}) Repeating the first character cycles through the results`, async function(assert) {
+ this.names = namesStartingWithA;
+ await render(hbs`
{{#power-select options=names onchange=(action (mut selected)) selected=selected searchEnabled=false as |option|}}
{{option}}
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
- helpers.beforeInteraction(trigger, assert);
- typeString(trigger, 'aa');
- helpers.checkSelectedValue(helpers.valueAt(this.names, 'aa'.length), trigger, assert);
- typeString(trigger, 'r');
- helpers.checkSelectedValue('Aaran', trigger, assert);
- assert.notEqual('Aaran', helpers.valueAt(this.names, 'aar'.length), 'Aaran would not be selected unless aa was remembered');
- });
-
- test(`(${state}) Typing the first character after typing a different one does not set again the cycling behaviour`, function(assert) {
- this.names = namesStartingWithA;
- this.render(hbs`
- {{#power-select options=names onchange=(action (mut selected)) selected=selected searchEnabled=false as |option|}}
- {{option}}
- {{/power-select}}
- `);
-
- let trigger = find('.ember-power-select-trigger');
- helpers.beforeInteraction(trigger, assert);
- typeString(trigger, 'aara');
- helpers.checkSelectedValue('Aaran', trigger, assert);
- });
-
- test(`(${state}) Cycling characters works with grouped items`, function(assert) {
- this.names = [
- { groupName: 'First', options: ['Faa', 'Fab', 'Fac'] },
- { groupName: 'Second', options: ['Fba', { groupName: '2.1', options: ['FFba'] }, 'Fbb'] }
- ];
- this.render(hbs`
- {{#power-select options=names onchange=(action (mut selected)) selected=selected searchEnabled=false as |option|}}
- {{option}}
- {{/power-select}}
- `);
- let trigger = find('.ember-power-select-trigger');
- helpers.beforeInteraction(trigger, assert);
- typeString(trigger, 'f', state === 'Open' ? 1 : 2); // Normalize open closed behaviour
- helpers.checkSelectedValue('Fab', trigger, assert);
- typeString(trigger, 'f', 2);
- helpers.checkSelectedValue('Fba', trigger, assert);
- typeString(trigger, 'f');
- helpers.checkSelectedValue('FFba', trigger, assert);
- typeString(trigger, 'f');
- helpers.checkSelectedValue('Fbb', trigger, assert);
+ let trigger = this.element.querySelector('.ember-power-select-trigger');
+ helpers.beforeInteraction(trigger, assert);
+ typeString(trigger, 'aaa');
+ helpers.checkSelectedValue(helpers.valueAt(this.names, 'aaa'.length), trigger, assert);
+ });
+
+ test(`(${state}) When going over all the possible results, it goes back to the first`, async function(assert) {
+ this.names = namesStartingWithA;
+ await render(hbs`
+ {{#power-select options=names onchange=(action (mut selected)) selected=selected searchEnabled=false as |option|}}
+ {{option}}
+ {{/power-select}}
+ `);
+
+ let trigger = this.element.querySelector('.ember-power-select-trigger');
+ helpers.beforeInteraction(trigger, assert);
+ let { length } = namesStartingWithA;
+ typeString(trigger, 'a', length + 1);
+ helpers.checkSelectedValue(helpers.valueAt(this.names, length + 1), trigger, assert);
+ });
+
+ test(`(${state}) Though repeating the first char, the whole search term is remembered`, async function(assert) {
+ this.names = namesStartingWithA;
+ await render(hbs`
+ {{#power-select options=names onchange=(action (mut selected)) selected=selected searchEnabled=false as |option|}}
+ {{option}}
+ {{/power-select}}
+ `);
+
+ let trigger = this.element.querySelector('.ember-power-select-trigger');
+ helpers.beforeInteraction(trigger, assert);
+ typeString(trigger, 'aa');
+ helpers.checkSelectedValue(helpers.valueAt(this.names, 'aa'.length), trigger, assert);
+ typeString(trigger, 'r');
+ helpers.checkSelectedValue('Aaran', trigger, assert);
+ assert.notEqual('Aaran', helpers.valueAt(this.names, 'aar'.length), 'Aaran would not be selected unless aa was remembered');
+ });
+
+ test(`(${state}) Typing the first character after typing a different one does not set again the cycling behaviour`, async function(assert) {
+ this.names = namesStartingWithA;
+ await render(hbs`
+ {{#power-select options=names onchange=(action (mut selected)) selected=selected searchEnabled=false as |option|}}
+ {{option}}
+ {{/power-select}}
+ `);
+
+ let trigger = this.element.querySelector('.ember-power-select-trigger');
+ helpers.beforeInteraction(trigger, assert);
+ typeString(trigger, 'aara');
+ helpers.checkSelectedValue('Aaran', trigger, assert);
+ });
+
+ test(`(${state}) Cycling characters works with grouped items`, async function(assert) {
+ this.names = [
+ { groupName: 'First', options: ['Faa', 'Fab', 'Fac'] },
+ { groupName: 'Second', options: ['Fba', { groupName: '2.1', options: ['FFba'] }, 'Fbb'] }
+ ];
+ await render(hbs`
+ {{#power-select options=names onchange=(action (mut selected)) selected=selected searchEnabled=false as |option|}}
+ {{option}}
+ {{/power-select}}
+ `);
+ let trigger = this.element.querySelector('.ember-power-select-trigger');
+ helpers.beforeInteraction(trigger, assert);
+ typeString(trigger, 'f', state === 'Open' ? 1 : 2); // Normalize open closed behaviour
+ helpers.checkSelectedValue('Fab', trigger, assert);
+ typeString(trigger, 'f', 2);
+ helpers.checkSelectedValue('Fba', trigger, assert);
+ typeString(trigger, 'f');
+ helpers.checkSelectedValue('FFba', trigger, assert);
+ typeString(trigger, 'f');
+ helpers.checkSelectedValue('Fbb', trigger, assert);
+ });
});
});
From 14b5b6794c0230a3d68650ee845a0f49af63d1c7 Mon Sep 17 00:00:00 2001
From: Miguel Camba
Date: Mon, 16 Apr 2018 10:13:15 +0200
Subject: [PATCH 11/34] Modernize test suite part 3 (#1091)
---
tests/.eslintrc.js | 1 -
.../components/power-select/disabled-test.js | 82 +++++++++----------
.../power-select/general-behaviour-test.js | 2 +-
.../components/power-select/helpers-test.js | 11 ++-
.../power-select/opened-property-test.js | 3 +-
5 files changed, 46 insertions(+), 53 deletions(-)
diff --git a/tests/.eslintrc.js b/tests/.eslintrc.js
index 82e3adf3d..47652b8bf 100644
--- a/tests/.eslintrc.js
+++ b/tests/.eslintrc.js
@@ -1,6 +1,5 @@
module.exports = {
globals: {
- server: true,
selectChoose: true,
selectSearch: true,
removeMultipleOption: true,
diff --git a/tests/integration/components/power-select/disabled-test.js b/tests/integration/components/power-select/disabled-test.js
index 0d5cb7ee7..bfe242e8d 100644
--- a/tests/integration/components/power-select/disabled-test.js
+++ b/tests/integration/components/power-select/disabled-test.js
@@ -6,7 +6,6 @@ import { run } from '@ember/runloop';
import { clickTrigger, typeInSearch } from 'ember-power-select/test-support/helpers';
import { numbers, countriesWithDisabled } from '../constants';
import { triggerEvent, triggerKeyEvent, click, focus } from '@ember/test-helpers';
-import { find, findAll } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (Disabled)', function(hooks) {
setupRenderingTest(hooks);
@@ -21,15 +20,14 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
- assert.ok(trigger.attributes['aria-disabled'].value, 'true', 'The trigger has `aria-disabled=true`');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-disabled', 'true');
await clickTrigger();
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is still closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is still closed');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is still closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is still closed');
});
- test('A disabled dropdown is not focusable, and ignores the passed tabindex ', async function(assert) {
+ test('A disabled dropdown is not focusable, and ignores the passed tabindex', async function(assert) {
assert.expect(1);
this.numbers = numbers;
@@ -38,7 +36,7 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{option}}
{{/power-select}}
`);
- assert.equal(find('.ember-power-select-trigger').attributes.tabindex, undefined, 'The trigger has no tabindex so it can\'t be focused');
+ assert.dom('.ember-power-select-trigger').doesNotHaveAttribute('tabindex', 'The trigger has no tabindex so it can\'t be focused');
});
test('Disabled options are not highlighted when hovered with the mouse', async function(assert) {
@@ -53,7 +51,7 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
await clickTrigger();
await triggerEvent('.ember-power-select-option[aria-disabled="true"]', 'mouseover');
- assert.equal(find('.ember-power-select-option[aria-disabled="true"]').attributes['aria-current'].value, 'false', 'The hovered option was not highlighted because it\'s disabled');
+ assert.dom('.ember-power-select-option[aria-disabled="true"]').hasAttribute('aria-current', 'false', 'The hovered option was not highlighted because it\'s disabled');
});
test('Disabled options are skipped when highlighting items with the keyboard', async function(assert) {
@@ -69,7 +67,7 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
await clickTrigger();
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'LV: Latvia', 'The hovered option was not highlighted because it\'s disabled');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('LV: Latvia', 'The hovered option was not highlighted because it\'s disabled');
});
test('When passed `disabled=true`, the input inside the trigger is also disabled', async function(assert) {
@@ -82,7 +80,7 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select-multiple}}
`);
- assert.ok(find('.ember-power-select-trigger-multiple-input').disabled, 'The input is disabled');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('disabled');
});
test('When passed `disabled=true`, the options cannot be removed', async function(assert) {
@@ -97,7 +95,7 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select-multiple}}
`);
- assert.equal(findAll('.ember-power-select-multiple-remove-btn').length, 0, 'There is no button to remove selected elements');
+ assert.dom('.ember-power-select-multiple-remove-btn').doesNotExist('There is no button to remove selected elements');
});
test('Multiple select: When passed `disabled=prop`, enabling and disabling that property changes the component', async function(assert) {
@@ -113,11 +111,10 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select-multiple}}
`);
- let trigger = find('.ember-power-select-trigger');
- assert.equal(trigger.attributes['aria-disabled'].value, 'true', 'The trigger has `aria-disabled=true`');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-disabled', 'true', 'The trigger has `aria-disabled=true`');
this.set('shouldBeDisabled', false);
- assert.notOk(trigger.attributes['aria-expanded']);
- assert.notOk(find('.ember-power-select-trigger-multiple-input').disabled, 'The input is not disabled');
+ assert.dom('.ember-power-select-trigger').doesNotHaveAttribute('aria-expanded')
+ assert.dom('.ember-power-select-trigger-multiple-input').doesNotHaveAttribute('disabled');
});
test('BUGFIX: When after a search the only result is a disabled element, it isn\'t highlighted and cannot be selected', async function(assert) {
@@ -132,10 +129,10 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
await clickTrigger();
typeInSearch('Br');
- assert.notOk(find('.ember-power-select-option[aria-current="true"]'), 'Nothing is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').doesNotExist('Nothing is highlighted');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing was selected');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
+ assert.dom('.ember-power-select-trigger').hasText('', 'Nothing was selected');
});
test('BUGFIX: When after a search there is two results and the first one is a disabled element, the second one is highlighted', async function(assert) {
@@ -150,10 +147,10 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
await clickTrigger();
typeInSearch('o'); // Finds ["Portugal", "United Kingdom"]
- assert.equal(findAll('.ember-power-select-option').length, 2, 'There is two results');
- assert.equal(findAll('.ember-power-select-option[aria-disabled="true"]').length, 1, 'One is disabled');
- assert.equal(findAll('.ember-power-select-option[aria-current="true"]').length, 1, 'One element is highlighted');
- assert.equal(findAll('.ember-power-select-option[aria-current="true"]')[0].textContent.trim(), 'United Kingdom', 'The first non-disabled element is highlighted');
+ assert.dom('.ember-power-select-option').exists({ count: 2 }, 'There is two results');
+ assert.dom('.ember-power-select-option[aria-disabled="true"]').exists({ count: 1 }, 'One is disabled');
+ assert.dom('.ember-power-select-option[aria-current="true"]').exists({ count: 1 }, 'One element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('United Kingdom', 'The first non-disabled element is highlighted');
});
test('BUGFIX: When searching by pressing keys on a focused & closed select, disabled options are ignored', async function(assert) {
@@ -167,12 +164,11 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
- await focus(trigger);
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- await triggerKeyEvent(trigger, 'keydown', 85); // u
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
- assert.equal(trigger.textContent.trim(), 'United Kingdom', '"United Kingdom" has been selected');
+ await focus('.ember-power-select-trigger');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 85); // u
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is still closed');
+ assert.dom('.ember-power-select-trigger').hasText('United Kingdom', '"United Kingdom" has been selected');
});
test('The title of a group can be marked as disabled, and it is still disabled after filtering', async function(assert) {
@@ -201,9 +197,9 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
`);
await clickTrigger();
- assert.equal(findAll('.ember-power-select-group[aria-disabled="true"]').length, 1, 'one group is disabled');
+ assert.dom('.ember-power-select-group[aria-disabled="true"]').exists({ count: 1 }, 'one group is disabled');
typeInSearch('fiv');
- assert.equal(findAll('.ember-power-select-group[aria-disabled="true"]').length, 1, 'one group is still disabled');
+ assert.dom('.ember-power-select-group[aria-disabled="true"]').exists({ count: 1 }, 'one group is still disabled');
});
test('If a group is disabled, any options inside cannot be interacted with mouse', async function(assert) {
@@ -233,12 +229,12 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one');
- assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'No option is selected');
- await triggerEvent(findAll('.ember-power-select-option')[8], 'mouseover');
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one');
- await click(findAll('.ember-power-select-option')[9]);
- assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'Noting was selected');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').doesNotExist('No option is selected');
+ await triggerEvent(document.querySelectorAll('.ember-power-select-option')[8], 'mouseover');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one');
+ await click(document.querySelectorAll('.ember-power-select-option')[9]);
+ assert.dom('.ember-power-select-option[aria-selected="true"]').doesNotExist('Noting was selected');
});
test('If the value of `disabled` changes, the `disabled` property in the publicAPI matches it', async function(assert) {
@@ -253,9 +249,9 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
{{/power-select}}
`);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'enabled!', 'The `disabled` attribute in the public API is false');
+ assert.dom('.ember-power-select-trigger').hasText('enabled!', 'The `disabled` attribute in the public API is false');
run(() => this.set('isDisabled', true));
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'disabled!', 'The `disabled` attribute in the public API is true');
+ assert.dom('.ember-power-select-trigger').hasText('disabled!', 'The `disabled` attribute in the public API is true');
});
test('If a select gets disabled while it\'s open, it closes automatically', async function(assert) {
@@ -270,9 +266,9 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The select is open');
+ assert.dom('.ember-power-select-dropdown').exists('The select is open');
run(() => this.set('isDisabled', true));
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is now closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is now closed');
});
test('BUGFIX: A component can be disabled on selection', async function(assert) {
@@ -286,8 +282,8 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
`);
await clickTrigger();
- await click(findAll('.ember-power-select-option')[1]);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'two', 'The option is selected');
- assert.equal(find('.ember-power-select-trigger').attributes['aria-disabled'].value, 'true');
+ await click(document.querySelectorAll('.ember-power-select-option')[1]);
+ assert.dom('.ember-power-select-trigger').hasText('two', 'The option is selected');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-disabled', 'true');
});
});
diff --git a/tests/integration/components/power-select/general-behaviour-test.js b/tests/integration/components/power-select/general-behaviour-test.js
index 79748e67e..ca5857265 100644
--- a/tests/integration/components/power-select/general-behaviour-test.js
+++ b/tests/integration/components/power-select/general-behaviour-test.js
@@ -1203,7 +1203,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
this.set('mainUser.bestie', new RSVP.Promise(function(resolve) {
- setTimeout(() => resolve(pets[2]), 40);
+ setTimeout(() => resolve(pets[2]), 90);
}));
await clickTrigger();
diff --git a/tests/integration/components/power-select/helpers-test.js b/tests/integration/components/power-select/helpers-test.js
index 75249dffa..9c58aa7cb 100644
--- a/tests/integration/components/power-select/helpers-test.js
+++ b/tests/integration/components/power-select/helpers-test.js
@@ -4,7 +4,6 @@ import { render } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { selectChoose } from 'ember-power-select/test-support/helpers';
import { numbers } from '../constants';
-import { find, findAll } from 'ember-native-dom-helpers';
module('Integration | Helpers | selectChoose', function(hooks) {
setupRenderingTest(hooks);
@@ -19,9 +18,9 @@ module('Integration | Helpers | selectChoose', function(hooks) {
{{/power-select}}
`);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'The select is empty');
+ assert.dom('.ember-power-select-trigger').hasText('', 'The select is empty');
await selectChoose('.ember-power-select-trigger', 'three');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'three', 'The values has been selected');
+ assert.dom('.ember-power-select-trigger').hasText('three', 'The values has been selected');
});
test('selectChoose selects the given value on multiple selects', async function(assert) {
@@ -34,10 +33,10 @@ module('Integration | Helpers | selectChoose', function(hooks) {
{{/power-select-multiple}}
`);
- assert.equal(findAll('.ember-power-select-multiple-option ').length, 0, 'There is no selected options');
+ assert.dom('.ember-power-select-multiple-option').doesNotExist('There is no selected options');
await selectChoose('.ember-power-select-trigger', 'three');
- assert.equal(findAll('.ember-power-select-multiple-option ').length, 1, 'There is one selected option');
+ assert.dom('.ember-power-select-multiple-option ').exists({ count: 1 }, 'There is one selected option');
await selectChoose('.ember-power-select-trigger', 'five');
- assert.equal(findAll('.ember-power-select-multiple-option ').length, 2, 'There is one selected option');
+ assert.dom('.ember-power-select-multiple-option ').exists({ count: 2 }, 'There is one selected option');
});
});
diff --git a/tests/integration/components/power-select/opened-property-test.js b/tests/integration/components/power-select/opened-property-test.js
index 208a2e77a..00d7aebc2 100644
--- a/tests/integration/components/power-select/opened-property-test.js
+++ b/tests/integration/components/power-select/opened-property-test.js
@@ -3,7 +3,6 @@ import { setupRenderingTest } from 'ember-qunit';
import { render } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { numbers } from '../constants';
-import { find } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (The opened property)', function(hooks) {
setupRenderingTest(hooks);
@@ -18,6 +17,6 @@ module('Integration | Component | Ember Power Select (The opened property)', fun
{{/power-select}}
`);
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is opened');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is opened');
});
});
From c301ba88a030f3678c67e9cb50617023b898887e Mon Sep 17 00:00:00 2001
From: Miguel Camba
Date: Mon, 16 Apr 2018 15:32:21 +0200
Subject: [PATCH 12/34] Modernize test suite part 4 (#1092)
---
.../components/power-select/a11y-test.js | 127 ++++++++----------
.../power-select/custom-search-test.js | 3 +-
.../customization-with-components-test.js | 3 +-
.../components/power-select/disabled-test.js | 3 +-
.../power-select/ember-data-test.js | 3 +-
.../power-select/general-behaviour-test.js | 9 +-
.../components/power-select/groups-test.js | 3 +-
.../power-select/public-actions-test.js | 4 +-
.../power-select/touch-control-test.js | 3 +-
9 files changed, 65 insertions(+), 93 deletions(-)
diff --git a/tests/integration/components/power-select/a11y-test.js b/tests/integration/components/power-select/a11y-test.js
index 5dbe13168..f2ae0f551 100644
--- a/tests/integration/components/power-select/a11y-test.js
+++ b/tests/integration/components/power-select/a11y-test.js
@@ -1,11 +1,9 @@
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render } from '@ember/test-helpers';
+import { render, triggerKeyEvent } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { numbers, groupedNumbers, countriesWithDisabled } from '../constants';
import { clickTrigger, findContains } from 'ember-power-select/test-support/helpers';
-import { triggerKeyEvent } from '@ember/test-helpers';
-import { find, findAll } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (Accesibility)', function(hooks) {
setupRenderingTest(hooks);
@@ -21,10 +19,9 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- let rootLevelOptionsList = find('.ember-power-select-dropdown > .ember-power-select-options');
- assert.equal(rootLevelOptionsList.attributes.role.value, 'listbox', 'The top-level list has `role=listbox`');
- let nestedOptionList = findAll('.ember-power-select-options .ember-power-select-options');
- [].slice.call(nestedOptionList).forEach((e) => assert.equal(e.attributes.role.value, 'group'));
+ assert.dom('.ember-power-select-dropdown > .ember-power-select-options').hasAttribute('role', 'listbox', 'The top-level list has `role=listbox`');
+ let nestedOptionList = document.querySelectorAll('.ember-power-select-options .ember-power-select-options');
+ [].slice.call(nestedOptionList).forEach((e) => assert.dom(e).hasAttribute('role', 'group'));
});
test('Multiple-select: The top-level options list have `role=listbox` and nested lists have `role=group`', async function(assert) {
@@ -38,10 +35,9 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- let rootLevelOptionsList = find('.ember-power-select-dropdown > .ember-power-select-options');
- assert.equal(rootLevelOptionsList.attributes.role.value, 'listbox', 'The top-level list has `role=listbox`');
- let nestedOptionList = findAll('.ember-power-select-options .ember-power-select-options');
- [].slice.call(nestedOptionList).forEach((e) => assert.equal(e.attributes.role.value, 'group'));
+ assert.dom('.ember-power-select-dropdown > .ember-power-select-options').hasAttribute('role', 'listbox', 'The top-level list has `role=listbox`');
+ let nestedOptionList = document.querySelectorAll('.ember-power-select-options .ember-power-select-options');
+ [].slice.call(nestedOptionList).forEach((e) => assert.dom(e).hasAttribute('role', 'group'));
});
test('Single-select: All options have `role=option`', async function(assert) {
@@ -55,7 +51,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- [].slice.call(findAll('.ember-power-select-option')).forEach((e) => assert.equal(e.attributes.role.value, 'option'));
+ [].slice.call(document.querySelectorAll('.ember-power-select-option')).forEach((e) => assert.dom(e).hasAttribute('role', 'option'));
});
test('Multiple-select: All options have `role=option`', async function(assert) {
@@ -69,7 +65,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- [].slice.call(findAll('.ember-power-select-option')).forEach((e) => assert.equal(e.attributes.role.value, 'option'));
+ [].slice.call(document.querySelectorAll('.ember-power-select-option')).forEach((e) => assert.dom(e).hasAttribute('role', 'option'));
});
test('Single-select: The selected option has `aria-selected=true` and the rest `aria-selected=false`', async function(assert) {
@@ -84,8 +80,8 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- assert.equal(findContains('.ember-power-select-option', 'two').attributes['aria-selected'].value, 'true', 'the selected option has aria-selected=true');
- assert.equal(findAll('.ember-power-select-option[aria-selected="false"]').length, numbers.length - 1, 'All other options have aria-selected=false');
+ assert.dom(findContains('.ember-power-select-option', 'two')).hasAttribute('aria-selected', 'true', 'the selected option has aria-selected=true');
+ assert.dom('.ember-power-select-option[aria-selected="false"]').exists({ count: numbers.length - 1 }, 'All other options have aria-selected=false');
});
test('Multiple-select: The selected options have `aria-selected=true` and the rest `aria-selected=false`', async function(assert) {
@@ -100,9 +96,9 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- assert.equal(findContains('.ember-power-select-option', 'two').attributes['aria-selected'].value, 'true', 'the first selected option has aria-selected=true');
- assert.equal(findContains('.ember-power-select-option', 'four').attributes['aria-selected'].value, 'true', 'the second selected option has aria-selected=true');
- assert.equal(findAll('.ember-power-select-option[aria-selected="false"]').length, numbers.length - 2, 'All other options have aria-selected=false');
+ assert.dom(findContains('.ember-power-select-option', 'two')).hasAttribute('aria-selected', 'true', 'the first selected option has aria-selected=true');
+ assert.dom(findContains('.ember-power-select-option', 'four')).hasAttribute('aria-selected', 'true', 'the second selected option has aria-selected=true');
+ assert.dom('.ember-power-select-option[aria-selected="false"]').exists({ count: numbers.length - 2 }, 'All other options have aria-selected=false');
});
test('Single-select: The highlighted option has `aria-current=true` and the rest not have `aria-current`', async function(assert) {
@@ -116,11 +112,11 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- assert.equal(findContains('.ember-power-select-option', 'one').attributes['aria-current'].value, 'true', 'the highlighted option has aria-current=true');
- assert.equal(findAll('.ember-power-select-option[aria-current="false"]').length, numbers.length - 1, 'All other options have aria-current=false');
+ assert.dom(findContains('.ember-power-select-option', 'one')).hasAttribute('aria-current', 'true', 'the highlighted option has aria-current=true');
+ assert.dom('.ember-power-select-option[aria-current="false"]').exists({ count: numbers.length - 1 }, 'All other options have aria-current=false');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
- assert.equal(findContains('.ember-power-select-option', 'one').attributes['aria-current'].value, 'false', 'the first option has now aria-current=false');
- assert.equal(findContains('.ember-power-select-option', 'two').attributes['aria-current'].value, 'true', 'the second option has now aria-current=false');
+ assert.dom(findContains('.ember-power-select-option', 'one')).hasAttribute('aria-current', 'false', 'the first option has now aria-current=false');
+ assert.dom(findContains('.ember-power-select-option', 'two')).hasAttribute('aria-current', 'true', 'the second option has now aria-current=false');
});
test('Multiple-select: The highlighted option has `aria-current=true` and the rest `aria-current=false`', async function(assert) {
@@ -134,11 +130,11 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- assert.equal(findContains('.ember-power-select-option', 'one').attributes['aria-current'].value, 'true', 'the highlighted option has aria-current=true');
- assert.equal(findAll('.ember-power-select-option[aria-current="false"]').length, numbers.length - 1, 'All other options have aria-current=false');
+ assert.dom(findContains('.ember-power-select-option', 'one')).hasAttribute('aria-current', 'true', 'the highlighted option has aria-current=true');
+ assert.dom('.ember-power-select-option[aria-current="false"]').exists({ count: numbers.length - 1 }, 'All other options have aria-current=false');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
- assert.equal(findContains('.ember-power-select-option', 'one').attributes['aria-current'].value, 'false', 'the first option has now aria-current=false');
- assert.equal(findContains('.ember-power-select-option', 'two').attributes['aria-current'].value, 'true', 'the second option has now aria-current=false');
+ assert.dom(findContains('.ember-power-select-option', 'one')).hasAttribute('aria-current', 'false', 'the first option has now aria-current=false');
+ assert.dom(findContains('.ember-power-select-option', 'two')).hasAttribute('aria-current', 'true', 'the second option has now aria-current=false');
});
test('Single-select: Options with a disabled field have `aria-disabled=true`', async function(assert) {
@@ -152,7 +148,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- assert.equal(findAll('.ember-power-select-option[aria-disabled=true]').length, 3, 'Three of them are disabled');
+ assert.dom('.ember-power-select-option[aria-disabled=true]').exists({ count: 3 }, 'Three of them are disabled');
});
test('Multiple-select: Options with a disabled field have `aria-disabled=true`', async function(assert) {
@@ -166,7 +162,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- assert.equal(findAll('.ember-power-select-option[aria-disabled=true]').length, 3, 'Three of them are disabled');
+ assert.dom('.ember-power-select-option[aria-disabled=true]').exists({ count: 3 }, 'Three of them are disabled');
});
test('Single-select: The trigger has `role=button` and `aria-owns=`', async function(assert) {
@@ -180,9 +176,8 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- let trigger = find('.ember-power-select-trigger');
- assert.equal(trigger.attributes.role.value, 'button', 'The trigger has role button');
- assert.ok(/^ember-basic-dropdown-content-ember\d+$/.test(trigger.attributes['aria-owns'].value), 'aria-owns point to the dropdown');
+ assert.dom('.ember-power-select-trigger').hasAttribute('role', 'button', 'The trigger has role button');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-owns', /^ember-basic-dropdown-content-ember\d+$/, 'aria-owns points to the dropdown');
});
test('Multiple-select: The trigger has `role=button` and `aria-owns=`', async function(assert) {
@@ -196,9 +191,8 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- let trigger = find('.ember-power-select-trigger');
- assert.equal(trigger.attributes.role.value, 'button', 'The trigger has role button');
- assert.ok(/^ember-basic-dropdown-content-ember\d+$/.test(trigger.attributes['aria-owns'].value), 'aria-owns point to the dropdown');
+ assert.dom('.ember-power-select-trigger').hasAttribute('role', 'button', 'The trigger has role button');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-owns', /^ember-basic-dropdown-content-ember\d+$/, 'aria-owns points to the dropdown');
});
test('Single-select: The trigger attribute `aria-expanded` is true when the dropdown is opened', async function(assert) {
@@ -211,10 +205,9 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
- assert.notOk(trigger.attributes['aria-expanded'], 'Not expanded');
+ assert.dom('.ember-power-select-trigger').doesNotHaveAttribute('aria-expanded', 'Not expanded');
clickTrigger();
- assert.ok(trigger.attributes['aria-expanded'], 'Expanded');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-expanded', 'true', 'Expanded');
});
test('Multiple-select: The trigger attribute `aria-expanded` is true when the dropdown is opened', async function(assert) {
@@ -227,10 +220,9 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select-multiple}}
`);
- let trigger = find('.ember-power-select-trigger');
- assert.notOk(trigger.attributes['aria-expanded'], 'Not expanded');
+ assert.dom('.ember-power-select-trigger').doesNotHaveAttribute('aria-expanded', 'Not expanded');
clickTrigger();
- assert.ok(trigger.attributes['aria-expanded'], 'Expanded');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-expanded', 'true', 'Expanded');
});
test('Single-select: The listbox has a unique id`', async function(assert) {
@@ -244,7 +236,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- assert.ok(/^ember-power-select-options-ember\d+$/.test(find('.ember-power-select-options').id), 'The search has a unique id');
+ assert.dom('.ember-power-select-options').hasAttribute('id', /^ember-power-select-options-ember\d+$/, 'The search has a unique id');
});
test('Multiple-select: The listbox has a unique id`', async function(assert) {
@@ -258,7 +250,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- assert.ok(/^ember-power-select-options-ember\d+$/.test(find('.ember-power-select-options').id), 'The search has a unique id');
+ assert.dom('.ember-power-select-options').hasAttribute('id', /^ember-power-select-options-ember\d+$/, 'The search has a unique id');
});
test('Single-select: The searchbox has type `search` and `aria-controls=`', async function(assert) {
@@ -272,8 +264,8 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- assert.equal(find('.ember-power-select-search-input').type, 'search', 'The type of the input is `search`');
- assert.ok(/^ember-power-select-options-ember\d+$/.test(find('.ember-power-select-search-input').attributes['aria-controls'].value), 'The `aria-controls` points to the id of the listbox');
+ assert.dom('.ember-power-select-search-input').hasAttribute('type', 'search', 'The type of the input is `search`');
+ assert.dom('.ember-power-select-search-input').hasAttribute('aria-controls', /^ember-power-select-options-ember\d+$/, 'The `aria-controls` points to the id of the listbox');
});
test('Multiple-select: The searchbox has type `search` and `aria-controls=`', async function(assert) {
@@ -287,8 +279,8 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- assert.equal(find('.ember-power-select-trigger-multiple-input').type, 'search', 'The type of the input is `search`');
- assert.ok(/^ember-power-select-options-ember\d+$/.test(find('.ember-power-select-trigger-multiple-input').attributes['aria-controls'].value), 'The `aria-controls` points to the id of the listbox');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('type', 'search', 'The type of the input is `search`');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('aria-controls', /^ember-power-select-options-ember\d+$/, 'The `aria-controls` points to the id of the listbox');
});
test('Single-select: The listbox has `aria-controls=`', async function(assert) {
@@ -302,7 +294,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- assert.ok(/^ember-power-select-trigger-ember\d+$/.test(find('.ember-power-select-options').attributes['aria-controls'].value), 'The listbox controls the trigger');
+ assert.dom('.ember-power-select-options').hasAttribute('aria-controls', /^ember-power-select-trigger-ember\d+$/, 'The listbox controls the trigger');
});
test('Multiple-select: The listbox has `aria-controls=`', async function(assert) {
@@ -316,7 +308,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
clickTrigger();
- assert.ok(/^ember-power-select-trigger-ember\d+$/.test(find('.ember-power-select-options').attributes['aria-controls'].value), 'The listbox controls the trigger');
+ assert.dom('.ember-power-select-options').hasAttribute('aria-controls', /^ember-power-select-trigger-ember\d+$/, 'The listbox controls the trigger');
});
test('Multiple-select: The selected elements are
s inside an
, and have an item with `role=button` with `aria-label="remove element"`', async function(assert) {
@@ -330,12 +322,12 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select-multiple}}
`);
- [].slice.call(findAll('.ember-power-select-multiple-option')).forEach((e) => {
+ [].slice.call(document.querySelectorAll('.ember-power-select-multiple-option')).forEach((e) => {
assert.equal(e.tagName, 'LI', 'The element is a list item');
assert.equal(e.parentElement.tagName, 'UL', 'The parent element is a list');
let closeButton = e.querySelector('.ember-power-select-multiple-remove-btn');
- assert.equal(closeButton.attributes.role.value, 'button', 'The role of the close button is "button"');
- assert.equal(closeButton.attributes['aria-label'].value, 'remove element', 'The close button has a helpful aria label');
+ assert.dom(closeButton).hasAttribute('role', 'button', 'The role of the close button is "button"');
+ assert.dom(closeButton).hasAttribute('aria-label', 'remove element', 'The close button has a helpful aria label');
});
});
@@ -356,11 +348,9 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{option}}
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
-
- assert.equal(trigger.attributes['aria-label'].value, 'ariaLabelString', 'aria-label set correctly');
- assert.equal(trigger.attributes['aria-invalid'].value, 'true', 'aria-invalid set correctly');
- assert.equal(trigger.attributes['aria-required'].value, 'true', 'aria-required set correctly');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-label', 'ariaLabelString', 'aria-label set correctly');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-invalid', 'true', 'aria-invalid set correctly');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-required', 'true', 'aria-required set correctly');
});
test('Multiple-select: The trigger element correctly passes through WAI-ARIA widget attributes', async function(assert) {
@@ -380,11 +370,9 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{option}}
{{/power-select-multiple}}
`);
- let trigger = find('.ember-power-select-trigger');
-
- assert.equal(trigger.attributes['aria-label'].value, 'ariaLabelString', 'aria-label set correctly');
- assert.equal(trigger.attributes['aria-invalid'].value, 'true', 'aria-invalid set correctly');
- assert.equal(trigger.attributes['aria-required'].value, 'true', 'aria-required set correctly');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-label', 'ariaLabelString', 'aria-label set correctly');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-invalid', 'true', 'aria-invalid set correctly');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-required', 'true', 'aria-required set correctly');
});
test('Single-select: The trigger element correctly passes through WAI-ARIA relationship attributes', async function(assert) {
@@ -403,10 +391,8 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{option}}
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
-
- assert.equal(trigger.attributes['aria-describedby'].value, 'ariaDescribedByString', 'aria-describedby set correctly');
- assert.equal(trigger.attributes['aria-labelledby'].value, 'ariaLabelledByString', 'aria-required set correctly');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-describedby', 'ariaDescribedByString', 'aria-describedby set correctly');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-labelledby', 'ariaLabelledByString', 'aria-required set correctly');
});
test('Multiple-select: The trigger element correctly passes through WAI-ARIA relationship attributes', async function(assert) {
@@ -425,10 +411,8 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{option}}
{{/power-select-multiple}}
`);
- let trigger = find('.ember-power-select-trigger');
-
- assert.equal(trigger.attributes['aria-describedby'].value, 'ariaDescribedByString', 'aria-describedby set correctly');
- assert.equal(trigger.attributes['aria-labelledby'].value, 'ariaLabelledByString', 'aria-required set correctly');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-describedby', 'ariaDescribedByString', 'aria-describedby set correctly');
+ assert.dom('.ember-power-select-trigger').hasAttribute('aria-labelledby', 'ariaLabelledByString', 'aria-required set correctly');
});
test('Trigger can have a custom aria-role passing triggerRole', async function(assert) {
@@ -444,9 +428,8 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- assert.equal(find('.ember-power-select-trigger').getAttribute('role'), role, 'The `role` was added.');
-
+ assert.dom('.ember-power-select-trigger').hasAttribute('role', role, 'The `role` was added.');
this.set('role', undefined);
- assert.equal(find('.ember-power-select-trigger').getAttribute('role'), 'button', 'The `role` was defaults to `button`.');
+ assert.dom('.ember-power-select-trigger').hasAttribute('role', 'button', 'The `role` was defaults to `button`.');
});
});
diff --git a/tests/integration/components/power-select/custom-search-test.js b/tests/integration/components/power-select/custom-search-test.js
index e594ed703..a0417f2e7 100644
--- a/tests/integration/components/power-select/custom-search-test.js
+++ b/tests/integration/components/power-select/custom-search-test.js
@@ -3,11 +3,10 @@ import { later } from '@ember/runloop';
import { task, timeout } from 'ember-concurrency';
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render, settled } from '@ember/test-helpers';
+import { render, settled, click} from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
import { numbers, countries } from '../constants';
-import { click } from '@ember/test-helpers';
import { find, findAll } from 'ember-native-dom-helpers';
import RSVP from 'rsvp';
diff --git a/tests/integration/components/power-select/customization-with-components-test.js b/tests/integration/components/power-select/customization-with-components-test.js
index 211ea5874..8b7416637 100644
--- a/tests/integration/components/power-select/customization-with-components-test.js
+++ b/tests/integration/components/power-select/customization-with-components-test.js
@@ -1,11 +1,10 @@
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render } from '@ember/test-helpers';
+import { render, click, focus } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { countries } from '../constants';
import { groupedNumbers } from '../constants';
import { clickTrigger } from 'ember-power-select/test-support/helpers';
-import { click, focus } from '@ember/test-helpers';
import { find, findAll } from 'ember-native-dom-helpers';
import { get } from '@ember/object';
import Component from '@ember/component';
diff --git a/tests/integration/components/power-select/disabled-test.js b/tests/integration/components/power-select/disabled-test.js
index bfe242e8d..1ec5905bf 100644
--- a/tests/integration/components/power-select/disabled-test.js
+++ b/tests/integration/components/power-select/disabled-test.js
@@ -1,11 +1,10 @@
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render } from '@ember/test-helpers';
+import { render, triggerEvent, triggerKeyEvent, click, focus } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { run } from '@ember/runloop';
import { clickTrigger, typeInSearch } from 'ember-power-select/test-support/helpers';
import { numbers, countriesWithDisabled } from '../constants';
-import { triggerEvent, triggerKeyEvent, click, focus } from '@ember/test-helpers';
module('Integration | Component | Ember Power Select (Disabled)', function(hooks) {
setupRenderingTest(hooks);
diff --git a/tests/integration/components/power-select/ember-data-test.js b/tests/integration/components/power-select/ember-data-test.js
index bb5ee63fe..5362d52bf 100644
--- a/tests/integration/components/power-select/ember-data-test.js
+++ b/tests/integration/components/power-select/ember-data-test.js
@@ -1,10 +1,9 @@
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render, settled } from '@ember/test-helpers';
+import { render, settled, click } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
import emberDataInitializer from '../../../../initializers/ember-data';
-import { click } from '@ember/test-helpers';
import setupMirage from 'ember-cli-mirage/test-support/setup-mirage';
module('Integration | Component | Ember Power Select (Ember-data integration)', function(hooks) {
diff --git a/tests/integration/components/power-select/general-behaviour-test.js b/tests/integration/components/power-select/general-behaviour-test.js
index ca5857265..33fc98f94 100644
--- a/tests/integration/components/power-select/general-behaviour-test.js
+++ b/tests/integration/components/power-select/general-behaviour-test.js
@@ -1,20 +1,15 @@
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render } from '@ember/test-helpers';
+import { render, click, triggerKeyEvent, triggerEvent, focus } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger, findContains } from 'ember-power-select/test-support/helpers';
import RSVP from 'rsvp';
import EmberObject, { get } from '@ember/object';
import { A } from '@ember/array';
import { run } from '@ember/runloop';
-import {
- numbers,
- names,
- countries
-} from '../constants';
+import { numbers, names, countries } from '../constants';
import PromiseProxyMixin from '@ember/object/promise-proxy-mixin';
import ArrayProxy from '@ember/array/proxy';
-import { click, triggerKeyEvent, triggerEvent, focus } from '@ember/test-helpers';
import { find, findAll } from 'ember-native-dom-helpers';
const PromiseArrayProxy = ArrayProxy.extend(PromiseProxyMixin);
diff --git a/tests/integration/components/power-select/groups-test.js b/tests/integration/components/power-select/groups-test.js
index f8cf6908a..1c0d3c8e3 100644
--- a/tests/integration/components/power-select/groups-test.js
+++ b/tests/integration/components/power-select/groups-test.js
@@ -1,10 +1,9 @@
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render } from '@ember/test-helpers';
+import { render, click } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
import { groupedNumbers } from '../constants';
-import { click } from '@ember/test-helpers';
import { find, findAll } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (Groups)', function(hooks) {
diff --git a/tests/integration/components/power-select/public-actions-test.js b/tests/integration/components/power-select/public-actions-test.js
index 61ba445a0..f8cdb1672 100644
--- a/tests/integration/components/power-select/public-actions-test.js
+++ b/tests/integration/components/power-select/public-actions-test.js
@@ -1,10 +1,10 @@
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render } from '@ember/test-helpers';
+import { render, click, triggerKeyEvent, focus } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { clickTrigger, typeInSearch } from 'ember-power-select/test-support/helpers';
import { numbers } from '../constants';
-import { find, findAll, click, triggerKeyEvent, focus } from '@ember/test-helpers';
+import { find, findAll } from 'ember-native-dom-helpers';
import { run } from '@ember/runloop';
function assertPublicAPIShape(assert, select) {
diff --git a/tests/integration/components/power-select/touch-control-test.js b/tests/integration/components/power-select/touch-control-test.js
index 82f1189af..9a698b237 100644
--- a/tests/integration/components/power-select/touch-control-test.js
+++ b/tests/integration/components/power-select/touch-control-test.js
@@ -1,9 +1,8 @@
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render } from '@ember/test-helpers';
+import { render, tap } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { numbers } from '../constants';
-import { tap } from '@ember/test-helpers';
module('Integration | Component | Ember Power Select (Touch control)', function(hooks) {
setupRenderingTest(hooks);
From 9ec9cf6ba7dc3e88883ff0a541539c4a83308d70 Mon Sep 17 00:00:00 2001
From: Miguel Camba
Date: Mon, 16 Apr 2018 23:41:54 +0200
Subject: [PATCH 13/34] Modernize test suite part 5 (#1093)
---
.../power-select/custom-search-test.js | 104 ++++++++----------
.../customization-with-attrs-test.js | 13 +--
.../customization-with-components-test.js | 54 ++++-----
3 files changed, 75 insertions(+), 96 deletions(-)
diff --git a/tests/integration/components/power-select/custom-search-test.js b/tests/integration/components/power-select/custom-search-test.js
index a0417f2e7..58ab08f7b 100644
--- a/tests/integration/components/power-select/custom-search-test.js
+++ b/tests/integration/components/power-select/custom-search-test.js
@@ -7,7 +7,6 @@ import { render, settled, click} from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
import { numbers, countries } from '../constants';
-import { find, findAll } from 'ember-native-dom-helpers';
import RSVP from 'rsvp';
module('Integration | Component | Ember Power Select (Custom search function)', function(hooks) {
@@ -25,7 +24,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
`);
clickTrigger();
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'Type to search', 'The dropdown shows the "type to search" message');
+ assert.dom('.ember-power-select-option').hasText('Type to search', 'The dropdown shows the "type to search" message');
});
test('The search text shouldn\'t appear if options are loading', async function(assert) {
@@ -46,8 +45,8 @@ module('Integration | Component | Ember Power Select (Custom search function)',
}, 100);
}));
clickTrigger();
- assert.notOk(/Type to search/.test(find('.ember-power-select-dropdown').textContent), 'The type to search message doesn\'t show');
- assert.ok(/Loading options\.\.\./.test(find('.ember-power-select-dropdown').textContent), '"Loading options..." message appears');
+ assert.dom('.ember-power-select-dropdown').doesNotIncludeText('Type to search', 'The type to search message doesn\'t show');
+ assert.dom('.ember-power-select-dropdown').includesText('Loading options...', '"Loading options..." message appears');
});
test('When no options are given but there is a search action, a "type to search" message is rendered', async function(assert) {
@@ -61,8 +60,8 @@ module('Integration | Component | Ember Power Select (Custom search function)',
`);
clickTrigger();
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'Type to search');
- assert.ok(find('.ember-power-select-option').classList.contains('ember-power-select-option--search-message'), 'The option with the search message has a special class');
+ assert.dom('.ember-power-select-option').hasText('Type to search');
+ assert.dom('.ember-power-select-option').hasClass('ember-power-select-option--search-message', 'The option with the search message has a special class');
});
test('The "type to search" message can be customized passing `searchMessage=something`', async function(assert) {
@@ -76,7 +75,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
`);
clickTrigger();
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'Type the name of the thing');
+ assert.dom('.ember-power-select-option').hasText('Type the name of the thing');
});
test('The search function can return an array and those options get rendered', async function(assert) {
@@ -94,7 +93,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
clickTrigger();
typeInSearch('teen');
- assert.equal(findAll('.ember-power-select-option').length, 7);
+ assert.dom('.ember-power-select-option').exists({ count: 7 });
});
test('The search function can return a promise that resolves to an array and those options get rendered', async function(assert) {
@@ -117,9 +116,8 @@ module('Integration | Component | Ember Power Select (Custom search function)',
clickTrigger();
typeInSearch('teen');
- return settled().then(function() {
- assert.equal(findAll('.ember-power-select-option').length, 7);
- });
+ await settled()
+ assert.dom('.ember-power-select-option').exists({ count: 7 });
});
test('While the async search is being performed the "Type to search" dissapears the "Loading..." message appears', async function(assert) {
@@ -140,11 +138,10 @@ module('Integration | Component | Ember Power Select (Custom search function)',
`);
clickTrigger();
- assert.ok(/Type to search/.test(find('.ember-power-select-dropdown').textContent), 'The type to search message is displayed');
+ assert.dom('.ember-power-select-dropdown').includesText('Type to search', 'The type to search message is displayed');
typeInSearch('teen');
- assert.ok(!/Type to search/.test(find('.ember-power-select-dropdown').textContent), 'The type to search message dissapeared');
- assert.ok(/Loading options\.\.\./.test(find('.ember-power-select-dropdown').textContent), '"Loading options..." message appears');
- return settled();
+ assert.dom('.ember-power-select-dropdown').doesNotIncludeText('Type to search', 'The type to search message dissapeared');
+ assert.dom('.ember-power-select-dropdown').includesText('Loading options...', '"Loading options..." message appears');
});
test('When the search resolves to an empty array then the "No results found" message or block appears.', async function(assert) {
@@ -166,9 +163,8 @@ module('Integration | Component | Ember Power Select (Custom search function)',
clickTrigger();
typeInSearch('teen');
- return settled().then(function() {
- assert.ok(/No results found/.test(find('.ember-power-select-option').textContent), 'The default "No results" message renders');
- });
+ await settled();
+ assert.dom('.ember-power-select-option').includesText('No results found', 'The default "No results" message renders');
});
test('When the search resolves to an empty array then the custom "No results" message appears', async function(assert) {
@@ -190,9 +186,8 @@ module('Integration | Component | Ember Power Select (Custom search function)',
clickTrigger();
typeInSearch('teen');
- return settled().then(function() {
- assert.ok(/Meec\. Try again/.test(find('.ember-power-select-option').textContent), 'The customized "No results" message renders');
- });
+ await settled();
+ assert.dom('.ember-power-select-option').includesText('Meec. Try again', 'The customized "No results" message renders');
});
test('When the search resolves to an empty array then the custom alternate block renders', async function(assert) {
@@ -216,9 +211,8 @@ module('Integration | Component | Ember Power Select (Custom search function)',
clickTrigger();
typeInSearch('teen');
- return settled().then(function() {
- assert.ok(find('.ember-power-select-dropdown .foo-bar'), 'The alternate block message gets rendered');
- });
+ await settled();
+ assert.dom('.ember-power-select-dropdown .foo-bar').exists('The alternate block message gets rendered');
});
// Random failure test. Fix
@@ -274,9 +268,8 @@ module('Integration | Component | Ember Power Select (Custom search function)',
clickTrigger();
typeInSearch('teen');
- return settled().then(function() {
- assert.equal(findAll('.ember-power-select-option')[0].attributes['aria-current'].value, 'true', 'The first result is highlighted');
- });
+ await settled();
+ assert.dom('.ember-power-select-option').hasAttribute('aria-current', 'true', 'The first result is highlighted');
});
test('On an select with a selected value, if after a search this value is not among the options the first element is highlighted', async function(assert) {
@@ -299,12 +292,11 @@ module('Integration | Component | Ember Power Select (Custom search function)',
`);
clickTrigger();
- assert.equal(findAll('.ember-power-select-option')[2].attributes['aria-current'].value, 'true', 'The 3rd result is highlighted');
+ assert.dom('.ember-power-select-option:nth-child(3)').hasAttribute('aria-current', 'true', 'The 3rd result is highlighted');
typeInSearch('teen');
- return settled().then(function() {
- assert.equal(findAll('.ember-power-select-option')[0].attributes['aria-current'].value, 'true', 'The first result is highlighted');
- });
+ await settled();
+ assert.dom('.ember-power-select-option').hasAttribute('aria-current', 'true', 'The first result is highlighted');
});
test('Closing a component with a custom search cleans the search box and the results list', async function(assert) {
@@ -322,14 +314,14 @@ module('Integration | Component | Ember Power Select (Custom search function)',
await clickTrigger();
typeInSearch('teen');
- assert.equal(findAll('.ember-power-select-option').length, 7, 'Results are filtered');
- assert.equal(find('.ember-power-select-search-input').value, 'teen');
+ assert.dom('.ember-power-select-option').exists({ count: 7 }, 'Results are filtered');
+ assert.dom('.ember-power-select-search-input').hasValue('teen');
await click('#different-node');
await clickTrigger();
- assert.equal(findAll('.ember-power-select-option').length, 1, 'Results have been cleared');
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'Type to search');
- assert.equal(find('.ember-power-select-search-input').value, '', 'The searchbox was cleared');
+ assert.dom('.ember-power-select-option').exists({ count: 1 }, 'Results have been cleared');
+ assert.dom('.ember-power-select-option').hasText('Type to search');
+ assert.dom('.ember-power-select-search-input').hasNoValue('The searchbox was cleared');
});
test('When received both options and search, those options are shown when the dropdown opens before the first search is performed', async function(assert) {
@@ -352,13 +344,12 @@ module('Integration | Component | Ember Power Select (Custom search function)',
`);
clickTrigger();
- assert.equal(findAll('.ember-power-select-option').length, 20, 'All the options are shown');
+ assert.dom('.ember-power-select-option').exists({ count: 20 }, 'All the options are shown');
typeInSearch('teen');
- assert.equal(findAll('.ember-power-select-option').length, 21, 'All the options are shown and also the loading message');
- assert.equal(findAll('.ember-power-select-option')[0].textContent.trim(), 'Loading options...');
- return settled().then(function() {
- assert.equal(findAll('.ember-power-select-option').length, 7, 'All the options are shown but no the loading message');
- });
+ assert.dom('.ember-power-select-option').exists({ count: 21 }, 'All the options are shown and also the loading message');
+ assert.dom('.ember-power-select-option').hasText('Loading options...');
+ await settled();
+ assert.dom('.ember-power-select-option').exists({ count: 7 }, 'All the options are shown but no the loading message');
});
test('Don\'t return from the search action and update the options instead also works as an strategy', async function(assert) {
@@ -379,12 +370,11 @@ module('Integration | Component | Ember Power Select (Custom search function)',
`);
clickTrigger();
- assert.equal(findAll('.ember-power-select-option').length, 20, 'All the options are shown');
+ assert.dom('.ember-power-select-option').exists({ count: 20 }, 'All the options are shown');
typeInSearch('teen');
- return settled().then(function() {
- assert.equal(findAll('.ember-power-select-option').length, 7);
- });
+ await settled();
+ assert.dom('.ember-power-select-option').exists({ count: 7 });
});
// This test fails randomly
@@ -468,8 +458,8 @@ module('Integration | Component | Ember Power Select (Custom search function)',
typeInSearch('');
}, 200);
setTimeout(function() {
- assert.equal(findAll('.ember-power-select-option').length, numbers.length, 'All the options are displayed after clearing the search');
- assert.equal(findAll('.ember-power-select-option')[1].textContent.trim(), 'two:', 'The results are the original options');
+ assert.dom('.ember-power-select-option').exists({ count: numbers.length }, 'All the options are displayed after clearing the search');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('two:', 'The results are the original options');
done();
}, 300);
});
@@ -495,10 +485,10 @@ module('Integration | Component | Ember Power Select (Custom search function)',
clickTrigger();
typeInSearch('teen');
setTimeout(function() {
- assert.equal(findAll('.ember-power-select-option')[0].textContent.trim(), 'thirteen:teen', 'The results and the lastSearchedText have updated');
+ assert.dom('.ember-power-select-option').hasText('thirteen:teen', 'The results and the lastSearchedText have updated');
typeInSearch('four');
- assert.equal(findAll('.ember-power-select-option')[0].textContent.trim(), 'Loading options...', 'There is a search going on');
- assert.equal(findAll('.ember-power-select-option')[1].textContent.trim(), 'thirteen:teen', 'The results and the lastSearchedText are still the same because the search has not finished yet');
+ assert.dom('.ember-power-select-option').hasText('Loading options...', 'There is a search going on');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('thirteen:teen', 'The results and the lastSearchedText are still the same because the search has not finished yet');
done();
}, 150);
});
@@ -524,10 +514,10 @@ module('Integration | Component | Ember Power Select (Custom search function)',
clickTrigger();
typeInSearch('teen');
setTimeout(function() {
- assert.equal(findAll('.ember-power-select-option')[0].textContent.trim(), 'thirteen:teen', 'The results and the searchTerm have updated');
+ assert.dom('.ember-power-select-option').hasText('thirteen:teen', 'The results and the searchTerm have updated');
typeInSearch('four');
- assert.equal(findAll('.ember-power-select-option')[0].textContent.trim(), 'Loading options...', 'There is a search going on');
- assert.equal(findAll('.ember-power-select-option')[1].textContent.trim(), 'thirteen:teen', 'The results and the searchTerm are still the same because the search has not finished yet');
+ assert.dom('.ember-power-select-option').hasText('Loading options...', 'There is a search going on');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('thirteen:teen', 'The results and the searchTerm are still the same because the search has not finished yet');
done();
}, 150);
});
@@ -577,11 +567,11 @@ module('Integration | Component | Ember Power Select (Custom search function)',
`);
clickTrigger();
- assert.equal(findAll('.ember-power-select-option').length, 20, 'There is 20 options');
+ assert.dom('.ember-power-select-option').exists({ count: 20 }, 'There is 20 options');
typeInSearch('teen');
- assert.equal(findAll('.ember-power-select-option').length, 7, 'There is 7 options');
+ assert.dom('.ember-power-select-option').exists({ count: 7 }, 'There is 7 options');
typeInSearch('');
- assert.equal(findAll('.ember-power-select-option').length, 20, 'There is 20 options again§');
+ assert.dom('.ember-power-select-option').exists({ count: 20 }, 'There is 20 options again§');
});
test('BUGFIX: If the user provides a custom matcher, that matcher receives the entire option even if the user also provided a searchField', async function(assert) {
diff --git a/tests/integration/components/power-select/customization-with-attrs-test.js b/tests/integration/components/power-select/customization-with-attrs-test.js
index e25e596e9..bb72da088 100644
--- a/tests/integration/components/power-select/customization-with-attrs-test.js
+++ b/tests/integration/components/power-select/customization-with-attrs-test.js
@@ -3,7 +3,6 @@ import { setupRenderingTest } from 'ember-qunit';
import { render } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { countries } from '../constants';
-import { find } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (Customization using attrs)', function(hooks) {
setupRenderingTest(hooks);
@@ -15,12 +14,12 @@ module('Integration | Component | Ember Power Select (Customization using attrs)
this.country = countries[1]; // Spain
await render(hbs`
- {{#power-select renderInPlace=true classNames="ember-power-select" options=countries selected=country onchange=(action (mut foo)) as |country|}}
+ {{#power-select renderInPlace=true classNames="foo" options=countries selected=country onchange=(action (mut foo)) as |country|}}
{{country.name}}
{{/power-select}}
`);
- assert.ok(find('.ember-basic-dropdown.ember-power-select'), 'Class was added.');
+ assert.dom('.ember-basic-dropdown').hasClass('foo', 'Class was added.');
});
test('trigger on single selects can be customized using triggerClass', async function(assert) {
@@ -35,7 +34,7 @@ module('Integration | Component | Ember Power Select (Customization using attrs)
{{/power-select}}
`);
- assert.ok(find('.country-single-trigger'), 'Class was added.');
+ assert.dom('.ember-power-select-trigger').hasClass('country-single-trigger', 'Class was added.');
});
test('trigger on multiple selects can be customized using triggerClass', async function(assert) {
@@ -50,7 +49,7 @@ module('Integration | Component | Ember Power Select (Customization using attrs)
{{/power-select}}
`);
- assert.ok(find('.country-multiple-trigger'), 'Class was added.');
+ assert.dom('.ember-power-select-trigger').hasClass('country-multiple-trigger', 'Class was added.');
});
test('Trigger can have a custom id passing triggerId', async function(assert) {
@@ -65,7 +64,7 @@ module('Integration | Component | Ember Power Select (Customization using attrs)
{{/power-select}}
`);
- assert.equal(find('.ember-power-select-trigger').id, 'this-is-my-id', 'The `id` was added.');
+ assert.dom('.ember-power-select-trigger').hasAttribute('id', 'this-is-my-id', 'The `id` was added.');
});
test('Trigger can have a custom id passing triggerId', async function(assert) {
@@ -80,6 +79,6 @@ module('Integration | Component | Ember Power Select (Customization using attrs)
{{/power-select-multiple}}
`);
- assert.equal(find('.ember-power-select-trigger').id, 'this-is-my-id', 'The `id` was added.');
+ assert.dom('.ember-power-select-trigger').hasAttribute('id', 'this-is-my-id', 'The `id` was added.');
});
});
diff --git a/tests/integration/components/power-select/customization-with-components-test.js b/tests/integration/components/power-select/customization-with-components-test.js
index 8b7416637..2c6b249f4 100644
--- a/tests/integration/components/power-select/customization-with-components-test.js
+++ b/tests/integration/components/power-select/customization-with-components-test.js
@@ -5,7 +5,6 @@ import hbs from 'htmlbars-inline-precompile';
import { countries } from '../constants';
import { groupedNumbers } from '../constants';
import { clickTrigger } from 'ember-power-select/test-support/helpers';
-import { find, findAll } from 'ember-native-dom-helpers';
import { get } from '@ember/object';
import Component from '@ember/component';
import { isPresent } from '@ember/utils';
@@ -25,9 +24,9 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{/power-select}}
`);
- assert.notOk(find('.ember-power-select-status-icon'), 'The provided trigger component is not rendered');
- assert.ok(find('.ember-power-select-trigger .icon-flag'), 'The custom flag appears.');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'Spain', 'With the country name as the text.');
+ assert.dom('.ember-power-select-status-icon').doesNotExist('The provided trigger component is not rendered');
+ assert.dom('.ember-power-select-trigger .icon-flag').exists('The custom flag appears.');
+ assert.dom('.ember-power-select-trigger').hasText('Spain', 'With the country name as the text.');
});
test('triggerComponent receives loading message', async function(assert) {
@@ -41,7 +40,7 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{option}}
{{/power-select}}
`);
- assert.equal(find('.custom-trigger-component').textContent, 'hmmmm paella', 'The loading message is passed to the trigger component');
+ assert.dom('.custom-trigger-component').hasText('hmmmm paella', 'The loading message is passed to the trigger component');
});
test('selected item option can be customized using selectedItemComponent', async function(assert) {
@@ -56,9 +55,9 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{/power-select}}
`);
- assert.ok(find('.ember-power-select-status-icon'), 'The provided trigger component is rendered');
- assert.ok(find('.ember-power-select-trigger .icon-flag'), 'The custom flag appears.');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'Spain', 'With the country name as the text.');
+ assert.dom('.ember-power-select-status-icon').exists('The provided trigger component is rendered');
+ assert.dom('.ember-power-select-trigger .icon-flag').exists('The custom flag appears.');
+ assert.dom('.ember-power-select-trigger').hasText('Spain', 'With the country name as the text.');
});
test('the list of options can be customized using optionsComponent', async function(assert) {
@@ -74,9 +73,8 @@ module('Integration | Component | Ember Power Select (Customization using compon
`);
clickTrigger();
- let text = find('.ember-power-select-options').textContent.trim();
- assert.ok(/Countries:/.test(text), 'The given component is rendered');
- assert.ok(/3\. Russia/.test(text), 'The component has access to the options');
+ assert.dom('.ember-power-select-options').includesText('Countries:', 'The given component is rendered');
+ assert.dom('.ember-power-select-options').includesText('3. Russia', 'The component has access to the options');
});
test('the `optionsComponent` receives the `extra` hash', async function(assert) {
@@ -92,9 +90,8 @@ module('Integration | Component | Ember Power Select (Customization using compon
`);
clickTrigger();
- let text = find('.ember-power-select-options').textContent.trim();
- assert.ok(/Countries:/.test(text), 'The given component is rendered');
- assert.ok(/3\. RU/.test(text), 'The component uses the field in the extra has to render the options');
+ assert.dom('.ember-power-select-options').includesText('Countries:', 'The given component is rendered');
+ assert.dom('.ember-power-select-options').includesText('3. RU', 'The component uses the field in the extra has to render the options');
});
test('the content before the list can be customized passing `beforeOptionsComponent`', async function(assert) {
@@ -116,12 +113,10 @@ module('Integration | Component | Ember Power Select (Customization using compon
`);
clickTrigger();
-
- let element = find('.ember-power-select-dropdown #custom-before-options-p-tag');
- assert.ok(element, 'The custom component is rendered instead of the usual search bar');
- assert.equal(element.innerText, 'inception', 'The placeholder attribute is passed through.');
- assert.ok(find('.ember-power-select-dropdown .ember-power-select-placeholder'), 'The placeholder component is passed through.');
- assert.notOk(find('.ember-power-select-search-input'), 'The search input is not visible');
+ assert.dom('.ember-power-select-dropdown #custom-before-options-p-tag').exists('The custom component is rendered instead of the usual search bar');
+ assert.dom('.ember-power-select-dropdown #custom-before-options-p-tag').hasText('inception', 'The placeholder attribute is passed through.');
+ assert.dom('.ember-power-select-dropdown .ember-power-select-placeholder').exists('The placeholder component is passed through.');
+ assert.dom('.ember-power-select-search-input').doesNotExist('The search input is not visible');
});
test('the content after the list can be customized passing `afterOptionsComponent`', async function(assert) {
@@ -137,8 +132,8 @@ module('Integration | Component | Ember Power Select (Customization using compon
`);
clickTrigger();
- assert.ok(find('.ember-power-select-dropdown #custom-after-options-p-tag'), 'The custom component is rendered instead of the usual search bar');
- assert.ok(find('.ember-power-select-search-input'), 'The search input is still visible');
+ assert.dom('.ember-power-select-dropdown #custom-after-options-p-tag').exists('The custom component is rendered instead of the usual search bar');
+ assert.dom('.ember-power-select-search-input').exists('The search input is still visible');
});
test('the `beforeOptionsComponent` and `afterOptionsComponent` receive the `extra` hash', async function(assert) {
@@ -193,7 +188,7 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{/power-select}}
`);
- focus('#focusable-input');
+ await focus('#focusable-input');
});
test('the search message can be customized passing `searchMessageComponent`', async function(assert) {
@@ -208,7 +203,7 @@ module('Integration | Component | Ember Power Select (Customization using compon
`);
clickTrigger();
- assert.ok(find('.ember-power-select-dropdown #custom-search-message-p-tag'), 'The custom component is rendered instead of the usual message');
+ assert.dom('.ember-power-select-dropdown #custom-search-message-p-tag').exists('The custom component is rendered instead of the usual message');
});
test('placeholder can be customized using placeholderComponent', async function(assert) {
@@ -226,12 +221,8 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{/power-select}}
`);
- assert.ok(find('.ember-power-select-placeholder'), 'The placeholder appears.');
- assert.equal(
- find('.ember-power-select-placeholder').textContent.trim(),
- 'This is a very bold placeholder',
- 'The placeholder content is equal.'
- );
+ assert.dom('.ember-power-select-placeholder').exists('The placeholder appears.');
+ assert.dom('.ember-power-select-placeholder').hasText('This is a very bold placeholder', 'The placeholder content is equal.');
});
test('groupComponent can be overridden', async function(assert) {
@@ -250,8 +241,7 @@ module('Integration | Component | Ember Power Select (Customization using compon
`);
clickTrigger();
-
- assert.equal(findAll('.ember-power-select-options .custom-component').length, numberOfGroups);
+ assert.dom('.ember-power-select-options .custom-component').exists({ count: numberOfGroups });
});
test('groupComponent has extension points', async function(assert) {
From 0a224ee909cfbd5ea0ed740c64549d61cd77c84c Mon Sep 17 00:00:00 2001
From: cibernox
Date: Tue, 17 Apr 2018 13:17:31 +0200
Subject: [PATCH 14/34] Remove more usages of ember-native-dom-helpers
---
.../components/power-select/groups-test.js | 41 +++++++++----------
1 file changed, 20 insertions(+), 21 deletions(-)
diff --git a/tests/integration/components/power-select/groups-test.js b/tests/integration/components/power-select/groups-test.js
index 1c0d3c8e3..7961d2550 100644
--- a/tests/integration/components/power-select/groups-test.js
+++ b/tests/integration/components/power-select/groups-test.js
@@ -4,7 +4,6 @@ import { render, click } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
import { groupedNumbers } from '../constants';
-import { find, findAll } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (Groups)', function(hooks) {
setupRenderingTest(hooks);
@@ -23,15 +22,15 @@ module('Integration | Component | Ember Power Select (Groups)', function(hooks)
clickTrigger();
- let rootLevelGroups = findAll('.ember-power-select-dropdown > .ember-power-select-options > .ember-power-select-group');
- let rootLevelOptions = findAll('.ember-power-select-dropdown > .ember-power-select-options > .ember-power-select-option');
- assert.equal(rootLevelGroups.length, 3, 'There is 3 groups in the root level');
- assert.equal(rootLevelOptions.length, 2, 'There is 2 options in the root level');
- assert.equal(find('.ember-power-select-group-name', rootLevelGroups[0]).textContent.trim(), 'Smalls');
- assert.equal(find('.ember-power-select-group-name', rootLevelGroups[1]).textContent.trim(), 'Mediums');
- assert.equal(find('.ember-power-select-group-name', rootLevelGroups[2]).textContent.trim(), 'Bigs');
- assert.equal(rootLevelOptions[0].textContent.trim(), 'one hundred');
- assert.equal(rootLevelOptions[1].textContent.trim(), 'one thousand');
+ let rootLevelGroups = document.querySelectorAll('.ember-power-select-dropdown > .ember-power-select-options > .ember-power-select-group');
+ let rootLevelOptions = document.querySelectorAll('.ember-power-select-dropdown > .ember-power-select-options > .ember-power-select-option');
+ assert.dom('.ember-power-select-dropdown > .ember-power-select-options > .ember-power-select-group').exists({ count: 3 }, 'There is 3 groups in the root level');
+ assert.dom('.ember-power-select-dropdown > .ember-power-select-options > .ember-power-select-option').exists({ count: 2 }, 'There is 2 options in the root level');
+ assert.dom('.ember-power-select-group-name', rootLevelGroups[0]).hasText('Smalls');
+ assert.dom('.ember-power-select-group-name', rootLevelGroups[1]).hasText('Mediums');
+ assert.dom('.ember-power-select-group-name', rootLevelGroups[2]).hasText('Bigs');
+ assert.dom(rootLevelOptions[0]).hasText('one hundred');
+ assert.dom(rootLevelOptions[1]).hasText('one thousand');
let bigs = [].slice.apply(rootLevelGroups[2].children).filter((e) => e.classList.contains('ember-power-select-options'))[0];
let bigGroups = [].slice.apply(bigs.children).filter((e) => e.classList.contains('ember-power-select-group'));
let bigOptions = [].slice.apply(bigs.children).filter((e) => e.classList.contains('ember-power-select-option'));
@@ -54,10 +53,10 @@ module('Integration | Component | Ember Power Select (Groups)', function(hooks)
{{/power-select}}
`);
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is not rendered');
clickTrigger();
- assert.equal(findAll('.ember-power-select-option').length, 4);
- assert.equal(findAll('.ember-power-select-option')[1].textContent.trim(), 'Tigers');
+ assert.dom('.ember-power-select-option').exists({ count: 4 });
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('Tigers');
});
test('When filtering, a group title is visible as long as one of it\'s elements is', async function(assert) {
@@ -71,12 +70,12 @@ module('Integration | Component | Ember Power Select (Groups)', function(hooks)
`);
clickTrigger();
typeInSearch('ve');
- let groupNames = findAll('.ember-power-select-group-name').map((e) => e.textContent.trim());
- let optionValues = findAll('.ember-power-select-option').map((e) => e.textContent.trim());
+ let groupNames = Array.from(document.querySelectorAll('.ember-power-select-group-name')).map((e) => e.textContent.trim());
+ let optionValues = Array.from(document.querySelectorAll('.ember-power-select-option')).map((e) => e.textContent.trim());
assert.deepEqual(groupNames, ['Mediums', 'Bigs', 'Fairly big', 'Really big'], 'Only the groups with matching options are shown');
assert.deepEqual(optionValues, ['five', 'seven', 'eleven', 'twelve'], 'Only the matching options are shown');
typeInSearch('lve');
- groupNames = findAll('.ember-power-select-group-name').map((e) => e.textContent.trim());
+ groupNames = Array.from(document.querySelectorAll('.ember-power-select-group-name')).map((e) => e.textContent.trim());
assert.deepEqual(groupNames, ['Bigs', 'Really big'], 'With no depth level');
});
@@ -90,10 +89,10 @@ module('Integration | Component | Ember Power Select (Groups)', function(hooks)
{{/power-select}}
`);
await clickTrigger();
- let option = findAll('.ember-power-select-option').find((e) => e.textContent.indexOf('four') > -1);
+ let option = Array.from(document.querySelectorAll('.ember-power-select-option')).find((e) => e.textContent.indexOf('four') > -1);
await click(option);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', 'The clicked option was selected');
- assert.notOk(find('.ember-power-select-options'), 'The dropdown has dissapeared');
+ assert.dom('.ember-power-select-trigger').hasText('four', 'The clicked option was selected');
+ assert.dom('.ember-power-select-options').doesNotExist('The dropdown has dissapeared');
});
test('Clicking on the title of a group doesn\'t performs any action nor closes the dropdown', async function(assert) {
@@ -107,7 +106,7 @@ module('Integration | Component | Ember Power Select (Groups)', function(hooks)
`);
clickTrigger();
- click(findAll('.ember-power-select-group-name')[1]);
- assert.ok(find('.ember-power-select-dropdown'), 'The select is still opened');
+ await click(document.querySelectorAll('.ember-power-select-group-name')[1]);
+ assert.dom('.ember-power-select-dropdown').exists('The select is still opened');
});
});
From 97621afa0284a2034a52684d80bbf766a981bb43 Mon Sep 17 00:00:00 2001
From: cibernox
Date: Tue, 17 Apr 2018 14:26:41 +0200
Subject: [PATCH 15/34] Add more qunit-dom
---
.../power-select/general-behaviour-test.js | 163 +++++++++---------
1 file changed, 78 insertions(+), 85 deletions(-)
diff --git a/tests/integration/components/power-select/general-behaviour-test.js b/tests/integration/components/power-select/general-behaviour-test.js
index 33fc98f94..dc08f6e79 100644
--- a/tests/integration/components/power-select/general-behaviour-test.js
+++ b/tests/integration/components/power-select/general-behaviour-test.js
@@ -1,6 +1,6 @@
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render, click, triggerKeyEvent, triggerEvent, focus } from '@ember/test-helpers';
+import { render, click, triggerKeyEvent, triggerEvent, focus, settled } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger, findContains } from 'ember-power-select/test-support/helpers';
import RSVP from 'rsvp';
@@ -27,10 +27,10 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is not rendered');
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
});
test('Click in the trigger of an opened select closes the dropdown', async function(assert) {
@@ -44,10 +44,10 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
await clickTrigger();
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is not rendered');
});
test('Search functionality is enabled by default', async function(assert) {
@@ -61,7 +61,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-search'), 'The search box is rendered');
+ assert.dom('.ember-power-select-search').exists('The search box is rendered');
});
test('The search functionality can be disabled by passing `searchEnabled=false`', async function(assert) {
@@ -75,8 +75,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
- assert.notOk(find('.ember-power-select-search'), 'The search box NOT rendered');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
+ assert.dom('.ember-power-select-search').doesNotExist('The search box NOT rendered');
});
test("The search box shouldn't gain focus if autofocus is disabled", async function(assert) {
@@ -96,7 +96,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-search-input') !== document.activeElement, 'The search box is not focused after opening select');
+ assert.dom('.ember-power-select-search-input').isNotFocused('The search box is not focused after opening select');
});
test('Each option of the select is the result of yielding an item', async function(assert) {
@@ -110,15 +110,13 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- let options = findAll('.ember-power-select-option');
- assert.equal(options.length, numbers.length, 'There is as many options in the markup as in the supplied array');
- assert.equal(options[0].textContent.trim(), 'one');
- assert.equal(options[9].textContent.trim(), 'ten');
- assert.equal(options[13].textContent.trim(), 'fourteen');
+ assert.dom('.ember-power-select-option').exists({ count: numbers.length }, 'There is as many options in the markup as in the supplied array');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('one');
+ assert.dom('.ember-power-select-option:nth-child(10)').hasText('ten');
+ assert.dom('.ember-power-select-option:nth-child(14)').hasText('fourteen');
});
test('If the passed options is a promise and it\'s not resolved the component shows a Loading message', async function(assert) {
- let done = assert.async();
assert.expect(4);
this.numbersPromise = [];
@@ -135,17 +133,14 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
}));
clickTrigger();
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'Loading options...', 'The loading message appears while the promise is pending');
- assert.ok(find('.ember-power-select-option').classList.contains('ember-power-select-option--loading-message'), 'The row has a special class to differentiate it from regular options');
- setTimeout(function() {
- assert.ok(!/Loading options/.test(find('.ember-power-select-option').textContent), 'The loading message is gone');
- assert.equal(findAll('.ember-power-select-option').length, 20, 'The results appear when the promise is resolved');
- done();
- }, 200);
+ assert.dom('.ember-power-select-option').hasText('Loading options...', 'The loading message appears while the promise is pending');
+ assert.dom('.ember-power-select-option').hasClass('ember-power-select-option--loading-message', 'The row has a special class to differentiate it from regular options');
+ await settled()
+ assert.dom('.ember-power-select-option').doesNotIncludeText('Loading options', 'The loading message is gone');
+ assert.dom('.ember-power-select-option').exists({ count: 20 }, 'The results appear when the promise is resolved');
});
test('If the passed options is a promise and it\'s not resolved but the `loadingMessage` attribute is false, no loading message is shown', async function(assert) {
- let done = assert.async();
assert.expect(2);
this.numbersPromise = [];
@@ -162,11 +157,9 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
}));
clickTrigger();
- assert.notOk(find('.ember-power-select-option'), 'No loading options message is displayed');
- setTimeout(function() {
- assert.equal(findAll('.ember-power-select-option').length, 20, 'The results appear when the promise is resolved');
- done();
- }, 120);
+ assert.dom('.ember-power-select-option').doesNotExist('No loading options message is displayed');
+ await settled();
+ assert.dom('.ember-power-select-option').exists({ count: 20 }, 'The results appear when the promise is resolved');
});
test('If a placeholder is provided, it shows while no element is selected', async function(assert) {
@@ -179,11 +172,11 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- assert.equal(find('.ember-power-select-trigger .ember-power-select-placeholder').textContent.trim(), 'abracadabra', 'The placeholder is rendered when there is no element');
+ assert.dom('.ember-power-select-trigger .ember-power-select-placeholder').hasText('abracadabra', 'The placeholder is rendered when there is no element');
await clickTrigger();
- await click(findAll('.ember-power-select-option')[3]);
- assert.notOk(find('.ember-power-select-trigger .ember-power-select-placeholder'), 'The placeholder is gone');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', 'The selected item replaced it');
+ await click('.ember-power-select-option:nth-child(4)');
+ assert.dom('.ember-power-select-trigger .ember-power-select-placeholder').doesNotExist('The placeholder is gone');
+ assert.dom('.ember-power-select-trigger').hasText('four', 'The selected item replaced it');
});
test('If a `searchPlaceholder` is provided, it shows on the searchbox of single selects while nothing is there', async function(assert) {
@@ -197,7 +190,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-search-input').attributes.placeholder.value, 'foobar yo!', 'The searchbox has the proper placeholder');
+ assert.dom('.ember-power-select-search-input').hasAttribute('placeholder', 'foobar yo!', 'The searchbox has the proper placeholder');
});
test('If the `selected` value changes the select gets updated, but the `onchange` action doesn\'t fire', async function(assert) {
@@ -216,10 +209,10 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
run(() => this.set('selected', 'three'));
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'three', 'The `three` element is selected');
+ assert.dom('.ember-power-select-trigger').hasText('three', 'The `three` element is selected');
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'three', 'The proper option gets highlighed');
- assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'three', 'The proper option gets selected');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('three', 'The proper option gets highlighed');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').hasText('three', 'The proper option gets selected');
});
test('If the user selects a value and later on the selected value changes from the outside, the components updates too', async function(assert) {
@@ -233,12 +226,12 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing is selected');
+ assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected');
await clickTrigger();
- await click(findAll('.ember-power-select-option')[3]);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', '"four" has been selected');
+ await click('.ember-power-select-option:nth-child(4)');
+ assert.dom('.ember-power-select-trigger').hasText('four', '"four" has been selected');
run(() => this.set('selected', 'three'));
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'three', '"three" has been selected because a change came from the outside');
+ assert.dom('.ember-power-select-trigger').hasText('three', '"three" has been selected because a change came from the outside');
});
test('If the user passes `renderInPlace=true` the dropdown is added below the trigger instead of in the root', async function(assert) {
@@ -252,7 +245,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is inside the component');
+ assert.dom('.ember-power-select-dropdown').exists('The dropdown is inside the component');
});
test('If the user passes `closeOnSelect=false` the dropdown remains visible after selecting an option with the mouse', async function(assert) {
@@ -265,12 +258,12 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is not rendered');
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
- await click(findAll('.ember-power-select-option')[3]);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', '"four" has been selected');
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
+ await click('.ember-power-select-option:nth-child(4)');
+ assert.dom('.ember-power-select-trigger').hasText('four', '"four" has been selected');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
});
test('If the user passes `closeOnSelect=false` the dropdown remains visible after selecting an option with the with the keyboard', async function(assert) {
@@ -283,12 +276,12 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is not rendered');
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'one', '"one" has been selected');
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
+ assert.dom('.ember-power-select-trigger').hasText('one', '"one" has been selected');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
});
test('If the content of the options is refreshed (starting with empty array proxy) the available options should also refresh', async function(assert) {
@@ -315,7 +308,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
setTimeout(function() {
assert.equal(findAll('.ember-power-select-option').length, 1, 'The dropdown is opened and results shown after proxy is updated');
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'one');
+ assert.dom('.ember-power-select-option').hasText('one');
done();
}, 150);
});
@@ -342,7 +335,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
assert.ok(find('.ember-power-select-option'), 'The dropdown is opened and results shown with initial proxy contents');
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'one');
+ assert.dom('.ember-power-select-option').hasText('one');
typeInSearch('o');
@@ -416,7 +409,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await click(findAll('.ember-power-select-option')[0]);
await clickTrigger();
typeInSearch('thr');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'thr:two', 'The trigger also receives the public API');
+ assert.dom('.ember-power-select-trigger').hasText('thr:two', 'The trigger also receives the public API');
});
test('If there is no search action and the options is empty the select shows the default "no options" message', async function(assert) {
@@ -428,8 +421,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
assert.equal(findAll('.ember-power-select-option').length, 1);
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found');
- assert.ok(find('.ember-power-select-option').classList.contains('ember-power-select-option--no-matches-message'), 'The row has a special class to differentiate it from regular options');
+ assert.dom('.ember-power-select-option').hasText('No results found');
+ assert.dom('.ember-power-select-option').hasClass('ember-power-select-option--no-matches-message', 'The row has a special class to differentiate it from regular options');
});
test('If there is a search action and the options is empty it shows the `searchMessage`, and if after searching there is no results, it shows the `noResults` message', async function(assert) {
@@ -442,10 +435,10 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
assert.equal(findAll('.ember-power-select-option').length, 1);
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'Type to search');
+ assert.dom('.ember-power-select-option').hasText('Type to search');
typeInSearch('foo');
assert.equal(findAll('.ember-power-select-option').length, 1);
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found');
+ assert.dom('.ember-power-select-option').hasText('No results found');
});
test('The default "no options" message can be customized passing `noMatchesMessage="other message"`', async function(assert) {
@@ -457,7 +450,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
assert.equal(findAll('.ember-power-select-option').length, 1);
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'Nope');
+ assert.dom('.ember-power-select-option').hasText('Nope');
});
test('If there is a search action, the options are empty and the `seachMessage` in intentionally empty, it doesn\'t show anything, and if you seach and there is no results it shows the `noResultsMessage`', async function(assert) {
@@ -472,7 +465,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
assert.equal(findAll('.ember-power-select-option').length, 0);
typeInSearch('foo');
assert.equal(findAll('.ember-power-select-option').length, 1);
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found');
+ assert.dom('.ember-power-select-option').hasText('No results found');
});
test('The content of the dropdown when there are no options can be completely customized using the inverse block', async function(assert) {
@@ -485,7 +478,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
await clickTrigger();
- assert.notOk(find('.ember-power-select-option'), 'No list elements, just the given alternate block');
+ assert.dom('.ember-power-select-option').doesNotExist('No list elements, just the given alternate block');
assert.ok(find('.empty-option-foo'));
});
@@ -500,7 +493,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
assert.equal(findAll('.ember-power-select-option[aria-current="true"]').length, 1, 'One element is highlighted');
assert.equal(findAll('.ember-power-select-option')[0].attributes['aria-current'].value, 'true', 'The first one to be precise');
});
@@ -515,14 +508,14 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'three', 'The selected option show in the trigger');
+ assert.dom('.ember-power-select-trigger').hasText('three', 'The selected option show in the trigger');
await render(hbs`
{{#power-select selected="three" options=numbers onchange=(action (mut foo)) as |option|}}
Selected: {{option}}
{{/power-select}}
`);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'Selected: three', 'The selected option uses the same yielded block as the options');
+ assert.dom('.ember-power-select-trigger').hasText('Selected: three', 'The selected option uses the same yielded block as the options');
});
test('When `selected` option is provided, it is highlighted when the dropdown opens', async function(assert) {
@@ -599,7 +592,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
typeInSearch('on');
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found', 'No number ends in "on"');
+ assert.dom('.ember-power-select-option').hasText('No results found', 'No number ends in "on"');
typeInSearch('teen');
assert.equal(findAll('.ember-power-select-option').length, 7, 'There is 7 number that end in "teen"');
});
@@ -615,7 +608,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
assert.equal(findAll('.ember-power-select-option[aria-current="true"]').length, 1, 'One element is highlighted');
assert.equal(findAll('.ember-power-select-option')[0].attributes['aria-current'].value, 'true', 'The first one to be precise');
});
@@ -631,7 +624,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'ES: Spain', 'The selected country is rendered in the trigger');
+ assert.dom('.ember-power-select-trigger').hasText('ES: Spain', 'The selected country is rendered in the trigger');
});
test('When `selected` option is provided, it is highlighted when the dropdown opens', async function(assert) {
@@ -831,7 +824,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first element is highlighted');
assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing is selected yet');
+ assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
});
test('If the passed selected element is a resolved promise, that element is selected and the trigger contains the proper text', async function(assert) {
@@ -849,7 +842,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', 'The trigger has the proper content');
+ assert.dom('.ember-power-select-trigger').hasText('four', 'The trigger has the proper content');
});
test('If the passed selected element is a pending promise that resolves while the select is opened, the highlighted & selected elements get updated, along with the trigger', async function(assert) {
@@ -869,12 +862,12 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first element is highlighted');
assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing is selected yet');
+ assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
setTimeout(function() {
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', 'The trigger has the proper content');
+ assert.dom('.ember-power-select-trigger').hasText('four', 'The trigger has the proper content');
done();
}, 100);
});
@@ -907,13 +900,13 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first element is highlighted');
assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing is selected yet');
+ assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
return new RSVP.Promise(function(resolve) {
setTimeout(function() {
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'five', 'The 5th element is highlighted');
assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'five', 'The 5th element is highlighted');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'five', 'The trigger has the proper content');
+ assert.dom('.ember-power-select-trigger').hasText('five', 'The trigger has the proper content');
resolve();
}, 500);
});
@@ -940,16 +933,16 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
// await clickTrigger();
// assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
- // assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing is selected yet');
+ // assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
// setTimeout(function() {
- // assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', 'The trigger has the proper content');
+ // assert.dom('.ember-power-select-trigger').hasText('four', 'The trigger has the proper content');
// }, 20);
// setTimeout(function() {
// assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
// assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'four', 'The 4th element is selected');
- // assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', 'The trigger has the proper content');
+ // assert.dom('.ember-power-select-trigger').hasText('four', 'The trigger has the proper content');
// done();
// }, 220);
// });
@@ -978,17 +971,17 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
// await clickTrigger();
// assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
- // assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing is selected yet');
+ // assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
// setTimeout(function() {
- // assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'The trigger is still empty');
+ // assert.dom('.ember-power-select-trigger').hasText('', 'The trigger is still empty');
// assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The 1st element is highlighted');
// }, 100);
// setTimeout(function() {
// assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
// assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'four', 'The 4th element is selected');
- // assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'four', 'The trigger has the proper content');
+ // assert.dom('.ember-power-select-trigger').hasText('four', 'The trigger has the proper content');
// done();
// }, 350);
// });
@@ -1035,7 +1028,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is not rendered');
await clickTrigger();
assert.ok(find('#alternative-destination .ember-power-select-dropdown'), 'Dropdown is rendered inside the destination element');
@@ -1072,7 +1065,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'five', 'the given element is highlighted instead of the first, as usual');
});
@@ -1100,7 +1093,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'five', 'the given element is highlighted instead of the first, as usual');
});
@@ -1204,12 +1197,12 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'Toby', 'The first element is highlighted');
assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing is selected yet');
+ assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
await this.mainUser.bestie;
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'Lucius', 'The 4th element is highlighted');
assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'Lucius', 'The 4th element is highlighted');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'Lucius', 'The trigger has the proper content');
+ assert.dom('.ember-power-select-trigger').hasText('Lucius', 'The trigger has the proper content');
});
test('If the options change and the new value is PromiseArrayProxy, the content of that proxy is set immediately while the promise resolves', async function(assert) {
@@ -1231,7 +1224,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await click('#refresh-collection-btn');
await clickTrigger();
- assert.equal(findAll('.ember-power-select-option').length, 1);
- assert.ok(find('.ember-power-select-option').classList.contains('ember-power-select-option--loading-message'));
+ assert.dom('.ember-power-select-option').exists({ count: 1 });
+ assert.dom('.ember-power-select-option').hasClass('ember-power-select-option--loading-message');
});
});
From d9e0d4c4a8becbf0fa93124d140ef013c7742970 Mon Sep 17 00:00:00 2001
From: Donald Wasserman
Date: Thu, 19 Apr 2018 17:47:20 -0400
Subject: [PATCH 16/34] fixes #1094 (#1097)
---
addon/components/power-select.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/addon/components/power-select.js b/addon/components/power-select.js
index 865990c10..81219e204 100644
--- a/addon/components/power-select.js
+++ b/addon/components/power-select.js
@@ -138,7 +138,7 @@ export default Component.extend({
return null;
},
set(_, selected) {
- if (selected && selected.then) {
+ if (selected && get(selected, 'then')) {
this.get('_updateSelectedTask').perform(selected);
} else {
scheduleOnce('actions', this, this.updateSelection, selected);
From 3d94c68269ebd6b49da8303ee147f73626ba172f Mon Sep 17 00:00:00 2001
From: Miguel Camba
Date: Thu, 19 Apr 2018 23:48:00 +0200
Subject: [PATCH 17/34] qunit-dom is almost everywhere (#1096)
---
.../power-select/general-behaviour-test.js | 221 ++++++++----------
.../power-select/keyboard-control-test.js | 200 ++++++++--------
2 files changed, 201 insertions(+), 220 deletions(-)
diff --git a/tests/integration/components/power-select/general-behaviour-test.js b/tests/integration/components/power-select/general-behaviour-test.js
index dc08f6e79..d71c95ccd 100644
--- a/tests/integration/components/power-select/general-behaviour-test.js
+++ b/tests/integration/components/power-select/general-behaviour-test.js
@@ -10,7 +10,6 @@ import { run } from '@ember/runloop';
import { numbers, names, countries } from '../constants';
import PromiseProxyMixin from '@ember/object/promise-proxy-mixin';
import ArrayProxy from '@ember/array/proxy';
-import { find, findAll } from 'ember-native-dom-helpers';
const PromiseArrayProxy = ArrayProxy.extend(PromiseProxyMixin);
@@ -307,7 +306,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
typeInSearch('o');
setTimeout(function() {
- assert.equal(findAll('.ember-power-select-option').length, 1, 'The dropdown is opened and results shown after proxy is updated');
+ assert.dom('.ember-power-select-option').exists({ count: 1 }, 'The dropdown is opened and results shown after proxy is updated');
assert.dom('.ember-power-select-option').hasText('one');
done();
}, 150);
@@ -334,15 +333,15 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
- assert.ok(find('.ember-power-select-option'), 'The dropdown is opened and results shown with initial proxy contents');
+ assert.dom('.ember-power-select-option').exists('The dropdown is opened and results shown with initial proxy contents');
assert.dom('.ember-power-select-option').hasText('one');
typeInSearch('o');
setTimeout(function() {
- assert.equal(findAll('.ember-power-select-option').length, 2, 'The dropdown is opened and results shown after proxy is updated');
- assert.equal(findAll('.ember-power-select-option')[0].textContent.trim(), 'one');
- assert.equal(findAll('.ember-power-select-option')[1].textContent.trim(), 'owner');
+ assert.dom('.ember-power-select-option').exists({ count: 2 }, 'The dropdown is opened and results shown after proxy is updated');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('one');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('owner');
done();
}, 150);
});
@@ -358,9 +357,9 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'two', 'The second options is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('two', 'The second options is highlighted');
run(() => this.set('numbers', ['foo', 'bar', 'baz']));
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'foo', 'The first element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('foo', 'The first element is highlighted');
});
test('If the user passes `dropdownClass` the dropdown content should have that class', async function(assert) {
@@ -373,7 +372,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown').classList.contains('this-is-a-test-class'), 'dropdownClass can be customized');
+ assert.dom('.ember-power-select-dropdown').hasClass('this-is-a-test-class', 'dropdownClass can be customized');
});
test('The filtering is reverted after closing the select', async function(assert) {
@@ -388,10 +387,10 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
await typeInSearch('th');
- assert.equal(findAll('.ember-power-select-option').length, 2, 'the dropdown has filtered the results');
+ assert.dom('.ember-power-select-option').exists({ count: 2 }, 'the dropdown has filtered the results');
await triggerEvent('#outside-div', 'mousedown');
await clickTrigger();
- assert.equal(findAll('.ember-power-select-option').length, numbers.length, 'the dropdown has shows all results');
+ assert.dom('.ember-power-select-option').exists({ count: numbers.length }, 'the dropdown has shows all results');
});
test('The publicAPI is yielded as second argument in single selects', async function(assert) {
@@ -405,8 +404,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
typeInSearch('tw');
- assert.equal(findAll('.ember-power-select-option')[0].textContent.trim(), 'tw:two', 'Each option receives the public API');
- await click(findAll('.ember-power-select-option')[0]);
+ assert.dom('.ember-power-select-option').hasText('tw:two', 'Each option receives the public API');
+ await click('.ember-power-select-option');
await clickTrigger();
typeInSearch('thr');
assert.dom('.ember-power-select-trigger').hasText('thr:two', 'The trigger also receives the public API');
@@ -420,7 +419,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
await clickTrigger();
- assert.equal(findAll('.ember-power-select-option').length, 1);
+ assert.dom('.ember-power-select-option').exists({ count: 1 });
assert.dom('.ember-power-select-option').hasText('No results found');
assert.dom('.ember-power-select-option').hasClass('ember-power-select-option--no-matches-message', 'The row has a special class to differentiate it from regular options');
});
@@ -434,10 +433,10 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
await clickTrigger();
- assert.equal(findAll('.ember-power-select-option').length, 1);
+ assert.dom('.ember-power-select-option').exists({ count: 1 });
assert.dom('.ember-power-select-option').hasText('Type to search');
typeInSearch('foo');
- assert.equal(findAll('.ember-power-select-option').length, 1);
+ assert.dom('.ember-power-select-option').exists({ count: 1 });
assert.dom('.ember-power-select-option').hasText('No results found');
});
@@ -449,7 +448,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
await clickTrigger();
- assert.equal(findAll('.ember-power-select-option').length, 1);
+ assert.dom('.ember-power-select-option').exists({ count: 1 });
assert.dom('.ember-power-select-option').hasText('Nope');
});
@@ -462,9 +461,9 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
await clickTrigger();
- assert.equal(findAll('.ember-power-select-option').length, 0);
+ assert.dom('.ember-power-select-option').exists({ count: 0 });
typeInSearch('foo');
- assert.equal(findAll('.ember-power-select-option').length, 1);
+ assert.dom('.ember-power-select-option').exists({ count: 1 });
assert.dom('.ember-power-select-option').hasText('No results found');
});
@@ -479,7 +478,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
assert.dom('.ember-power-select-option').doesNotExist('No list elements, just the given alternate block');
- assert.ok(find('.empty-option-foo'));
+ assert.dom('.empty-option-foo').exists();
});
test('When no `selected` is provided, the first item in the dropdown is highlighted', async function(assert) {
@@ -494,8 +493,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
- assert.equal(findAll('.ember-power-select-option[aria-current="true"]').length, 1, 'One element is highlighted');
- assert.equal(findAll('.ember-power-select-option')[0].attributes['aria-current'].value, 'true', 'The first one to be precise');
+ assert.dom('.ember-power-select-option[aria-current="true"]').exists({ count: 1 }, 'One element is highlighted');
+ assert.dom('.ember-power-select-option').hasAttribute('aria-current', 'true', 'The first one to be precise');
});
test('When `selected` option is provided, it appears in the trigger yielded with the same block as the options', async function(assert) {
@@ -529,9 +528,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- let highlightedOption = find('.ember-power-select-option[aria-current="true"]');
- assert.ok(highlightedOption, 'One element is highlighted');
- assert.equal(highlightedOption.textContent.trim(), 'three', 'The third option is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').exists({ count: 1}, 'One element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('three', 'The third option is highlighted');
});
test('When `selected` option is provided, that option is marked as `.selected`', async function(assert) {
@@ -545,8 +543,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- let selectedOption = findAll('.ember-power-select-option')[2];
- assert.equal(selectedOption.attributes['aria-selected'].value, 'true', 'The third option is marked as selected');
+ assert.dom('.ember-power-select-option:nth-child(3)').hasAttribute('aria-selected', 'true', 'The third option is marked as selected');
});
test('The default search strategy matches disregarding diacritics differences and capitalization', async function(assert) {
@@ -561,19 +558,16 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
typeInSearch('mar');
- let options = findAll('.ember-power-select-option');
- assert.equal(options.length, 2, 'Only 2 results match the search');
- assert.equal(options[0].textContent.trim(), 'MarÃa');
- assert.equal(options[1].textContent.trim(), 'Marta');
+ assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only 2 results match the search');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('MarÃa');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('Marta');
typeInSearch('mari');
- options = findAll('.ember-power-select-option');
- assert.equal(options.length, 1, 'Only 1 results match the search');
- assert.equal(options[0].textContent.trim(), 'MarÃa');
+ assert.dom('.ember-power-select-option').exists({ count: 1 }, 'Only 1 results match the search');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('MarÃa');
typeInSearch('o');
- options = findAll('.ember-power-select-option');
- assert.equal(options.length, 2, 'Only 2 results match the search');
- assert.equal(options[0].textContent.trim(), 'Søren Larsen');
- assert.equal(options[1].textContent.trim(), 'João');
+ assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only 2 results match the search');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('Søren Larsen');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('João');
});
test('You can pass a custom marcher with `matcher=myFn` to customize the search strategy', async function(assert) {
@@ -594,7 +588,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
typeInSearch('on');
assert.dom('.ember-power-select-option').hasText('No results found', 'No number ends in "on"');
typeInSearch('teen');
- assert.equal(findAll('.ember-power-select-option').length, 7, 'There is 7 number that end in "teen"');
+ assert.dom('.ember-power-select-option').exists({ count: 7 }, 'There is 7 number that end in "teen"');
});
test('When no `selected` is provided, the first item in the dropdown is highlighted', async function(assert) {
@@ -609,8 +603,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
- assert.equal(findAll('.ember-power-select-option[aria-current="true"]').length, 1, 'One element is highlighted');
- assert.equal(findAll('.ember-power-select-option')[0].attributes['aria-current'].value, 'true', 'The first one to be precise');
+ assert.dom('.ember-power-select-option[aria-current="true"]').exists({ count: 1 }, 'One element is highlighted');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasAttribute('aria-current', 'true', 'The first one to be precise');
});
test('When a option is provided that options is rendered in the trigger using the same block as the options', async function(assert) {
@@ -639,9 +633,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- let highlightedOption = find('.ember-power-select-option[aria-current="true"]');
- assert.ok(highlightedOption, 'One element is highlighted');
- assert.equal(highlightedOption.textContent.trim(), 'ES: Spain', 'The second option is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').exists('One element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('ES: Spain', 'The second option is highlighted');
});
test('When `selected` option (object) is provided, that option is marked as `.selected`', async function(assert) {
@@ -657,7 +650,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
let selectedOption = findContains('.ember-power-select-option', 'ES: Spain');
- assert.equal(selectedOption.attributes['aria-selected'].value, 'true', 'The second option is marked as selected');
+ assert.dom(selectedOption).hasAttribute('aria-selected', 'true', 'The second option is marked as selected');
});
test('The default search strategy matches disregarding diacritics differences and capitalization', async function(assert) {
@@ -680,19 +673,16 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
typeInSearch('mar');
- let options = findAll('.ember-power-select-option');
- assert.equal(options.length, 2, 'Only 2 results match the search');
- assert.equal(options[0].textContent.trim(), 'MarÃa Murray');
- assert.equal(options[1].textContent.trim(), 'Marta Stinson');
+ assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only 2 results match the search');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('MarÃa Murray');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('Marta Stinson');
typeInSearch('mari');
- options = findAll('.ember-power-select-option');
- assert.equal(options.length, 1, 'Only 1 results match the search');
- assert.equal(options[0].textContent.trim(), 'MarÃa Murray');
+ assert.dom('.ember-power-select-option').exists({ count: 1 }, 'Only 1 results match the search');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('MarÃa Murray');
typeInSearch('o');
- options = findAll('.ember-power-select-option');
- assert.equal(options.length, 2, 'Only 2 results match the search');
- assert.equal(options[0].textContent.trim(), 'Søren Williams');
- assert.equal(options[1].textContent.trim(), 'João Jin');
+ assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only 2 results match the search');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('Søren Williams');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('João Jin');
});
test('You can pass a custom marcher with `matcher=myFn` to customize the search strategy', async function(assert) {
@@ -719,11 +709,10 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
typeInSearch('s');
- let options = findAll('.ember-power-select-option');
- assert.equal(options.length, 3, 'Only 3 results match the search');
- assert.equal(options[0].textContent.trim(), 'Søren Williams');
- assert.equal(options[1].textContent.trim(), 'Marta Stinson');
- assert.equal(options[2].textContent.trim(), 'Lisa Simpson');
+ assert.dom('.ember-power-select-option').exists({ count: 3 }, 'Only 3 results match the search');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('Søren Williams');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('Marta Stinson');
+ assert.dom('.ember-power-select-option:nth-child(3)').hasText('Lisa Simpson');
});
test('BUGFIX: The highlighted element is reset when single selects are closed', async function(assert) {
@@ -738,12 +727,12 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'three', 'The third element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('three', 'The third element is highlighted');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The forth element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('four', 'The forth element is highlighted');
await clickTrigger();
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'three', 'The third element is highlighted again');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('three', 'The third element is highlighted again');
});
test('BUGFIX: The highlighted element is reset when multiple selects are closed', async function(assert) {
@@ -757,12 +746,12 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one', 'The first element is highlighted');
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 40);
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'two', 'The second element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('two', 'The second element is highlighted');
await clickTrigger();
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first element is highlighted again');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one', 'The first element is highlighted again');
});
test('If the passed options is a promise that is resolved, searching should filter the results from a promise', async function(assert) {
@@ -785,12 +774,11 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
clickTrigger();
typeInSearch('o');
- let options = findAll('.ember-power-select-option');
- assert.equal(options.length, 4, 'The dropdown is opened and results shown.');
- assert.equal(options[0].textContent.trim(), 'one');
- assert.equal(options[1].textContent.trim(), 'two');
- assert.equal(options[2].textContent.trim(), 'four');
- assert.equal(options[3].textContent.trim(), 'fourteen');
+ assert.dom('.ember-power-select-option').exists({ count: 4 }, 'The dropdown is opened and results shown.');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('one');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('two');
+ assert.dom('.ember-power-select-option:nth-child(3)').hasText('four');
+ assert.dom('.ember-power-select-option:nth-child(4)').hasText('fourteen');
done();
}, 150);
});
@@ -806,7 +794,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- assert.notOk(find('ember-power-select-clear-btn'), 'There is no clear button');
+ assert.dom('ember-power-select-clear-btn').doesNotExist('There is no clear button');
});
test('If the passed selected element is a pending promise, the first element is highlighted and the trigger is empty', async function(assert) {
@@ -822,8 +810,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
run.later(resolve, numbers[3], 50);
}));
clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first element is highlighted');
- assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one', 'The first element is highlighted');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').doesNotExist('no element is selected');
assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
});
@@ -840,8 +828,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
- assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('four', 'The 4th element is highlighted');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').hasText('four', 'The 4th element is highlighted');
assert.dom('.ember-power-select-trigger').hasText('four', 'The trigger has the proper content');
});
@@ -860,13 +848,13 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
}));
clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first element is highlighted');
- assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one', 'The first element is highlighted');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').doesNotExist('no element is selected');
assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
setTimeout(function() {
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
- assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('four', 'The 4th element is highlighted');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').hasText('four', 'The 4th element is highlighted');
assert.dom('.ember-power-select-trigger').hasText('four', 'The trigger has the proper content');
done();
}, 100);
@@ -898,14 +886,14 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first element is highlighted');
- assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one', 'The first element is highlighted');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').doesNotExist('no element is selected');
assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
return new RSVP.Promise(function(resolve) {
setTimeout(function() {
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'five', 'The 5th element is highlighted');
- assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'five', 'The 5th element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('five', 'The 5th element is highlighted');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').hasText('five', 'The 5th element is highlighted');
assert.dom('.ember-power-select-trigger').hasText('five', 'The trigger has the proper content');
resolve();
}, 500);
@@ -932,7 +920,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
// await clickTrigger();
- // assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
+ // assert.dom('.ember-power-select-option[aria-selected="true"]').doesNotExist('no element is selected');
// assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
// setTimeout(function() {
@@ -940,8 +928,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
// }, 20);
// setTimeout(function() {
- // assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
- // assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'four', 'The 4th element is selected');
+ // assert.dom('.ember-power-select-option[aria-current="true"]').hasText('four', 'The 4th element is highlighted');
+ // assert.dom('.ember-power-select-option[aria-selected="true"]').hasText('four', 'The 4th element is selected');
// assert.dom('.ember-power-select-trigger').hasText('four', 'The trigger has the proper content');
// done();
// }, 220);
@@ -970,17 +958,17 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
// await clickTrigger();
- // assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
+ // assert.dom('.ember-power-select-option[aria-selected="true"]').doesNotExist('no element is selected');
// assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
// setTimeout(function() {
// assert.dom('.ember-power-select-trigger').hasText('', 'The trigger is still empty');
- // assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The 1st element is highlighted');
+ // assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one', 'The 1st element is highlighted');
// }, 100);
// setTimeout(function() {
- // assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The 4th element is highlighted');
- // assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'four', 'The 4th element is selected');
+ // assert.dom('.ember-power-select-option[aria-current="true"]').hasText('four', 'The 4th element is highlighted');
+ // assert.dom('.ember-power-select-option[aria-selected="true"]').hasText('four', 'The 4th element is selected');
// assert.dom('.ember-power-select-trigger').hasText('four', 'The trigger has the proper content');
// done();
// }, 350);
@@ -996,10 +984,10 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- assert.ok(!find('.ember-power-select-trigger').classList.contains('ember-power-select-trigger--active'), 'The select doesn\'t have the class yet');
+ assert.dom('.ember-power-select-trigger').doesNotHaveClass('ember-power-select-trigger--active', 'The select doesn\'t have the class yet');
await clickTrigger();
focus('.ember-power-select-search-input');
- assert.ok(find('.ember-power-select-trigger').classList.contains('ember-power-select-trigger--active'), 'The select has the class now');
+ assert.dom('.ember-power-select-trigger').hasClass('ember-power-select-trigger--active', 'The select has the class now');
});
test('[BUGFIX] When the component opens, if the selected option is not visible the list is scrolled to make it visible', async function(assert) {
@@ -1013,8 +1001,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'nine');
- assert.ok(findAll('.ember-power-select-options')[0].scrollTop > 0, 'The list has scrolled');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('nine');
+ assert.ok(document.querySelector('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
});
test('The destination where the content is rendered can be customized by passing a `destination=id-of-the-destination`', async function(assert) {
@@ -1031,7 +1019,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is not rendered');
await clickTrigger();
- assert.ok(find('#alternative-destination .ember-power-select-dropdown'), 'Dropdown is rendered inside the destination element');
+ assert.dom('#alternative-destination .ember-power-select-dropdown').exists('Dropdown is rendered inside the destination element');
});
test('[BUGFIX] When the component is open and it has a `search` action, if options get updated the highlighted items is reset', async function(assert) {
@@ -1048,9 +1036,9 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'two');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('two');
run(() => this.set('numbers', ['one', 'three', 'five', 'seven', 'nine']));
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one');
});
test('the item that is highlighted by default can be customized passing a value to `defaultHighlighted`', async function(assert) {
@@ -1066,7 +1054,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
- assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'five', 'the given element is highlighted instead of the first, as usual');
+ assert.dom('.ember-power-select-option[aria-current=true]').hasText('five', 'the given element is highlighted instead of the first, as usual');
});
test('the item that is highlighted by default can be customized passing a function to `defaultHighlighted`', async function(assert) {
@@ -1094,7 +1082,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
- assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'five', 'the given element is highlighted instead of the first, as usual');
+ assert.dom('.ember-power-select-option[aria-current=true]').hasText('five', 'the given element is highlighted instead of the first, as usual');
});
test('If the options of a single select implement `isEqual`, that option is used to determine whether or not two items are the same', async function(assert) {
@@ -1125,12 +1113,11 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
typeInSearch('M');
- await click(findAll('.ember-power-select-option')[1]);
+ await click('.ember-power-select-option:nth-child(2)');
await clickTrigger();
typeInSearch('i');
- let firstOption = findAll('.ember-power-select-option')[0];
- assert.equal(firstOption.attributes['aria-selected'].value, 'true', 'The item in the list is marked as selected');
- await click(firstOption);
+ assert.dom('.ember-power-select-option:nth-child(1)').hasAttribute('aria-selected', 'true', 'The item in the list is marked as selected');
+ await click('.ember-power-select-option:nth-child(1)');
assert.equal(onChangeInvocationsCount, 1);
});
@@ -1165,18 +1152,16 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- let dropdownContent = find('.ember-power-select-dropdown');
- assert.ok(dropdownContent.classList.contains('ember-basic-dropdown-content--above'), 'The dropdown is above');
- assert.ok(dropdownContent.classList.contains('ember-basic-dropdown-content--right'), 'The dropdown is in the right');
- assert.equal(dropdownContent.attributes.style.value, 'top: 111px;right: 222px;', 'The style attribute is the expected one');
+ assert.dom('.ember-power-select-dropdown').hasClass('ember-basic-dropdown-content--above', 'The dropdown is above');
+ assert.dom('.ember-power-select-dropdown').hasClass('ember-basic-dropdown-content--right', 'The dropdown is in the right');
+ assert.dom('.ember-power-select-dropdown').hasAttribute('style', 'top: 111px;right: 222px;', 'The style attribute is the expected one');
await clickTrigger();
run(() => this.set('renderInPlace', true));
await clickTrigger();
- dropdownContent = find('.ember-power-select-dropdown');
- assert.ok(dropdownContent.classList.contains('ember-basic-dropdown-content--below'), 'The dropdown is below');
- assert.ok(dropdownContent.classList.contains('ember-basic-dropdown-content--left'), 'The dropdown is in the left');
- assert.equal(dropdownContent.attributes.style.value, 'top: 333px;right: 444px;', 'The style attribute is the expected one');
+ assert.dom('.ember-power-select-dropdown').hasClass('ember-basic-dropdown-content--below', 'The dropdown is below');
+ assert.dom('.ember-power-select-dropdown').hasClass('ember-basic-dropdown-content--left', 'The dropdown is in the left');
+ assert.dom('.ember-power-select-dropdown').hasAttribute('style', 'top: 333px;right: 444px;', 'The style attribute is the expected one');
});
test('The `selected` option can be a thenable', async function(assert) {
@@ -1195,13 +1180,13 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
}));
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'Toby', 'The first element is highlighted');
- assert.notOk(find('.ember-power-select-option[aria-selected="true"]'), 'no element is selected');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('Toby', 'The first element is highlighted');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').doesNotExist('no element is selected');
assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
await this.mainUser.bestie;
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'Lucius', 'The 4th element is highlighted');
- assert.equal(find('.ember-power-select-option[aria-selected="true"]').textContent.trim(), 'Lucius', 'The 4th element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('Lucius', 'The 4th element is highlighted');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').hasText('Lucius', 'The 4th element is highlighted');
assert.dom('.ember-power-select-trigger').hasText('Lucius', 'The trigger has the proper content');
});
diff --git a/tests/integration/components/power-select/keyboard-control-test.js b/tests/integration/components/power-select/keyboard-control-test.js
index 53c4166bc..422a87eb7 100644
--- a/tests/integration/components/power-select/keyboard-control-test.js
+++ b/tests/integration/components/power-select/keyboard-control-test.js
@@ -21,9 +21,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'two', 'The next options is highlighted now');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('two', 'The next options is highlighted now');
});
test('Pressing keyup highlights the previous option', async function(assert) {
@@ -37,9 +37,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'three');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('three');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 38);
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'two', 'The previous options is highlighted now');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('two', 'The previous options is highlighted now');
});
test('When the last option is highlighted, pressing keydown doesn\'t change the highlighted', async function(assert) {
@@ -54,9 +54,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'twenty');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('twenty');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'twenty', 'The last option is still the highlighted one');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('twenty', 'The last option is still the highlighted one');
});
test('When the first option is highlighted, pressing keyup doesn\'t change the highlighted', async function(assert) {
@@ -71,9 +71,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 38);
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first option is still the highlighted one');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one', 'The first option is still the highlighted one');
});
test('The arrow keys also scroll the list if the new highlighted element if it is outside of the viewport of the list', async function(assert) {
@@ -87,11 +87,11 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'seven');
- assert.equal(find('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('seven');
+ assert.equal(document.querySelector('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'eight', 'The next option is highlighted now');
- assert.ok(find('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('eight', 'The next option is highlighted now');
+ assert.ok(document.querySelector('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
});
test('Pressing ENTER selects the highlighted element, closes the dropdown and focuses the trigger', async function(assert) {
@@ -113,9 +113,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
await clickTrigger();
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'two', 'The highlighted element was selected');
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigger is focused');
+ assert.dom('.ember-power-select-trigger').hasText('two', 'The highlighted element was selected');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
+ assert.dom('.ember-power-select-trigger').isFocused('The trigger is focused');
});
test('Pressing ENTER on a single select with search disabled selects the highlighted element, closes the dropdown and focuses the trigger', async function(assert) {
@@ -137,9 +137,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
await clickTrigger();
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'two', 'The highlighted element was selected');
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigger is focused');
+ assert.dom('.ember-power-select-trigger').hasText('two', 'The highlighted element was selected');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
+ assert.dom('.ember-power-select-trigger').isFocused('The trigger is focused');
});
test('Pressing ENTER when there is no highlighted element, closes the dropdown and focuses the trigger without calling the onchange function', async function(assert) {
@@ -157,11 +157,11 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
await clickTrigger();
typeInSearch('asjdnah');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'two', 'Two is selected');
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found');
+ assert.dom('.ember-power-select-trigger').hasText('two', 'Two is selected');
+ assert.dom('.ember-power-select-option').hasText('No results found');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigger is focused');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
+ assert.dom('.ember-power-select-trigger').isFocused('The trigger is focused');
});
test('Pressing SPACE on a select without a searchbox selects the highlighted element, closes the dropdown and focuses the trigger without scrolling the page', async function(assert) {
@@ -184,9 +184,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
await clickTrigger();
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 32); // Space
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'two', 'The highlighted element was selected');
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigger is focused');
+ assert.dom('.ember-power-select-trigger').hasText('two', 'The highlighted element was selected');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
+ assert.dom('.ember-power-select-trigger').isFocused('The trigger is focused');
});
test('Pressing TAB closes the select WITHOUT selecting the highlighed element and focuses the trigger', async function(assert) {
@@ -202,9 +202,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
await clickTrigger();
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 9);
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'The highlighted element wasn\'t selected');
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigges is focused');
+ assert.dom('.ember-power-select-trigger').hasText('', 'The highlighted element wasn\'t selected');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
+ assert.dom('.ember-power-select-trigger').isFocused('The trigges is focused');
});
test('The component is focusable using the TAB key as any other kind of input', async function(assert) {
@@ -230,11 +230,11 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
focus('.ember-power-select-trigger');
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed again');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed again');
});
test('If the single component is focused and has no search, pressing SPACE toggles it', async function(assert) {
@@ -248,11 +248,11 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
focus('.ember-power-select-trigger');
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 32);
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 32);
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed again');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed again');
});
test('If the single component is focused, pressing KEYDOWN opens it', async function(assert) {
@@ -266,9 +266,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
focus('.ember-power-select-trigger');
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
});
test('If the single component is focused, pressing KEYUP opens it', async function(assert) {
@@ -282,9 +282,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
focus('.ember-power-select-trigger');
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 38);
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
});
test('Pressing ESC while the component is opened closes it and focuses the trigger', async function(assert) {
@@ -298,10 +298,10 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 27);
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
- assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The select is focused');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
+ assert.dom('.ember-power-select-trigger').isFocused('The select is focused');
});
test('In single-mode, when the user presses a key being the search input focused the passes `onkeydown` action is invoked with the public API and the event', async function(assert) {
@@ -326,9 +326,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
});
test('In single-mode, when the user presses SPACE on the searchbox, the highlighted option is not selected, and that space is part of the search', async function(assert) {
@@ -353,10 +353,10 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 32);
- assert.ok(find('.ember-power-select-dropdown'), 'The select is still opened');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing was selected');
+ assert.dom('.ember-power-select-dropdown').exists('The select is still opened');
+ assert.dom('.ember-power-select-trigger').hasText('', 'Nothing was selected');
});
test('In multiple-mode, when the user presses SPACE on the searchbox, the highlighted option is not selected, and that space is part of the search', async function(assert) {
@@ -381,10 +381,10 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 32);
- assert.ok(find('.ember-power-select-dropdown'), 'The select is still opened');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), '', 'Nothing was selected');
+ assert.dom('.ember-power-select-dropdown').exists('The select is still opened');
+ assert.dom('.ember-power-select-trigger').hasText('', 'Nothing was selected');
});
test('in single-mode if the users returns false in the `onkeydown` action it prevents the component to do the usual thing', async function(assert) {
@@ -403,9 +403,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
- assert.ok(find('.ember-power-select-dropdown'), 'The select is still opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is still opened');
});
test('In multiple-mode, when the user presses a key being the search input focused the passes `onkeydown` action is invoked with the public API and the event', async function(assert) {
@@ -430,9 +430,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
});
test('in multiple-mode if the users returns false in the `onkeydown` action it prevents the component to do the usual thing', async function(assert) {
@@ -449,9 +449,9 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
- assert.ok(find('.ember-power-select-dropdown'), 'The select is still opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is still opened');
});
test('Typing on a closed single select selects the value that matches the string typed so far', async function(assert) {
@@ -464,14 +464,13 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
- await focus(trigger);
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- triggerKeyEvent(trigger, 'keydown', 78); // n
- triggerKeyEvent(trigger, 'keydown', 73); // i
- await triggerKeyEvent(trigger, 'keydown', 78); // n
- assert.equal(trigger.textContent.trim(), 'nine', '"nine" has been selected');
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
+ await focus('.ember-power-select-trigger');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
+ triggerKeyEvent('.ember-power-select-trigger', 'keydown', 78); // n
+ triggerKeyEvent('.ember-power-select-trigger', 'keydown', 73); // i
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 78); // n
+ assert.dom('.ember-power-select-trigger').hasText('nine', '"nine" has been selected');
+ assert.dom('.ember-power-select-dropdown').doesNotExist( 'The dropdown is still closed');
});
test('Typing with modifier keys on a closed single select does not select the value that matches the string typed so far', async function(assert) {
@@ -484,12 +483,11 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
- focus(trigger);
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- await triggerKeyEvent(trigger, 'keydown', 82, { ctrlKey: true }); // r
- assert.notEqual(trigger.textContent.trim(), 'three', '"three" is not selected');
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
+ focus('.ember-power-select-trigger');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 82, { ctrlKey: true }); // r
+ assert.dom('.ember-power-select-trigger').doesNotIncludeText('three', '"three" is not selected');
+ assert.dom('.ember-power-select-dropdown').doesNotExist( 'The dropdown is still closed');
});
//
@@ -509,17 +507,16 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
- assert.equal(find('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
- triggerKeydown(trigger, 78); // n
- triggerKeydown(trigger, 73); // i
- triggerKeydown(trigger, 78); // n
- assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
- assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'nine', 'The option containing "nine" has been highlighted');
- assert.ok(find('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is still open');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
+ assert.equal(document.querySelector('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
+ triggerKeydown('.ember-power-select-trigger', 78); // n
+ triggerKeydown('.ember-power-select-trigger', 73); // i
+ triggerKeydown('.ember-power-select-trigger', 78); // n
+ assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
+ assert.dom('.ember-power-select-option[aria-current=true]').hasText('nine', 'The option containing "nine" has been highlighted');
+ assert.ok(document.querySelector('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still open');
});
test('Typing from the Numpad on an opened single select highlights the first value that matches the string typed so far, scrolling if needed', async function(assert) {
@@ -532,15 +529,14 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
- assert.equal(find('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
- triggerKeydown(trigger, 104); // Numpad 8
- assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
- assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), '853', 'The option containing "853" has been highlighted');
- assert.ok(find('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
+ assert.equal(document.querySelector('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
+ triggerKeydown('.ember-power-select-trigger', 104); // Numpad 8
+ assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
+ assert.dom('.ember-power-select-option[aria-current=true]').hasText('853', 'The option containing "853" has been highlighted');
+ assert.ok(document.querySelector('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
});
test('Typing on an opened multiple select highlights the value that matches the string typed so far, scrolling if needed', async function(assert) {
@@ -555,15 +551,15 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
let trigger = find('.ember-power-select-trigger');
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
- assert.equal(find('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
+ assert.equal(document.querySelector('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
triggerKeydown(trigger, 78); // n
triggerKeydown(trigger, 73); // i
triggerKeydown(trigger, 78); // n
assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'nine', 'The option containing "nine" has been highlighted');
- assert.ok(find('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
+ assert.ok(document.querySelector('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
});
test('The typed string gets reset after 1s idle', async function(assert) {
@@ -579,15 +575,15 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
let trigger = find('.ember-power-select-trigger');
focus(trigger);
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist( 'The dropdown is closed');
triggerKeydown(trigger, 84); // t
triggerKeydown(trigger, 87); // w
assert.equal(trigger.textContent.trim(), 'two', '"two" has been selected');
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist( 'The dropdown is still closed');
setTimeout(function() {
triggerKeydown(trigger, 79); // o
assert.equal(trigger.textContent.trim(), 'one', '"one" has been selected, instead of "two", because the typing started over');
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist( 'The dropdown is still closed');
done();
}, 1100);
});
@@ -626,12 +622,12 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
let trigger = find('.ember-power-select-trigger');
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
triggerKeydown(trigger, 80); // p
triggerKeydown(trigger, 79); // o
assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'Portugal', 'The option containing "Portugal" has been highlighted');
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
});
test('Typing on an opened single select containing groups highlights the value that matches the string', async function(assert) {
@@ -646,12 +642,12 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
let trigger = find('.ember-power-select-trigger');
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
triggerKeydown(trigger, 69); // e
triggerKeydown(trigger, 76); // l
assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'eleven', 'The option containing "eleven" has been highlighted');
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
});
test('Typing on an opened single select highlights skips disabled options', async function(assert) {
@@ -667,11 +663,11 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
let trigger = find('.ember-power-select-trigger');
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
triggerKeydown(trigger, 85); // u
assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'United Kingdom', 'The option containing "United Kingdom" has been highlighted');
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
});
test('Typing on an opened single select highlights skips disabled groups', async function(assert) {
@@ -686,12 +682,12 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
let trigger = find('.ember-power-select-trigger');
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is open');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
triggerKeydown(trigger, 84); // t
triggerKeydown(trigger, 87); // w
assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'twelve', 'The option containing "United Kingdom" has been highlighted');
- assert.ok(find('.ember-power-select-dropdown'), 'The dropdown is still closed');
+ assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
});
test('BUGFIX: If pressing up/down arrow on a single select open the dropdown, the event is defaultPrevented', async function(assert) {
From f2364a8ca93bf658e26e25299e34d5501cb0fba2 Mon Sep 17 00:00:00 2001
From: cibernox
Date: Thu, 19 Apr 2018 23:51:06 +0200
Subject: [PATCH 18/34] v2.0.0-beta.4
---
CHANGELOG.md | 3 +++
package.json | 2 +-
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 3f1597287..2875ab0e0 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,8 @@
# Master
+# 2.0.0-beta.4
+- [BUGFIX] Fixes big un Ember 3.1 accessing the getter `selected.then`
+
# 2.0.0-beta.0
- [BREAKING] Remove long-time-deprecated behavior to support _some_ usages of the `:eq` pseudoselector from jQuery.
- [DEPRECATE] Deprecate global async test helpers: `selectChoose`, `selectSearch`, `removeMultipleOption`
diff --git a/package.json b/package.json
index ecf439ba1..539320689 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "ember-power-select",
- "version": "2.0.0-beta.3",
+ "version": "2.0.0-beta.4",
"description": "The extensible select component built for ember",
"keywords": [
"ember-addon",
From 6cb7f5a6a9d736bd702ce9f2083827faee0d77b5 Mon Sep 17 00:00:00 2001
From: cibernox
Date: Fri, 20 Apr 2018 12:32:10 +0200
Subject: [PATCH 19/34] Simplify tests a bit more
---
.../power-select/keyboard-control-test.js | 87 +++++++++----------
.../power-select/mouse-control-test.js | 77 ++++++++--------
2 files changed, 78 insertions(+), 86 deletions(-)
diff --git a/tests/integration/components/power-select/keyboard-control-test.js b/tests/integration/components/power-select/keyboard-control-test.js
index 422a87eb7..ac87433e1 100644
--- a/tests/integration/components/power-select/keyboard-control-test.js
+++ b/tests/integration/components/power-select/keyboard-control-test.js
@@ -5,7 +5,6 @@ import hbs from 'htmlbars-inline-precompile';
import { triggerKeydown, clickTrigger, typeInSearch } from 'ember-power-select/test-support/helpers';
import { numbers, numerals, countries, countriesWithDisabled, groupedNumbers, groupedNumbersWithDisabled } from '../constants';
import { triggerKeyEvent, focus } from '@ember/test-helpers';
-import { find } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (Keyboard control)', function(hooks) {
setupRenderingTest(hooks);
@@ -216,7 +215,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{option}}
{{/power-select}}
`);
- assert.equal(find('.ember-power-select-trigger').attributes.tabindex.value, '0', 'The trigger is reachable with TAB');
+ assert.dom('.ember-power-select-trigger').hasAttribute('tabindex', '0', 'The trigger is reachable with TAB');
});
test('If the component is focused, pressing ENTER toggles it', async function(assert) {
@@ -549,15 +548,14 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select-multiple}}
`);
- let trigger = find('.ember-power-select-trigger');
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
assert.equal(document.querySelector('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
- triggerKeydown(trigger, 78); // n
- triggerKeydown(trigger, 73); // i
- triggerKeydown(trigger, 78); // n
- assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
- assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'nine', 'The option containing "nine" has been highlighted');
+ triggerKeydown('.ember-power-select-trigger', 78); // n
+ triggerKeydown('.ember-power-select-trigger', 73); // i
+ triggerKeydown('.ember-power-select-trigger', 78); // n
+ assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
+ assert.dom('.ember-power-select-option[aria-current=true]').hasText('nine', 'The option containing "nine" has been highlighted');
assert.ok(document.querySelector('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
});
@@ -573,16 +571,15 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
- focus(trigger);
+ focus('.ember-power-select-trigger');
assert.dom('.ember-power-select-dropdown').doesNotExist( 'The dropdown is closed');
- triggerKeydown(trigger, 84); // t
- triggerKeydown(trigger, 87); // w
- assert.equal(trigger.textContent.trim(), 'two', '"two" has been selected');
+ triggerKeydown('.ember-power-select-trigger', 84); // t
+ triggerKeydown('.ember-power-select-trigger', 87); // w
+ assert.dom('.ember-power-select-trigger').hasText('two', '"two" has been selected');
assert.dom('.ember-power-select-dropdown').doesNotExist( 'The dropdown is still closed');
setTimeout(function() {
- triggerKeydown(trigger, 79); // o
- assert.equal(trigger.textContent.trim(), 'one', '"one" has been selected, instead of "two", because the typing started over');
+ triggerKeydown('.ember-power-select-trigger', 79); // o
+ assert.dom('.ember-power-select-trigger').hasText('one', '"one" has been selected, instead of "two", because the typing started over');
assert.dom('.ember-power-select-dropdown').doesNotExist( 'The dropdown is still closed');
done();
}, 1100);
@@ -598,16 +595,15 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
- focus(trigger);
- assert.equal(trigger.textContent.trim(), '', 'nothing is selected');
- triggerKeydown(trigger, 78); // n
- triggerKeydown(trigger, 73); // i
- triggerKeydown(trigger, 78); // n
- triggerKeydown(trigger, 69); // e
- assert.equal(trigger.textContent.trim(), 'nine', 'nine has been selected');
- triggerKeydown(trigger, 87); // w
- assert.equal(trigger.textContent.trim(), 'nine', 'nine is still selected because "ninew" gave no results');
+ focus('.ember-power-select-trigger');
+ assert.dom('.ember-power-select-trigger').hasText('', 'nothing is selected');
+ triggerKeydown('.ember-power-select-trigger', 78); // n
+ triggerKeydown('.ember-power-select-trigger', 73); // i
+ triggerKeydown('.ember-power-select-trigger', 78); // n
+ triggerKeydown('.ember-power-select-trigger', 69); // e
+ assert.dom('.ember-power-select-trigger').hasText('nine', 'nine has been selected');
+ triggerKeydown('.ember-power-select-trigger', 87); // w
+ assert.dom('.ember-power-select-trigger').hasText('nine', 'nine is still selected because "ninew" gave no results');
});
test('Typing on an opened single select highlights the value that matches the string, also when the options are complex, using the `searchField` for that', async function(assert) {
@@ -620,13 +616,12 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
- triggerKeydown(trigger, 80); // p
- triggerKeydown(trigger, 79); // o
- assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
- assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'Portugal', 'The option containing "Portugal" has been highlighted');
+ triggerKeydown('.ember-power-select-trigger', 80); // p
+ triggerKeydown('.ember-power-select-trigger', 79); // o
+ assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
+ assert.dom('.ember-power-select-option[aria-current=true]').hasText('Portugal', 'The option containing "Portugal" has been highlighted');
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
});
@@ -640,13 +635,12 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
- triggerKeydown(trigger, 69); // e
- triggerKeydown(trigger, 76); // l
- assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
- assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'eleven', 'The option containing "eleven" has been highlighted');
+ triggerKeydown('.ember-power-select-trigger', 69); // e
+ triggerKeydown('.ember-power-select-trigger', 76); // l
+ assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
+ assert.dom('.ember-power-select-option[aria-current=true]').hasText('eleven', 'The option containing "eleven" has been highlighted');
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
});
@@ -661,12 +655,11 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
- triggerKeydown(trigger, 85); // u
- assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
- assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'United Kingdom', 'The option containing "United Kingdom" has been highlighted');
+ triggerKeydown('.ember-power-select-trigger', 85); // u
+ assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
+ assert.dom('.ember-power-select-option[aria-current=true]').hasText('United Kingdom', 'The option containing "United Kingdom" has been highlighted');
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
});
@@ -680,13 +673,12 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
- triggerKeydown(trigger, 84); // t
- triggerKeydown(trigger, 87); // w
- assert.equal(trigger.textContent.trim(), '', 'nothing has been selected');
- assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'twelve', 'The option containing "United Kingdom" has been highlighted');
+ triggerKeydown('.ember-power-select-trigger', 84); // t
+ triggerKeydown('.ember-power-select-trigger', 87); // w
+ assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
+ assert.dom('.ember-power-select-option[aria-current=true]').hasText('twelve', 'The option containing "United Kingdom" has been highlighted');
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
});
@@ -818,11 +810,10 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{option.label}}
{{/power-select}}
`);
- let trigger = find('.ember-power-select-trigger');
- focus(trigger);
- assert.equal(find('.ember-power-select-selected-item').textContent.trim(), '25');
+ focus('.ember-power-select-trigger');
+ assert.dom('.ember-power-select-selected-item').hasText('25');
assert.expectAssertion(() => {
- triggerKeydown(trigger, 67); // c
+ triggerKeydown('.ember-power-select-trigger', 67); // c
}, '{{power-select}} If you want the default filtering to work on options that are not plain strings, you need to provide `searchField`');
});
});
diff --git a/tests/integration/components/power-select/mouse-control-test.js b/tests/integration/components/power-select/mouse-control-test.js
index 4187acc7c..41b454e5c 100644
--- a/tests/integration/components/power-select/mouse-control-test.js
+++ b/tests/integration/components/power-select/mouse-control-test.js
@@ -4,7 +4,8 @@ import { render } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { clickTrigger } from 'ember-power-select/test-support/helpers';
import { numbers } from '../constants';
-import { find, findAll, click, triggerEvent } from 'ember-native-dom-helpers';
+import { click, triggerEvent } from '@ember/test-helpers';
+import { find, findAll } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (Mouse control)', function(hooks) {
setupRenderingTest(hooks);
@@ -19,11 +20,11 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option').attributes['aria-current'].value, 'true', 'The first element is highlighted');
- triggerEvent(findAll('.ember-power-select-option')[3], 'mouseover');
- assert.equal(findAll('.ember-power-select-option')[3].attributes['aria-current'].value, 'true', 'The 4th element is highlighted');
- assert.equal(findAll('.ember-power-select-option')[3].textContent.trim(), 'four');
+ await triggerEvent('.ember-power-select-option:nth-child(4)', 'mouseover');
+ assert.dom('.ember-power-select-option:nth-child(4)').hasAttribute('aria-current', 'true', 'The 4th element is highlighted');
+ assert.dom('.ember-power-select-option:nth-child(4)').hasText('four');
});
test('Clicking an item selects it, closes the dropdown and focuses the trigger', async function(assert) {
@@ -40,10 +41,10 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
{{/power-select}}
`);
- clickTrigger();
- click(findAll('.ember-power-select-option')[3]);
- assert.notOk(find('.ember-power-select-dropdown'), 'The select was closed');
- assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigger is focused');
+ await clickTrigger();
+ await click('.ember-power-select-option:nth-child(4)');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select was closed');
+ assert.dom('.ember-power-select-trigger').isFocused();
});
test('Clicking the trigger while the select is opened closes it and and focuses the trigger', async function(assert) {
@@ -56,11 +57,11 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
{{/power-select}}
`);
- clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
- clickTrigger();
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
- assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigger is focused');
+ await clickTrigger();
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
+ await clickTrigger();
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
+ assert.dom('.ember-power-select-trigger').isFocused();
});
test('Doing mousedown the clear button removes the selection but does not open the select', async function(assert) {
@@ -79,11 +80,11 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
{{/power-select}}
`);
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
- assert.ok(/three/.test(find('.ember-power-select-trigger').textContent.trim()), 'A element is selected');
- click('.ember-power-select-clear-btn');
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is still closed');
- assert.ok(!/three/.test(find('.ember-power-select-trigger').textContent.trim()), 'That element is not selected now');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
+ assert.dom('.ember-power-select-trigger').includesText('three', 'A element is selected');
+ await click('.ember-power-select-clear-btn');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is still closed');
+ assert.dom('.ember-power-select-trigger').doesNotIncludeText('three', 'That element is not selected now');
});
test('Clicking anywhere outside the select while opened closes the component and doesn\'t focuses the trigger', async function(assert) {
@@ -97,11 +98,11 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
{{/power-select}}
`);
- clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
- click('#other-thing');
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
- assert.ok(find('.ember-power-select-trigger') !== document.activeElement, 'The select is not focused');
+ await clickTrigger();
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
+ await click('#other-thing');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
+ assert.dom('.ember-power-select-trigger').isNotFocused();
});
test('Doing mouseup over an option less than 2px in the Y axis of where the mousedown that opened the component was triggered doesn\'t select the option', async function(assert) {
@@ -114,12 +115,12 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
{{/power-select}}
`);
- clickTrigger(null, { clientY: 123 });
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
- triggerEvent(findAll('.ember-power-select-option')[1], 'mouseup', { clientY: 124 });
- assert.ok(find('.ember-power-select-dropdown'), 'The select is still opened');
- triggerEvent(findAll('.ember-power-select-option')[1], 'mouseup', { clientY: 125 });
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed now');
+ await clickTrigger(null, { clientY: 123 });
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
+ await triggerEvent(findAll('.ember-power-select-option')[1], 'mouseup', { clientY: 124 });
+ assert.dom('.ember-power-select-dropdown').exists('The select is still opened');
+ await triggerEvent(findAll('.ember-power-select-option')[1], 'mouseup', { clientY: 125 });
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed now');
assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'two', 'The element has been selected');
});
@@ -138,10 +139,10 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
{{/power-select}}
`);
- clickTrigger();
- click(findAll('.special-class')[3]);
- assert.notOk(find('.ember-power-select-dropdown'), 'The select was closed');
- assert.ok(find('.ember-power-select-trigger') === document.activeElement, 'The trigger is focused');
+ await clickTrigger();
+ await click(findAll('.special-class')[3]);
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select was closed');
+ assert.dom('.ember-power-select-trigger').isFocused();
});
test('Mouse-overing on a wrapped option should select it', async function(assert) {
@@ -155,9 +156,9 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first element is highlighted');
- triggerEvent(findAll('.special-class')[3], 'mouseover');
+ await triggerEvent(findAll('.special-class')[3], 'mouseover');
assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The fourth element is highlighted');
});
@@ -172,8 +173,8 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
{{/power-select}}
`);
- clickTrigger();
- triggerEvent('ul', 'mouseover');
+ await clickTrigger();
+ await triggerEvent('ul', 'mouseover');
});
});
From 06cbfa7b17d514c7bba1e6ec97dc17b16307e3d0 Mon Sep 17 00:00:00 2001
From: Miguel Camba
Date: Sun, 22 Apr 2018 15:14:42 +0200
Subject: [PATCH 20/34] Penultimate test refactor (#1098)
---
.../power-select/mouse-control-test.js | 19 ++-
.../components/power-select/multiple-test.js | 147 +++++++++---------
.../power-select/public-actions-test.js | 74 ++++-----
3 files changed, 117 insertions(+), 123 deletions(-)
diff --git a/tests/integration/components/power-select/mouse-control-test.js b/tests/integration/components/power-select/mouse-control-test.js
index 41b454e5c..5a2033dd9 100644
--- a/tests/integration/components/power-select/mouse-control-test.js
+++ b/tests/integration/components/power-select/mouse-control-test.js
@@ -5,7 +5,6 @@ import hbs from 'htmlbars-inline-precompile';
import { clickTrigger } from 'ember-power-select/test-support/helpers';
import { numbers } from '../constants';
import { click, triggerEvent } from '@ember/test-helpers';
-import { find, findAll } from 'ember-native-dom-helpers';
module('Integration | Component | Ember Power Select (Mouse control)', function(hooks) {
setupRenderingTest(hooks);
@@ -21,7 +20,7 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option').attributes['aria-current'].value, 'true', 'The first element is highlighted');
+ assert.dom('.ember-power-select-option').hasAttribute('aria-current', 'true', 'The first element is highlighted');
await triggerEvent('.ember-power-select-option:nth-child(4)', 'mouseover');
assert.dom('.ember-power-select-option:nth-child(4)').hasAttribute('aria-current', 'true', 'The 4th element is highlighted');
assert.dom('.ember-power-select-option:nth-child(4)').hasText('four');
@@ -54,7 +53,7 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
await render(hbs`
{{#power-select options=numbers onchange=(action (mut foo)) as |option|}}
{{option}}
- {{/power-select}}
+ {{/power-select}}f
`);
await clickTrigger();
@@ -117,11 +116,11 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
await clickTrigger(null, { clientY: 123 });
assert.dom('.ember-power-select-dropdown').exists('The select is opened');
- await triggerEvent(findAll('.ember-power-select-option')[1], 'mouseup', { clientY: 124 });
+ await triggerEvent('.ember-power-select-option:nth-child(2)', 'mouseup', { clientY: 124 });
assert.dom('.ember-power-select-dropdown').exists('The select is still opened');
- await triggerEvent(findAll('.ember-power-select-option')[1], 'mouseup', { clientY: 125 });
+ await triggerEvent('.ember-power-select-option:nth-child(2)', 'mouseup', { clientY: 125 });
assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed now');
- assert.equal(find('.ember-power-select-trigger').textContent.trim(), 'two', 'The element has been selected');
+ assert.dom('.ember-power-select-trigger').hasText('two', 'The element has been selected');
});
test('Clicking on a wrapped option should select it', async function(assert) {
@@ -140,7 +139,7 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
`);
await clickTrigger();
- await click(findAll('.special-class')[3]);
+ await click(document.querySelectorAll('.special-class')[3]);
assert.dom('.ember-power-select-dropdown').doesNotExist('The select was closed');
assert.dom('.ember-power-select-trigger').isFocused();
});
@@ -157,9 +156,9 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The first element is highlighted');
- await triggerEvent(findAll('.special-class')[3], 'mouseover');
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'four', 'The fourth element is highlighted');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one', 'The first element is highlighted');
+ await triggerEvent(document.querySelectorAll('.special-class')[3], 'mouseover');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('four', 'The fourth element is highlighted');
});
test('Mouse-overing the list itself doesn\'t crashes the app', async function(assert) {
diff --git a/tests/integration/components/power-select/multiple-test.js b/tests/integration/components/power-select/multiple-test.js
index c7fb32507..096b4d64a 100644
--- a/tests/integration/components/power-select/multiple-test.js
+++ b/tests/integration/components/power-select/multiple-test.js
@@ -4,7 +4,8 @@ import { render } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
import { numbers, names, countries, countriesWithDisabled } from '../constants';
-import { find, findAll, click, tap, keyEvent, focus } from 'ember-native-dom-helpers';
+import { click, tap, triggerKeyEvent, focus } from '@ember/test-helpers';
+import { find, findAll } from 'ember-native-dom-helpers';
import RSVP from 'rsvp';
import EmberObject, { get } from '@ember/object';
import { isEmpty } from '@ember/utils';
@@ -24,7 +25,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.notOk(find('.ember-power-select-search'), 'There is no search box');
});
@@ -38,7 +39,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-trigger-multiple-input') === document.activeElement, 'The search input is focused');
});
@@ -52,9 +53,9 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-trigger-multiple-input') === document.activeElement, 'The input of the trigger is focused');
- click(findAll('.ember-power-select-option')[1]);
+ await click(findAll('.ember-power-select-option')[1]);
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is 1 option selected');
assert.ok(/two/.test(find('.ember-power-select-multiple-option').textContent), 'The clicked element has been selected');
@@ -75,8 +76,8 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
- click(findAll('.ember-power-select-option')[1]);
+ await clickTrigger();
+ await click(findAll('.ember-power-select-option')[1]);
});
test('Click an option when there is already another selects both, and triggers the onchange action with them', async function(assert) {
@@ -96,8 +97,8 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is 1 option selected');
- clickTrigger();
- click(findAll('.ember-power-select-option')[1]);
+ await clickTrigger();
+ await click(findAll('.ember-power-select-option')[1]);
let selectedTriggerOptions = findAll('.ember-power-select-multiple-option');
assert.equal(selectedTriggerOptions.length, 2, 'There is 2 options selected');
assert.ok(/four/.test(selectedTriggerOptions[0].textContent), 'The first option is the provided one');
@@ -116,7 +117,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
let options = findAll('.ember-power-select-option');
assert.equal(options[1].attributes['aria-selected'].value, 'true', 'The second option is styled as selected');
assert.equal(options[3].attributes['aria-selected'].value, 'true', 'The 4th option is styled as selected');
@@ -134,7 +135,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(findAll('.ember-power-select-option[aria-current="true"]').length, 1, 'There is one element highlighted');
assert.equal(findAll('.ember-power-select-option[aria-selected="true"]').length, 1, 'There is one element selected');
assert.equal(findAll('.ember-power-select-option[aria-current="true"][aria-selected="true"]').length, 0, 'They are not the same');
@@ -158,8 +159,8 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is 1 option selected');
- clickTrigger();
- click('.ember-power-select-option[aria-selected="true"]');
+ await clickTrigger();
+ await click('.ember-power-select-option[aria-selected="true"]');
assert.equal(findAll('.ember-power-select-multiple-option').length, 0, 'There is no options selected');
});
@@ -173,7 +174,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('four');
assert.equal(findAll('.ember-power-select-option').length, 2, 'Only two items matched the criteria');
});
@@ -196,7 +197,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('mar');
let options = findAll('.ember-power-select-option');
assert.equal(options.length, 2, 'Only 2 results match the search');
@@ -226,7 +227,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('on');
assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found', 'No number ends in "on"');
typeInSearch('teen');
@@ -251,7 +252,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
setTimeout(function() {
@@ -270,11 +271,11 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 27);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 27);
assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
assert.ok(find('.ember-power-select-trigger-multiple-input') === document.activeElement, 'The trigger is focused');
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
});
@@ -291,7 +292,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
let trigger = find('.ember-power-select-trigger');
focus(trigger);
assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
- keyEvent(trigger, 'keydown', 13);
+ await triggerKeyEvent(trigger, 'keydown', 13);
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
});
@@ -309,9 +310,9 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 40);
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
assert.ok(/two/.test(find('.ember-power-select-trigger').textContent.trim()), 'The element was selected');
});
@@ -325,11 +326,11 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
let trigger = find('.ember-power-select-trigger');
- keyEvent(trigger, 'keydown', 40);
- keyEvent(trigger, 'keydown', 13);
+ await triggerKeyEvent(trigger, 'keydown', 40);
+ await triggerKeyEvent(trigger, 'keydown', 13);
assert.ok(/two/.test(find('.ember-power-select-trigger').textContent.trim()), 'The element was selected');
});
@@ -347,11 +348,11 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(findAll('.ember-power-select-multiple-option').length, 0, 'There is no elements selected');
let trigger = find('.ember-power-select-trigger');
- keyEvent(trigger, 'keydown', 40);
- keyEvent(trigger, 'keydown', 13);
+ await triggerKeyEvent(trigger, 'keydown', 40);
+ await triggerKeyEvent(trigger, 'keydown', 13);
assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is one element selected');
assert.ok(/two/.test(find('.ember-power-select-trigger').textContent.trim()), 'The element is "two"');
});
@@ -371,9 +372,9 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 40);
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
assert.ok(/two/.test(find('.ember-power-select-trigger').textContent.trim()), 'The element is still selected');
assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
assert.ok(find('.ember-power-select-trigger-multiple-input') === document.activeElement, 'The trigger is focused');
@@ -394,9 +395,9 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('four');
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 8);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 8);
assert.ok(find('.ember-power-select-dropdown'), 'The dropown is still opened');
});
@@ -418,7 +419,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
let input = find('.ember-power-select-trigger-multiple-input');
assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is one element selected');
- keyEvent(input, 'keydown', 8);
+ await triggerKeyEvent(input, 'keydown', 8);
assert.equal(findAll('.ember-power-select-multiple-option').length, 0, 'There is no elements selected');
assert.equal(find('.ember-power-select-trigger-multiple-input').value, 'two', 'The text of the seach input is two now');
assert.ok(find('.ember-power-select-dropdown'), 'The dropown has been opened');
@@ -442,9 +443,9 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{c.name}}
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(findAll('.ember-power-select-multiple-option').length, 2, 'There is two elements selected');
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 8);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 8);
assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is one element selected');
assert.equal(find('.ember-power-select-trigger-multiple-input').value, 'Latvia', 'The text of the seach input is two "Latvia"');
assert.ok(find('.ember-power-select-dropdown'), 'The dropown is still opened');
@@ -461,11 +462,11 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
click(findAll('.ember-power-select-option')[2]);
- clickTrigger();
+ await clickTrigger();
assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is one element selected');
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 8);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 8);
assert.equal(findAll('.ember-power-select-multiple-option').length, 0, 'There is no elements selected');
assert.equal(find('.ember-power-select-trigger-multiple-input').value, 'three', 'The text of the seach input is three now');
assert.ok(find('.ember-power-select-dropdown'), 'The dropown is still opened');
@@ -482,10 +483,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 27);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 27);
assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 40);
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
});
@@ -499,10 +500,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 27);
+ await clickTrigger();
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 27);
assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 38);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 38);
assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
});
@@ -517,8 +518,8 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, 'Select stuff here', 'There is a placeholder');
- clickTrigger();
- click(findAll('.ember-power-select-option')[1]);
+ await clickTrigger();
+ await click(findAll('.ember-power-select-option')[1]);
assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, '', 'The placeholder is gone');
});
@@ -533,8 +534,8 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
assert.equal(find('.ember-power-select-placeholder').textContent, 'Select stuff here', 'There is a placeholder');
- clickTrigger();
- click(findAll('.ember-power-select-option')[1]);
+ await clickTrigger();
+ await click(findAll('.ember-power-select-option')[1]);
assert.notOk(find('.ember-power-select-placeholder'), 'The placeholder is gone');
});
@@ -549,10 +550,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, '', 'Input does not have a placeholder');
- clickTrigger();
- click(findAll('.ember-power-select-option')[1]);
+ await clickTrigger();
+ await click(findAll('.ember-power-select-option')[1]);
assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, '', 'Input still does not have a placeholder');
- click('.ember-power-select-multiple-remove-btn');
+ await click('.ember-power-select-multiple-remove-btn');
assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, '', 'Input still does not have a placeholder');
});
@@ -564,10 +565,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{option}}
{{/power-select-multiple}}
`);
- clickTrigger();
- click(findAll('.ember-power-select-option')[1]);
+ await clickTrigger();
+ await click(findAll('.ember-power-select-option')[1]);
assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'Should add selected option');
- click('.ember-power-select-multiple-remove-btn');
+ await click('.ember-power-select-multiple-remove-btn');
assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, '', 'Input still does not have a placeholder');
assert.equal(findAll('.ember-power-select-multiple-option').length, 0, 'Should remove selected option');
});
@@ -580,10 +581,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{option}}
{{/power-select-multiple}}
`);
- clickTrigger();
- click(findAll('.ember-power-select-option')[1]);
+ await clickTrigger();
+ await click(findAll('.ember-power-select-option')[1]);
assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'Should add selected option');
- tap('.ember-power-select-multiple-remove-btn');
+ await tap('.ember-power-select-multiple-remove-btn');
assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, '', 'Input still does not have a placeholder');
assert.equal(findAll('.ember-power-select-multiple-option').length, 0, 'Should remove selected option');
});
@@ -637,11 +638,11 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('tw');
assert.equal(find('.ember-power-select-option').textContent.trim(), 'tw:two');
- click(findAll('.ember-power-select-option')[0]);
- clickTrigger();
+ await click(findAll('.ember-power-select-option')[0]);
+ await clickTrigger();
typeInSearch('thr');
assert.ok(/thr:two/.test(find('.ember-power-select-trigger').textContent.trim()), 'The trigger also receives the public API');
});
@@ -656,11 +657,11 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
Other div
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('asjdnah');
assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found');
assert.equal(find('.ember-power-select-trigger-multiple-input').value, 'asjdnah');
- click('#other-thing');
+ await click('#other-thing');
assert.equal(find('.ember-power-select-trigger-multiple-input').value, '');
});
@@ -676,10 +677,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('asjdnah');
assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found');
- keyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
assert.ok(find('.ember-power-select-trigger-multiple-input') === document.activeElement, 'The input is focused');
});
@@ -706,9 +707,9 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{option}}
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
run(() => this.get('selected').pushObject(numbers[3]));
- click(findAll('.ember-power-select-option')[0]);
+ await click(findAll('.ember-power-select-option')[0]);
assert.equal(findAll('.ember-power-select-multiple-option').length, 2, 'Two elements are selected');
});
@@ -723,7 +724,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
assert.ok(!find('.ember-power-select-trigger').classList.contains('ember-power-select-trigger--active'), 'The trigger does not have the class');
- clickTrigger();
+ await clickTrigger();
assert.ok(find('.ember-power-select-trigger').classList.contains('ember-power-select-trigger--active'), 'The trigger has the class');
assert.ok(find('.ember-power-select-dropdown').classList.contains('ember-power-select-dropdown--active'), 'The dropdown has the class');
});
@@ -779,7 +780,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'four', 'the given defaultHighlighted element is highlighted instead of the first, as usual');
});
@@ -804,10 +805,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
typeInSearch('M');
- click(findAll('.ember-power-select-option')[1]);
+ await click(findAll('.ember-power-select-option')[1]);
typeInSearch('Mi');
assert.equal(findAll('.ember-power-select-option')[0].attributes['aria-selected'].value, 'true', 'The item in the list is marked as selected');
- click(findAll('.ember-power-select-option')[0]); // select the same user again should i[0])t
+ await click(findAll('.ember-power-select-option')[0]); // select the same user again should i[0])t
assert.equal(findAll('.ember-power-select-multiple-option').length, 0);
});
diff --git a/tests/integration/components/power-select/public-actions-test.js b/tests/integration/components/power-select/public-actions-test.js
index f8cdb1672..63d09c8d1 100644
--- a/tests/integration/components/power-select/public-actions-test.js
+++ b/tests/integration/components/power-select/public-actions-test.js
@@ -4,7 +4,6 @@ import { render, click, triggerKeyEvent, focus } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { clickTrigger, typeInSearch } from 'ember-power-select/test-support/helpers';
import { numbers } from '../constants';
-import { find, findAll } from 'ember-native-dom-helpers';
import { run } from '@ember/runloop';
function assertPublicAPIShape(assert, select) {
@@ -126,9 +125,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
clickTrigger();
- let input = find('.ember-power-select-search-input');
- triggerKeyEvent(input, 'keydown', 13);
- triggerKeyEvent(input, 'keydown', 65);
+ triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
+ triggerKeyEvent('.ember-power-select-search-input', 'keydown', 65);
});
test('The onkeydown can be used to easily allow to select on tab', async function(assert) {
@@ -149,12 +147,11 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
clickTrigger();
- let trigger = find('.ember-power-select-trigger');
- await triggerKeyEvent(trigger, 'keydown', 40);
- await triggerKeyEvent(trigger, 'keydown', 40);
- await triggerKeyEvent(trigger, 'keydown', 9);
- assert.equal(trigger.textContent.trim(), 'three', 'The highlighted options has been selected');
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is opened');
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 9);
+ assert.dom('.ember-power-select-trigger').hasText('three', 'The highlighted options has been selected');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is opened');
});
test('The onkeydown of multiple selects action receives the public API and the keydown event', async function(assert) {
@@ -173,9 +170,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
clickTrigger();
- let input = find('.ember-power-select-trigger-multiple-input');
- triggerKeyEvent(input, 'keydown', 13);
- triggerKeyEvent(input, 'keydown', 65);
+ triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
+ triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 65);
});
test('returning false from the `onkeydown` action prevents the default behaviour in single selects', async function(assert) {
@@ -196,9 +192,9 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is still closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is still closed');
triggerKeyEvent('.ember-power-select-trigger', 'keydown', 84); // 't'
- assert.notEqual(find('.ember-power-select-trigger').textContent.trim(), 'two', 'nothing was selected');
+ assert.dom('.ember-power-select-trigger').doesNotIncludeText('two', 'nothing was selected');
});
test('returning false from the `onkeydown` action prevents the default behaviour in multiple selects', async function(assert) {
@@ -219,7 +215,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is still closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is still closed');
});
test('The onfocus of single selects action receives the public API and the focus event', async function(assert) {
@@ -352,7 +348,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is opened');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is opened');
});
test('returning false from the `onopen` action prevents the single select from opening', async function(assert) {
@@ -373,7 +369,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
clickTrigger();
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown didn\'t open');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown didn\'t open');
});
test('returning false from the `onopen` action prevents the multiple select from opening', async function(assert) {
@@ -394,7 +390,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
clickTrigger();
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown didn\'t open');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown didn\'t open');
});
test('the `onclose` action is invoked just before the dropdown closes', async function(assert) {
@@ -415,7 +411,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
clickTrigger();
clickTrigger();
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is closed');
});
test('returning false from the `onclose` action prevents the single select from closing', async function(assert) {
@@ -436,9 +432,9 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is open');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is open');
clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown didn\'t close');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown didn\'t close');
});
test('returning false from the `onclose` action prevents the multiple select from closing', async function(assert) {
@@ -459,9 +455,9 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is open');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is open');
clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown didn\'t close');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown didn\'t close');
});
test('the `oninput` action is invoked when the user modifies the text of the search input on single selects, and the search happens', async function(assert) {
@@ -483,11 +479,10 @@ module('Integration | Component | Ember Power Select (Public actions)', function
clickTrigger();
typeInSearch('tw');
- let options = findAll('.ember-power-select-option');
- assert.equal(options.length, 3, 'There is three options');
- assert.equal(options[0].textContent.trim(), 'two');
- assert.equal(options[1].textContent.trim(), 'twelve');
- assert.equal(options[2].textContent.trim(), 'twenty');
+ assert.dom('.ember-power-select-option').exists({ count: 3 }, 'There is three options');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('two');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('twelve');
+ assert.dom('.ember-power-select-option:nth-child(3)').hasText('twenty');
});
test('the `oninput` action is invoked when the user modifies the text of the search input on multiple selects, and the search happens', async function(assert) {
@@ -509,11 +504,10 @@ module('Integration | Component | Ember Power Select (Public actions)', function
clickTrigger();
typeInSearch('tw');
- let options = findAll('.ember-power-select-option');
- assert.equal(options.length, 3, 'There is three options');
- assert.equal(options[0].textContent.trim(), 'two');
- assert.equal(options[1].textContent.trim(), 'twelve');
- assert.equal(options[2].textContent.trim(), 'twenty');
+ assert.dom('.ember-power-select-option').exists({ count: 3 }, 'There is three options');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('two');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('twelve');
+ assert.dom('.ember-power-select-option:nth-child(3)').hasText('twenty');
});
test('if the `oninput` action of single selects returns false the search is cancelled', async function(assert) {
@@ -532,7 +526,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
clickTrigger();
typeInSearch('tw');
- assert.equal(findAll('.ember-power-select-option').length, 20, 'There is the same options than before');
+ assert.dom('.ember-power-select-option').exists({ count: 20 }, 'There is the same options than before');
});
test('if `oninput` action of multiple selects returns false the search is cancelled', async function(assert) {
@@ -551,7 +545,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
clickTrigger();
typeInSearch('tw');
- assert.equal(findAll('.ember-power-select-option').length, 20, 'There is the same options than before');
+ assert.dom('.ember-power-select-option').exists({ count: 20 }, 'There is the same options than before');
});
test('the `highlight` action of the public api passed to the public actions works as expected', async function(assert) {
@@ -566,8 +560,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
clickTrigger();
- assert.equal(findAll('.ember-power-select-option').length, 3, 'There is three options');
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'baz', 'The third option is highlighted');
+ assert.dom('.ember-power-select-option').exists({ count: 3 }, 'There is three options');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('baz', 'The third option is highlighted');
});
test('The programmer can use the received public API to perform searches in single selects', async function(assert) {
@@ -586,7 +580,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
clickTrigger();
- assert.equal(find('.ember-power-select-search-input').value, 'hello', 'The search text contains the searched string');
+ assert.dom('.ember-power-select-search-input').hasValue('hello', 'The search text contains the searched string');
});
test('The programmer can use the received public API to perform searches in mutiple selects', async function(assert) {
@@ -605,7 +599,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
clickTrigger();
- assert.equal(find('.ember-power-select-trigger-multiple-input').value, 'hello', 'The search text contains the searched string');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasValue('hello', 'The search text contains the searched string');
});
test('The search action of multiple selects has the searchText set to the up-to-date value', async function(assert) {
From d696c282ecb922b82e49d60ad246bd6439652af8 Mon Sep 17 00:00:00 2001
From: cibernox
Date: Sun, 22 Apr 2018 21:12:48 +0200
Subject: [PATCH 21/34] Remove all traces of find/findAll from
ember-native-dom-helpers
---
.../components/power-select/multiple-test.js | 254 +++++++++---------
1 file changed, 123 insertions(+), 131 deletions(-)
diff --git a/tests/integration/components/power-select/multiple-test.js b/tests/integration/components/power-select/multiple-test.js
index 096b4d64a..0078ebbc3 100644
--- a/tests/integration/components/power-select/multiple-test.js
+++ b/tests/integration/components/power-select/multiple-test.js
@@ -5,7 +5,6 @@ import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
import { numbers, names, countries, countriesWithDisabled } from '../constants';
import { click, tap, triggerKeyEvent, focus } from '@ember/test-helpers';
-import { find, findAll } from 'ember-native-dom-helpers';
import RSVP from 'rsvp';
import EmberObject, { get } from '@ember/object';
import { isEmpty } from '@ember/utils';
@@ -26,7 +25,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- assert.notOk(find('.ember-power-select-search'), 'There is no search box');
+ assert.dom('.ember-power-select-search').doesNotExist('There is no search box');
});
test('When the select opens, the search input in the trigger gets the focus', async function(assert) {
@@ -40,7 +39,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-trigger-multiple-input') === document.activeElement, 'The search input is focused');
+ assert.dom('.ember-power-select-trigger-multiple-input').isFocused();
});
test('Click on an element selects it and closes the dropdown and focuses the trigger\'s input', async function(assert) {
@@ -54,12 +53,12 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-trigger-multiple-input') === document.activeElement, 'The input of the trigger is focused');
- await click(findAll('.ember-power-select-option')[1]);
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is 1 option selected');
- assert.ok(/two/.test(find('.ember-power-select-multiple-option').textContent), 'The clicked element has been selected');
- assert.ok(find('.ember-power-select-trigger-multiple-input') === document.activeElement, 'The input of the trigger is focused again');
+ assert.dom('.ember-power-select-trigger-multiple-input').isFocused();
+ await click('.ember-power-select-option:nth-child(2)');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 1 }, 'There is 1 option selected');
+ assert.dom('.ember-power-select-multiple-option').includesText('two', 'The clicked element has been selected');
+ assert.dom('.ember-power-select-trigger-multiple-input').isFocused();
});
test('Selecting an element triggers the onchange action with the list of selected options', async function(assert) {
@@ -77,7 +76,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- await click(findAll('.ember-power-select-option')[1]);
+ await click('.ember-power-select-option:nth-child(2)');
});
test('Click an option when there is already another selects both, and triggers the onchange action with them', async function(assert) {
@@ -96,13 +95,12 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is 1 option selected');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 1 }, 'There is 1 option selected');
await clickTrigger();
- await click(findAll('.ember-power-select-option')[1]);
- let selectedTriggerOptions = findAll('.ember-power-select-multiple-option');
- assert.equal(selectedTriggerOptions.length, 2, 'There is 2 options selected');
- assert.ok(/four/.test(selectedTriggerOptions[0].textContent), 'The first option is the provided one');
- assert.ok(/two/.test(selectedTriggerOptions[1].textContent), 'The second option is the one just selected');
+ await click('.ember-power-select-option:nth-child(2)');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 2 }, 'There is 2 options selected');
+ assert.dom('.ember-power-select-multiple-option:nth-child(1)').includesText('four', 'The first option is the provided one');
+ assert.dom('.ember-power-select-multiple-option:nth-child(2)').includesText('two', 'The second option is the one just selected');
});
test('If there is many selections, all those options are styled as `selected`', async function(assert) {
@@ -118,9 +116,8 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- let options = findAll('.ember-power-select-option');
- assert.equal(options[1].attributes['aria-selected'].value, 'true', 'The second option is styled as selected');
- assert.equal(options[3].attributes['aria-selected'].value, 'true', 'The 4th option is styled as selected');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasAttribute('aria-selected', 'true', 'The second option is styled as selected');
+ assert.dom('.ember-power-select-option:nth-child(4)').hasAttribute('aria-selected', 'true', 'The 4th option is styled as selected');
});
test('When the popup opens, the first items is highlighed, even if there is only one selection', async function(assert) {
@@ -136,10 +133,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- assert.equal(findAll('.ember-power-select-option[aria-current="true"]').length, 1, 'There is one element highlighted');
- assert.equal(findAll('.ember-power-select-option[aria-selected="true"]').length, 1, 'There is one element selected');
- assert.equal(findAll('.ember-power-select-option[aria-current="true"][aria-selected="true"]').length, 0, 'They are not the same');
- assert.equal(find('.ember-power-select-option[aria-current="true"]').textContent.trim(), 'one', 'The highlighted element is the first one');
+ assert.dom('.ember-power-select-option[aria-current="true"]').exists({ count: 1 }, 'There is one element highlighted');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').exists({ count: 1 }, 'There is one element selected');
+ assert.dom('.ember-power-select-option[aria-current="true"][aria-selected="true"]').doesNotExist('They are not the same');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one', 'The highlighted element is the first one');
});
test('Clicking on an option that is already selected unselects it, closes the select and triggers the `onchange` action', async function(assert) {
@@ -158,10 +155,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is 1 option selected');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 1 }, 'There is 1 option selected');
await clickTrigger();
await click('.ember-power-select-option[aria-selected="true"]');
- assert.equal(findAll('.ember-power-select-multiple-option').length, 0, 'There is no options selected');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 0 }, 'There is no options selected');
});
test('The default filtering works in multiple mode', async function(assert) {
@@ -176,7 +173,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
await clickTrigger();
typeInSearch('four');
- assert.equal(findAll('.ember-power-select-option').length, 2, 'Only two items matched the criteria');
+ assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only two items matched the criteria');
});
test('The filtering specifying a searchkey works in multiple model', async function(assert) {
@@ -199,18 +196,16 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
await clickTrigger();
typeInSearch('mar');
- let options = findAll('.ember-power-select-option');
- assert.equal(options.length, 2, 'Only 2 results match the search');
- assert.equal(options[0].textContent.trim(), 'MarÃa Murray');
- assert.equal(options[1].textContent.trim(), 'Marta Stinson');
+ assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only 2 results match the search');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('MarÃa Murray');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('Marta Stinson');
typeInSearch('mari');
- assert.equal(findAll('.ember-power-select-option').length, 1, 'Only 1 results match the search');
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'MarÃa Murray');
+ assert.dom('.ember-power-select-option').exists({ count: 1 }, 'Only 1 results match the search');
+ assert.dom('.ember-power-select-option').hasText('MarÃa Murray');
typeInSearch('o');
- options = findAll('.ember-power-select-option');
- assert.equal(options.length, 2, 'Only 2 results match the search');
- assert.equal(options[0].textContent.trim(), 'Søren Williams');
- assert.equal(options[1].textContent.trim(), 'João Jin');
+ assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only 2 results match the search');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('Søren Williams');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('João Jin');
});
test('The filtering specifying a custom matcher works in multiple model', async function(assert) {
@@ -229,9 +224,9 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
await clickTrigger();
typeInSearch('on');
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found', 'No number ends in "on"');
+ assert.dom('.ember-power-select-option').hasText('No results found', 'No number ends in "on"');
typeInSearch('teen');
- assert.equal(findAll('.ember-power-select-option').length, 7, 'There is 7 number that end in "teen"');
+ assert.dom('.ember-power-select-option').exists({ count: 7 }, 'There is 7 number that end in "teen"');
});
test('The search using a custom action works int multiple mode', async function(assert) {
@@ -256,7 +251,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
typeInSearch('teen');
setTimeout(function() {
- assert.equal(findAll('.ember-power-select-option').length, 7);
+ assert.dom('.ember-power-select-option').exists({ count: 7 });
done();
}, 150);
});
@@ -273,10 +268,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
await clickTrigger();
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 27);
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
- assert.ok(find('.ember-power-select-trigger-multiple-input') === document.activeElement, 'The trigger is focused');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is not rendered');
+ assert.dom('.ember-power-select-trigger-multiple-input').isFocused();
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
});
test('Pressing ENTER on a multiple select with `searchEnabled=false` when it is closed opens it', async function(assert) {
@@ -289,11 +284,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- let trigger = find('.ember-power-select-trigger');
- focus(trigger);
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
- await triggerKeyEvent(trigger, 'keydown', 13);
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
+ await focus('.ember-power-select-trigger');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is not rendered');
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
});
test('Pressing ENTER over a highlighted element selects it', async function(assert) {
@@ -313,7 +307,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
await clickTrigger();
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 40);
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
- assert.ok(/two/.test(find('.ember-power-select-trigger').textContent.trim()), 'The element was selected');
+ assert.dom('.ember-power-select-trigger').includesText('two', 'The element was selected');
});
test('Pressing ENTER over a highlighted element on a multiple select with `searchEnabled=false` selects it', async function(assert) {
@@ -327,11 +321,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- assert.ok(find('.ember-power-select-dropdown'), 'Dropdown is rendered');
- let trigger = find('.ember-power-select-trigger');
- await triggerKeyEvent(trigger, 'keydown', 40);
- await triggerKeyEvent(trigger, 'keydown', 13);
- assert.ok(/two/.test(find('.ember-power-select-trigger').textContent.trim()), 'The element was selected');
+ assert.dom('.ember-power-select-dropdown').exists('Dropdown is rendered');
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
+ assert.dom('.ember-power-select-trigger').includesText('two', 'The element was selected');
});
test('Pressing ENTER over a highlighted element on a select with `searchEnabled=false` selects it', async function(assert) {
@@ -349,12 +342,11 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- assert.equal(findAll('.ember-power-select-multiple-option').length, 0, 'There is no elements selected');
- let trigger = find('.ember-power-select-trigger');
- await triggerKeyEvent(trigger, 'keydown', 40);
- await triggerKeyEvent(trigger, 'keydown', 13);
- assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is one element selected');
- assert.ok(/two/.test(find('.ember-power-select-trigger').textContent.trim()), 'The element is "two"');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 0 }, 'There is no elements selected');
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 1 }, 'There is one element selected');
+ assert.dom('.ember-power-select-trigger').includesText('two', 'The element was selected');
});
test('Pressing ENTER over a highlighted element what is already selected closes the select without doing anything and focuses the trigger', async function(assert) {
@@ -375,9 +367,9 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
await clickTrigger();
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 40);
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
- assert.ok(/two/.test(find('.ember-power-select-trigger').textContent.trim()), 'The element is still selected');
- assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
- assert.ok(find('.ember-power-select-trigger-multiple-input') === document.activeElement, 'The trigger is focused');
+ assert.dom('.ember-power-select-trigger').includesText('two', 'The element is still selected');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is not rendered');
+ assert.dom('.ember-power-select-trigger-multiple-input').isFocused();
});
test('Pressing BACKSPACE on the search input when there is text on it does nothing special', async function(assert) {
@@ -398,7 +390,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
await clickTrigger();
typeInSearch('four');
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 8);
- assert.ok(find('.ember-power-select-dropdown'), 'The dropown is still opened');
+ assert.dom('.ember-power-select-dropdown').exists('The dropown is still opened');
});
test('Pressing BACKSPACE on the search input when it\'s empty removes the last selection and performs a search for that text immediatly, opening the select if closed', async function(assert) {
@@ -417,13 +409,13 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- let input = find('.ember-power-select-trigger-multiple-input');
- assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is one element selected');
- await triggerKeyEvent(input, 'keydown', 8);
- assert.equal(findAll('.ember-power-select-multiple-option').length, 0, 'There is no elements selected');
- assert.equal(find('.ember-power-select-trigger-multiple-input').value, 'two', 'The text of the seach input is two now');
- assert.ok(find('.ember-power-select-dropdown'), 'The dropown has been opened');
- assert.equal(findAll('.ember-power-select-option').length, 1, 'The list has been filtered');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 1 }, 'There is one element selected');
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 8);
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 0 }, 'There is no elements selected');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasValue('two', 'The text of the seach input is two now');
+ assert.dom('.ember-power-select-dropdown').exists('The dropown has been opened');
+ assert.dom('.ember-power-select-option').exists({ count: 1 }, 'The list has been filtered');
+ let input = this.element.querySelector('.ember-power-select-trigger-multiple-input');
assert.equal(input.selectionStart, 3);
assert.equal(input.selectionEnd, 3);
});
@@ -444,12 +436,12 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
await clickTrigger();
- assert.equal(findAll('.ember-power-select-multiple-option').length, 2, 'There is two elements selected');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 2 }, 'There is two elements selected');
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 8);
- assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is one element selected');
- assert.equal(find('.ember-power-select-trigger-multiple-input').value, 'Latvia', 'The text of the seach input is two "Latvia"');
- assert.ok(find('.ember-power-select-dropdown'), 'The dropown is still opened');
- assert.equal(findAll('.ember-power-select-option').length, 1, 'The list has been filtered');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 1 }, 'There is one element selected');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasValue('Latvia', 'The text of the seach input is two "Latvia"');
+ assert.dom('.ember-power-select-dropdown').exists('The dropown is still opened');
+ assert.dom('.ember-power-select-option').exists({ count: 1 }, 'The list has been filtered');
});
test('Pressing BACKSPACE on the search input when it\'s empty removes the last selection ALSO when that option didn\'t come from the outside', async function(assert) {
@@ -463,14 +455,14 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- click(findAll('.ember-power-select-option')[2]);
+ await click('.ember-power-select-option:nth-child(3)');
await clickTrigger();
- assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'There is one element selected');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 1 }, 'There is one element selected');
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 8);
- assert.equal(findAll('.ember-power-select-multiple-option').length, 0, 'There is no elements selected');
- assert.equal(find('.ember-power-select-trigger-multiple-input').value, 'three', 'The text of the seach input is three now');
- assert.ok(find('.ember-power-select-dropdown'), 'The dropown is still opened');
- assert.equal(findAll('.ember-power-select-option').length, 1, 'The list has been filtered');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 0 }, 'There is no elements selected');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasValue('three', 'The text of the seach input is three now');
+ assert.dom('.ember-power-select-dropdown').exists('The dropown is still opened');
+ assert.dom('.ember-power-select-option').exists({ count: 1 }, 'The list has been filtered');
});
test('If the multiple component is focused, pressing KEYDOWN opens it', async function(assert) {
@@ -485,9 +477,9 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
await clickTrigger();
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 27);
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 40);
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
});
test('If the multiple component is focused, pressing KEYUP opens it', async function(assert) {
@@ -502,9 +494,9 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
await clickTrigger();
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 27);
- assert.notOk(find('.ember-power-select-dropdown'), 'The select is closed');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 38);
- assert.ok(find('.ember-power-select-dropdown'), 'The select is opened');
+ assert.dom('.ember-power-select-dropdown').exists('The select is opened');
});
test('The placeholder is only visible when no options are selected', async function(assert) {
@@ -517,10 +509,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, 'Select stuff here', 'There is a placeholder');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('placeholder', 'Select stuff here', 'There is a placeholder');
await clickTrigger();
- await click(findAll('.ember-power-select-option')[1]);
- assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, '', 'The placeholder is gone');
+ await click('.ember-power-select-option:nth-child(2)');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('placeholder', '', 'The placeholder is gone');
});
test('The placeholder is visible when no options are selected and search is disabled', async function(assert) {
@@ -533,10 +525,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- assert.equal(find('.ember-power-select-placeholder').textContent, 'Select stuff here', 'There is a placeholder');
+ assert.dom('.ember-power-select-placeholder').hasText('Select stuff here', 'There is a placeholder');
await clickTrigger();
- await click(findAll('.ember-power-select-option')[1]);
- assert.notOk(find('.ember-power-select-placeholder'), 'The placeholder is gone');
+ await click('.ember-power-select-option:nth-child(2)');
+ assert.dom('.ember-power-select-placeholder').doesNotExist('The placeholder is gone');
});
test('If the placeholder is null the placeholders shouldn\'t be "null" (issue #94)', async function(assert) {
@@ -549,12 +541,12 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, '', 'Input does not have a placeholder');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('placeholder', '', 'Input does not have a placeholder');
await clickTrigger();
- await click(findAll('.ember-power-select-option')[1]);
- assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, '', 'Input still does not have a placeholder');
+ await click('.ember-power-select-option:nth-child(2)');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('placeholder', '', 'Input still does not have a placeholder');
await click('.ember-power-select-multiple-remove-btn');
- assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, '', 'Input still does not have a placeholder');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('placeholder', '', 'Input still does not have a placeholder');
});
test('Selecting and removing should result in desired behavior', async function(assert) {
@@ -566,11 +558,11 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
await clickTrigger();
- await click(findAll('.ember-power-select-option')[1]);
- assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'Should add selected option');
+ await click('.ember-power-select-option:nth-child(2)');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 1 }, 'Should add selected option');
await click('.ember-power-select-multiple-remove-btn');
- assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, '', 'Input still does not have a placeholder');
- assert.equal(findAll('.ember-power-select-multiple-option').length, 0, 'Should remove selected option');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('placeholder', '', 'Input still does not have a placeholder');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 0 }, 'Should remove selected option');
});
test('Selecting and removing can also be done with touch events', async function(assert) {
@@ -582,11 +574,11 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
await clickTrigger();
- await click(findAll('.ember-power-select-option')[1]);
- assert.equal(findAll('.ember-power-select-multiple-option').length, 1, 'Should add selected option');
+ await click('.ember-power-select-option:nth-child(2)');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 1 }, 'Should add selected option');
await tap('.ember-power-select-multiple-remove-btn');
- assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.placeholder.value, '', 'Input still does not have a placeholder');
- assert.equal(findAll('.ember-power-select-multiple-option').length, 0, 'Should remove selected option');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('placeholder', '', 'Input still does not have a placeholder');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 0 }, 'Should remove selected option');
});
test('Typing in the input opens the component and filters the options', async function(assert) {
@@ -600,7 +592,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
typeInSearch('fo');
- assert.equal(findAll('.ember-power-select-option').length, 2, 'The dropdown is opened and results filtered');
+ assert.dom('.ember-power-select-option').exists({ count: 2 }, 'The dropdown is opened and results filtered');
});
test('Typing in the input opens the component and filters the options also with async searches', async function(assert) {
@@ -624,7 +616,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
let done = assert.async();
setTimeout(function() {
- assert.equal(findAll('.ember-power-select-option').length, 2, 'The dropdown is opened and results filtered');
+ assert.dom('.ember-power-select-option').exists({ count: 2 }, 'The dropdown is opened and results filtered');
done();
}, 150);
});
@@ -640,11 +632,11 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
await clickTrigger();
typeInSearch('tw');
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'tw:two');
- await click(findAll('.ember-power-select-option')[0]);
+ assert.dom('.ember-power-select-option').hasText('tw:two');
+ await click('.ember-power-select-option');
await clickTrigger();
typeInSearch('thr');
- assert.ok(/thr:two/.test(find('.ember-power-select-trigger').textContent.trim()), 'The trigger also receives the public API');
+ assert.dom('.ember-power-select-trigger').includesText('thr:two', 'The trigger also receives the public API');
});
test('The search input is cleared when the component is closed', async function(assert) {
@@ -659,10 +651,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
await clickTrigger();
typeInSearch('asjdnah');
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found');
- assert.equal(find('.ember-power-select-trigger-multiple-input').value, 'asjdnah');
+ assert.dom('.ember-power-select-option').hasText('No results found');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasValue('asjdnah');
await click('#other-thing');
- assert.equal(find('.ember-power-select-trigger-multiple-input').value, '');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasValue('');
});
test('When hitting ENTER after a search with no results, the component is closed but the onchange function is not invoked', async function(assert) {
@@ -679,10 +671,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
await clickTrigger();
typeInSearch('asjdnah');
- assert.equal(find('.ember-power-select-option').textContent.trim(), 'No results found');
+ assert.dom('.ember-power-select-option').hasText('No results found');
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
- assert.notOk(find('.ember-power-select-dropdown'), 'The dropdown is closed');
- assert.ok(find('.ember-power-select-trigger-multiple-input') === document.activeElement, 'The input is focused');
+ assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
+ assert.dom('.ember-power-select-trigger-multiple-input').isFocused();
});
test('The trigger of multiple selects have a special class to distinguish them from regular ones, even if you pass them another one', async function(assert) {
@@ -694,8 +686,8 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- assert.ok(find('.ember-power-select-trigger').classList.contains('ember-power-select-multiple-trigger'), 'The trigger has the default class');
- assert.ok(find('.ember-power-select-trigger').classList.contains('foobar-trigger'), 'The trigger has the given class');
+ assert.dom('.ember-power-select-trigger').hasClass('ember-power-select-multiple-trigger', 'The trigger has the default class');
+ assert.dom('.ember-power-select-trigger').hasClass('foobar-trigger', 'The trigger has the given class');
});
test('The component works when the array of selected elements is mutated in place instead of replaced', async function(assert) {
@@ -709,8 +701,8 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
run(() => this.get('selected').pushObject(numbers[3]));
- await click(findAll('.ember-power-select-option')[0]);
- assert.equal(findAll('.ember-power-select-multiple-option').length, 2, 'Two elements are selected');
+ await click('.ember-power-select-option');
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 2 }, 'Two elements are selected');
});
test('When the input inside the multiple select gets focused, the trigger and the dropdown gain special `--active` classes', async function(assert) {
@@ -723,10 +715,10 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- assert.ok(!find('.ember-power-select-trigger').classList.contains('ember-power-select-trigger--active'), 'The trigger does not have the class');
+ assert.dom('.ember-power-select-trigger').doesNotHaveClass('ember-power-select-trigger--active', 'The trigger does not have the class');
await clickTrigger();
- assert.ok(find('.ember-power-select-trigger').classList.contains('ember-power-select-trigger--active'), 'The trigger has the class');
- assert.ok(find('.ember-power-select-dropdown').classList.contains('ember-power-select-dropdown--active'), 'The dropdown has the class');
+ assert.dom('.ember-power-select-trigger').hasClass('ember-power-select-trigger--active', 'The trigger has the class');
+ assert.dom('.ember-power-select-dropdown').hasClass('ember-power-select-dropdown--active', 'The dropdown has the class');
});
test('When the power select multiple uses the default component and the search is enabled, the trigger has `tabindex=-1`', async function(assert) {
@@ -739,7 +731,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- assert.equal(find('.ember-power-select-trigger').attributes.tabindex.value, '-1', 'The trigger has tabindex=-1');
+ assert.dom('.ember-power-select-trigger').hasAttribute('tabindex', '-1', 'The trigger has tabindex=-1');
});
test('When the power select multiple uses the default component and the search is disabled, the trigger has `tabindex=0`', async function(assert) {
@@ -752,7 +744,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- assert.equal(find('.ember-power-select-trigger').attributes.tabindex.value, '0', 'The trigger has tabindex=0');
+ assert.dom('.ember-power-select-trigger').hasAttribute('tabindex', '0', 'The trigger has tabindex=0');
});
test('When the power select multiple uses the default component and the search is enabled, and the component receives an specific tabindex, the trigger has tabindex=-1, and the tabindex is applied to the searchbox inside', async function(assert) {
@@ -765,8 +757,8 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- assert.equal(find('.ember-power-select-trigger').attributes.tabindex.value, '-1', 'The trigger has tabindex=1');
- assert.equal(find('.ember-power-select-trigger-multiple-input').attributes.tabindex.value, '3', 'The searchbox has tabindex=3');
+ assert.dom('.ember-power-select-trigger').hasAttribute('tabindex', '-1', 'The trigger has tabindex=1');
+ assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('tabindex', '3', 'The searchbox has tabindex=3');
});
test('Multiple selects honor the `defaultHighlighted` option', async function(assert) {
@@ -781,7 +773,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- assert.equal(find('.ember-power-select-option[aria-current=true]').textContent.trim(), 'four', 'the given defaultHighlighted element is highlighted instead of the first, as usual');
+ assert.dom('.ember-power-select-option[aria-current=true]').hasText('four', 'the given defaultHighlighted element is highlighted instead of the first, as usual');
});
test('If the options of a multiple select implement `isEqual`, that option is used to determine whether or not two items are the same', async function(assert) {
@@ -805,11 +797,11 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
typeInSearch('M');
- await click(findAll('.ember-power-select-option')[1]);
+ await click('.ember-power-select-option:nth-child(2)');
typeInSearch('Mi');
- assert.equal(findAll('.ember-power-select-option')[0].attributes['aria-selected'].value, 'true', 'The item in the list is marked as selected');
- await click(findAll('.ember-power-select-option')[0]); // select the same user again should i[0])t
- assert.equal(findAll('.ember-power-select-multiple-option').length, 0);
+ assert.dom('.ember-power-select-option').hasAttribute('aria-selected', 'true', 'The item in the list is marked as selected');
+ await click('.ember-power-select-option'); // select the same user again should remove it
+ assert.dom('.ember-power-select-multiple-option').exists({ count: 0 });
});
test('When there is an option which is disabled the css class "ember-power-select-multiple-option--disabled" should be added', async function(assert) {
@@ -831,6 +823,6 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{option}}
{{/power-select-multiple}}
`);
- assert.equal(findAll('.ember-power-select-multiple-options .ember-power-select-multiple-option--disabled').length, disabledNumCountries, 'The class "ember-power-select-multiple-option--disabled" is added to disabled options');
+ assert.dom('.ember-power-select-multiple-options .ember-power-select-multiple-option--disabled').exists({ count: disabledNumCountries }, 'The class "ember-power-select-multiple-option--disabled" is added to disabled options');
});
});
From 44c84529b804762b8bc90e570bb8f1502f62a507 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Josu=C3=A9=20Pech?=
Date: Tue, 24 Apr 2018 03:03:01 -0500
Subject: [PATCH 22/34] Changed self.window to window and self.document to
document (#1099)
---
addon/components/power-select-multiple/trigger.js | 4 ++--
addon/components/power-select.js | 4 ++--
addon/components/power-select/before-options.js | 2 +-
addon/components/power-select/options.js | 2 +-
4 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/addon/components/power-select-multiple/trigger.js b/addon/components/power-select-multiple/trigger.js
index 81d71ca87..49d79fa20 100644
--- a/addon/components/power-select-multiple/trigger.js
+++ b/addon/components/power-select-multiple/trigger.js
@@ -8,9 +8,9 @@ import { isBlank } from '@ember/utils';
import { htmlSafe } from '@ember/string';
import layout from '../../templates/components/power-select-multiple/trigger';
-const ua = self.window && self.window.navigator ? self.window.navigator.userAgent : '';
+const ua = window && window.navigator ? window.navigator.userAgent : '';
const isIE = ua.indexOf('MSIE ') > -1 || ua.indexOf('Trident/') > -1;
-const isTouchDevice = !!self.window && 'ontouchstart' in self.window;
+const isTouchDevice = !!window && 'ontouchstart' in window;
export default Component.extend({
tagName: '',
diff --git a/addon/components/power-select.js b/addon/components/power-select.js
index 81219e204..aea42a4f4 100644
--- a/addon/components/power-select.js
+++ b/addon/components/power-select.js
@@ -326,7 +326,7 @@ export default Component.extend({
},
scrollTo(option, ...rest) {
- if (!self.document || !option) {
+ if (!document || !option) {
return;
}
let publicAPI = this.get('publicAPI');
@@ -334,7 +334,7 @@ export default Component.extend({
if (userDefinedScrollTo) {
return userDefinedScrollTo(option, publicAPI, ...rest);
}
- let optionsList = self.document.getElementById(`ember-power-select-options-${publicAPI.uniqueId}`);
+ let optionsList = document.getElementById(`ember-power-select-options-${publicAPI.uniqueId}`);
if (!optionsList) {
return;
}
diff --git a/addon/components/power-select/before-options.js b/addon/components/power-select/before-options.js
index ef7376778..8c3a880d9 100644
--- a/addon/components/power-select/before-options.js
+++ b/addon/components/power-select/before-options.js
@@ -39,7 +39,7 @@ export default Component.extend({
// Methods
focusInput() {
- this.input = self.document.querySelector(`.ember-power-select-search-input[aria-controls="${this.get('listboxId')}"]`);
+ this.input = document.querySelector(`.ember-power-select-search-input[aria-controls="${this.get('listboxId')}"]`);
if (this.input) {
scheduleOnce('afterRender', this.input, 'focus');
}
diff --git a/addon/components/power-select/options.js b/addon/components/power-select/options.js
index a7a83ba0c..8c0eb343e 100644
--- a/addon/components/power-select/options.js
+++ b/addon/components/power-select/options.js
@@ -2,7 +2,7 @@ import Component from '@ember/component';
import { computed } from '@ember/object';
import layout from '../../templates/components/power-select/options';
-const isTouchDevice = (!!self.window && 'ontouchstart' in self.window);
+const isTouchDevice = (!!window && 'ontouchstart' in window);
(function(ElementProto) {
if (typeof ElementProto.matches !== 'function') {
ElementProto.matches = ElementProto.msMatchesSelector || ElementProto.mozMatchesSelector || ElementProto.webkitMatchesSelector;
From 601579c3f915ca1ae9290c03950a95c274cff33e Mon Sep 17 00:00:00 2001
From: cibernox
Date: Tue, 24 Apr 2018 10:05:27 +0200
Subject: [PATCH 23/34] v2.0.0-beta.5
---
CHANGELOG.md | 3 +++
package.json | 2 +-
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 2875ab0e0..2994415a4 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,8 @@
# Master
+# 2.0.0-beta.5
+- [BUGFIX] Remove redundant `self.` preceeding many well know globals like document or window
+
# 2.0.0-beta.4
- [BUGFIX] Fixes big un Ember 3.1 accessing the getter `selected.then`
diff --git a/package.json b/package.json
index 539320689..485d6a483 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "ember-power-select",
- "version": "2.0.0-beta.4",
+ "version": "2.0.0-beta.5",
"description": "The extensible select component built for ember",
"keywords": [
"ember-addon",
From 2087909c159abf09322e43312006263681df99c9 Mon Sep 17 00:00:00 2001
From: Edward Faulkner
Date: Wed, 25 Apr 2018 18:43:37 -0400
Subject: [PATCH 24/34] Pre-render docs site at build time (#1102)
This PR enables Fastboot pre-rendering of the entire docs site using [prember[(https://github.com/ef4/prember). For URL discovery, it's using the newly-published [prember-crawler](https://github.com/ef4/prember-crawler)
I tested the `_redirects` on netlify to confirm it will work, and it does. By default, prember outputs an `_empty.html` file that contains your original (empty) index.html content, since your pre-rendered index.html file will have actual content in it.
---
ember-cli-build.js | 7 +-
package.json | 3 +
tests/dummy/public/_redirects | 2 +-
yarn.lock | 346 +++++++++++++++++++++++++++++++---
4 files changed, 333 insertions(+), 25 deletions(-)
diff --git a/ember-cli-build.js b/ember-cli-build.js
index 05c247c3e..6a9fc5d95 100644
--- a/ember-cli-build.js
+++ b/ember-cli-build.js
@@ -2,13 +2,16 @@
const EmberAddon = require('ember-cli/lib/broccoli/ember-addon');
const VersionChecker = require('ember-cli-version-checker'); // eslint-disable-line
-
+const crawl = require('prember-crawler');
module.exports = function(defaults) {
let checker = new VersionChecker(defaults);
let emberChecker = checker.forEmber();
let options = {
- snippetPaths: ['tests/dummy/app/templates/snippets']
+ snippetPaths: ['tests/dummy/app/templates/snippets'],
+ prember: {
+ urls: crawl
+ }
};
if (process.env.DEPLOY_TARGET === undefined && emberChecker.isAbove('2.14.0')) {
diff --git a/package.json b/package.json
index 485d6a483..0cd32690c 100644
--- a/package.json
+++ b/package.json
@@ -55,6 +55,7 @@
"ember-cli-blueprint-test-helpers": "^0.18.3",
"ember-cli-dependency-checker": "^2.0.1",
"ember-cli-eslint": "^4.2.1",
+ "ember-cli-fastboot": "^1.1.4-beta.1",
"ember-cli-htmlbars-inline-precompile": "^1.0.2",
"ember-cli-inject-live-reload": "^1.7.0",
"ember-cli-mirage": "^0.4.3",
@@ -83,6 +84,8 @@
"loader.js": "^4.6.0",
"memory-scroll": "0.9.1",
"mocha": "2.5.3",
+ "prember": "0.4.0",
+ "prember-crawler": "^0.1.0",
"qunit-dom": "^0.6.2",
"simple-git": "^1.10.0",
"testdouble": "^3.2.6"
diff --git a/tests/dummy/public/_redirects b/tests/dummy/public/_redirects
index ad37e2c2c..9733ef366 100644
--- a/tests/dummy/public/_redirects
+++ b/tests/dummy/public/_redirects
@@ -1 +1 @@
-/* /index.html 200
+/* /_empty.html 200
diff --git a/yarn.lock b/yarn.lock
index bd0b2dfe2..e9c88d3f0 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -66,6 +66,10 @@
version "0.7.0"
resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-0.7.0.tgz#9a06f4f137ee84d7df0460c1fdb1135ffa6c50fd"
+abab@^1.0.4:
+ version "1.0.4"
+ resolved "https://registry.yarnpkg.com/abab/-/abab-1.0.4.tgz#5faad9c2c07f60dd76770f71cf025b62a63cfd4e"
+
abbrev@1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8"
@@ -77,6 +81,12 @@ accepts@~1.3.4, accepts@~1.3.5:
mime-types "~2.1.18"
negotiator "0.6.1"
+acorn-globals@^4.1.0:
+ version "4.1.0"
+ resolved "https://registry.yarnpkg.com/acorn-globals/-/acorn-globals-4.1.0.tgz#ab716025dbe17c54d3ef81d32ece2b2d99fe2538"
+ dependencies:
+ acorn "^5.0.0"
+
acorn-jsx@^3.0.0:
version "3.0.1"
resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-3.0.1.tgz#afdf9488fb1ecefc8348f6fb22f464e32a58b36b"
@@ -87,7 +97,7 @@ acorn@^3.0.4:
version "3.3.0"
resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a"
-acorn@^5.5.0:
+acorn@^5.0.0, acorn@^5.3.0, acorn@^5.5.0:
version "5.5.3"
resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.5.3.tgz#f473dd47e0277a08e28e9bec5aeeb04751f0b8c9"
@@ -1435,6 +1445,10 @@ broccoli-writer@^0.1.1, broccoli-writer@~0.1.1:
quick-temp "^0.1.0"
rsvp "^3.0.6"
+browser-process-hrtime@^0.1.2:
+ version "0.1.2"
+ resolved "https://registry.yarnpkg.com/browser-process-hrtime/-/browser-process-hrtime-0.1.2.tgz#425d68a58d3447f02a04aa894187fce8af8b7b8e"
+
browser-stdout@1.3.0:
version "1.3.0"
resolved "https://registry.yarnpkg.com/browser-stdout/-/browser-stdout-1.3.0.tgz#f351d32969d32fa5d7a5567154263d928ae3bd1f"
@@ -1640,6 +1654,14 @@ chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.3.1:
escape-string-regexp "^1.0.5"
supports-color "^5.3.0"
+chalk@^2.3.0:
+ version "2.4.0"
+ resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.0.tgz#a060a297a6b57e15b61ca63ce84995daa0fe6e52"
+ dependencies:
+ ansi-styles "^3.2.1"
+ escape-string-regexp "^1.0.5"
+ supports-color "^5.3.0"
+
chardet@^0.4.0:
version "0.4.2"
resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.4.2.tgz#b5473b33dc97c424e5d98dc87d55d4d8a29c8bf2"
@@ -1934,7 +1956,7 @@ continuable-cache@^0.3.1:
version "0.3.1"
resolved "https://registry.yarnpkg.com/continuable-cache/-/continuable-cache-0.3.1.tgz#bd727a7faed77e71ff3985ac93351a912733ad0f"
-convert-source-map@^1.5.0:
+convert-source-map@^1.5.0, convert-source-map@^1.5.1:
version "1.5.1"
resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.5.1.tgz#b8278097b9bc229365de5c62cf5fcaed8b5599e5"
@@ -1942,7 +1964,7 @@ cookie-signature@1.0.6:
version "1.0.6"
resolved "https://registry.yarnpkg.com/cookie-signature/-/cookie-signature-1.0.6.tgz#e303a882b342cc3ee8ca513a79999734dab3ae2c"
-cookie@0.3.1:
+cookie@0.3.1, cookie@^0.3.1:
version "0.3.1"
resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.3.1.tgz#e7e0a1f9ef43b4c8ba925c5c5a96e806d16873bb"
@@ -2019,6 +2041,16 @@ cson-parser@^1.1.0:
dependencies:
coffee-script "^1.10.0"
+cssom@0.3.x, "cssom@>= 0.3.2 < 0.4.0":
+ version "0.3.2"
+ resolved "https://registry.yarnpkg.com/cssom/-/cssom-0.3.2.tgz#b8036170c79f07a90ff2f16e22284027a243848b"
+
+"cssstyle@>= 0.2.37 < 0.3.0":
+ version "0.2.37"
+ resolved "https://registry.yarnpkg.com/cssstyle/-/cssstyle-0.2.37.tgz#541097234cb2513c83ceed3acddc27ff27987d54"
+ dependencies:
+ cssom "0.3.x"
+
currently-unhandled@^0.4.1:
version "0.4.1"
resolved "https://registry.yarnpkg.com/currently-unhandled/-/currently-unhandled-0.4.1.tgz#988df33feab191ef799a61369dd76c17adf957ea"
@@ -2041,6 +2073,14 @@ dashdash@^1.12.0:
dependencies:
assert-plus "^1.0.0"
+data-urls@^1.0.0:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/data-urls/-/data-urls-1.0.0.tgz#24802de4e81c298ea8a9388bb0d8e461c774684f"
+ dependencies:
+ abab "^1.0.4"
+ whatwg-mimetype "^2.0.0"
+ whatwg-url "^6.4.0"
+
debug@2.2.0:
version "2.2.0"
resolved "https://registry.yarnpkg.com/debug/-/debug-2.2.0.tgz#f87057e995b1a1f6ae6a4960664137bc56f039da"
@@ -2144,6 +2184,10 @@ delegates@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/delegates/-/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a"
+denodeify@^1.2.1:
+ version "1.2.1"
+ resolved "https://registry.yarnpkg.com/denodeify/-/denodeify-1.2.1.tgz#3a36287f5034e699e7577901052c2e6c94251631"
+
depd@1.1.1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/depd/-/depd-1.1.1.tgz#5783b4e1c459f06fa5ca27f991f3d06e7a310359"
@@ -2188,6 +2232,12 @@ doctrine@^2.1.0:
dependencies:
esutils "^2.0.2"
+domexception@^1.0.0:
+ version "1.0.1"
+ resolved "https://registry.yarnpkg.com/domexception/-/domexception-1.0.1.tgz#937442644ca6a31261ef36e3ec677fe805582c90"
+ dependencies:
+ webidl-conversions "^4.0.2"
+
dot-prop@^4.1.0:
version "4.2.0"
resolved "https://registry.yarnpkg.com/dot-prop/-/dot-prop-4.2.0.tgz#1f19e0c2e1aa0e32797c49799f2837ac6af69c57"
@@ -2224,7 +2274,7 @@ ember-basic-dropdown@^1.0.0-beta.5:
ember-cli-htmlbars "^2.0.3"
ember-maybe-in-element "^0.1.3"
-ember-cli-babel@6.12.0, ember-cli-babel@^6.0.0, ember-cli-babel@^6.0.0-beta.4, ember-cli-babel@^6.0.0-beta.7, ember-cli-babel@^6.10.0, ember-cli-babel@^6.11.0, ember-cli-babel@^6.12.0, ember-cli-babel@^6.3.0, ember-cli-babel@^6.6.0, ember-cli-babel@^6.8.1, ember-cli-babel@^6.8.2, ember-cli-babel@^6.9.0:
+ember-cli-babel@6.12.0, ember-cli-babel@^6.0.0, ember-cli-babel@^6.0.0-beta.4, ember-cli-babel@^6.0.0-beta.7, ember-cli-babel@^6.10.0, ember-cli-babel@^6.11.0, ember-cli-babel@^6.12.0, ember-cli-babel@^6.3.0, ember-cli-babel@^6.6.0, ember-cli-babel@^6.7.2, ember-cli-babel@^6.8.1, ember-cli-babel@^6.8.2, ember-cli-babel@^6.9.0:
version "6.12.0"
resolved "https://registry.yarnpkg.com/ember-cli-babel/-/ember-cli-babel-6.12.0.tgz#3adcdbe1278da1fcd0b9038f1360cb4ac5d4414c"
dependencies:
@@ -2283,6 +2333,27 @@ ember-cli-eslint@^4.2.1:
rsvp "^4.6.1"
walk-sync "^0.3.0"
+ember-cli-fastboot@^1.1.4-beta.1:
+ version "1.1.4-beta.1"
+ resolved "https://registry.yarnpkg.com/ember-cli-fastboot/-/ember-cli-fastboot-1.1.4-beta.1.tgz#7063df36e62b92fd0f60c9a23dd03b5b57aec3fe"
+ dependencies:
+ broccoli-concat "^3.2.2"
+ broccoli-funnel "^2.0.0"
+ broccoli-merge-trees "^2.0.0"
+ broccoli-plugin "^1.2.1"
+ chalk "^2.0.1"
+ ember-cli-babel "^6.7.2"
+ ember-cli-lodash-subset "2.0.1"
+ ember-cli-preprocess-registry "^3.1.0"
+ ember-cli-version-checker "^2.1.0"
+ fastboot "^1.1.4-beta.1"
+ fastboot-express-middleware "^1.1.0"
+ fastboot-transform "^0.1.2"
+ fs-extra "^4.0.2"
+ json-stable-stringify "^1.0.1"
+ md5-hex "^2.0.0"
+ silent-error "^1.0.0"
+
ember-cli-get-component-path-option@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/ember-cli-get-component-path-option/-/ember-cli-get-component-path-option-1.0.0.tgz#0d7b595559e2f9050abed804f1d8eff1b08bc771"
@@ -2331,14 +2402,14 @@ ember-cli-is-package-missing@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/ember-cli-is-package-missing/-/ember-cli-is-package-missing-1.0.0.tgz#6e6184cafb92635dd93ca6c946b104292d4e3390"
+ember-cli-lodash-subset@2.0.1, ember-cli-lodash-subset@^2.0.1:
+ version "2.0.1"
+ resolved "https://registry.yarnpkg.com/ember-cli-lodash-subset/-/ember-cli-lodash-subset-2.0.1.tgz#20cb68a790fe0fde2488ddfd8efbb7df6fe766f2"
+
ember-cli-lodash-subset@^1.0.7:
version "1.0.12"
resolved "https://registry.yarnpkg.com/ember-cli-lodash-subset/-/ember-cli-lodash-subset-1.0.12.tgz#af2e77eba5dcb0d77f3308d3a6fd7d3450f6e537"
-ember-cli-lodash-subset@^2.0.1:
- version "2.0.1"
- resolved "https://registry.yarnpkg.com/ember-cli-lodash-subset/-/ember-cli-lodash-subset-2.0.1.tgz#20cb68a790fe0fde2488ddfd8efbb7df6fe766f2"
-
ember-cli-mirage@^0.4.3:
version "0.4.3"
resolved "https://registry.yarnpkg.com/ember-cli-mirage/-/ember-cli-mirage-0.4.3.tgz#81470c2b9cdb2b88661c56be6aacb928945a9b3b"
@@ -2979,6 +3050,17 @@ escape-string-regexp@1.0.5, escape-string-regexp@^1.0.0, escape-string-regexp@^1
version "1.0.5"
resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4"
+escodegen@^1.9.0:
+ version "1.9.1"
+ resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.9.1.tgz#dbae17ef96c8e4bedb1356f4504fa4cc2f7cb7e2"
+ dependencies:
+ esprima "^3.1.3"
+ estraverse "^4.2.0"
+ esutils "^2.0.2"
+ optionator "^0.8.1"
+ optionalDependencies:
+ source-map "~0.6.1"
+
eslint-plugin-ember@^5.0.0:
version "5.1.0"
resolved "https://registry.yarnpkg.com/eslint-plugin-ember/-/eslint-plugin-ember-5.1.0.tgz#fb96abd2d8bf105678a0aa81dadd99d7ca441ba1"
@@ -3057,6 +3139,10 @@ espree@^3.5.4:
acorn "^5.5.0"
acorn-jsx "^3.0.0"
+esprima@^3.1.3, esprima@~3.1.0:
+ version "3.1.3"
+ resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.1.3.tgz#fdca51cee6133895e3c88d535ce49dbff62a4633"
+
esprima@^4.0.0:
version "4.0.0"
resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.0.tgz#4499eddcd1110e0b218bacf2fa7f7f59f55ca804"
@@ -3065,10 +3151,6 @@ esprima@~3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.0.0.tgz#53cf247acda77313e551c3aa2e73342d3fb4f7d9"
-esprima@~3.1.0:
- version "3.1.3"
- resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.1.3.tgz#fdca51cee6133895e3c88d535ce49dbff62a4633"
-
esquery@^1.0.0:
version "1.0.1"
resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708"
@@ -3081,7 +3163,7 @@ esrecurse@^4.1.0:
dependencies:
estraverse "^4.1.0"
-estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1:
+estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1, estraverse@^4.2.0:
version "4.2.0"
resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.2.0.tgz#0dee3fed31fcd469618ce7342099fc1afa0bdb13"
@@ -3196,7 +3278,7 @@ expand-tilde@^2.0.0, expand-tilde@^2.0.2:
dependencies:
homedir-polyfill "^1.0.1"
-express@^4.10.7, express@^4.12.3:
+express@^4.10.7, express@^4.12.3, express@^4.16.2:
version "4.16.3"
resolved "https://registry.yarnpkg.com/express/-/express-4.16.3.tgz#6af8a502350db3246ecc4becf6b5a34d22f7ed53"
dependencies:
@@ -3330,6 +3412,47 @@ fast-sourcemap-concat@^1.0.1:
source-map-url "^0.3.0"
sourcemap-validator "^1.0.5"
+fastboot-express-middleware@^1.1.0:
+ version "1.1.1"
+ resolved "https://registry.yarnpkg.com/fastboot-express-middleware/-/fastboot-express-middleware-1.1.1.tgz#b6e156a3acbaecef42b1f023ebb8405a934c28e6"
+ dependencies:
+ chalk "^2.0.1"
+ fastboot "^1.1.2"
+ request "^2.81.0"
+
+fastboot-transform@^0.1.2:
+ version "0.1.3"
+ resolved "https://registry.yarnpkg.com/fastboot-transform/-/fastboot-transform-0.1.3.tgz#7dea0b117594afd8772baa6c9b0919644e7f7dcd"
+ dependencies:
+ broccoli-stew "^1.5.0"
+ convert-source-map "^1.5.1"
+
+fastboot@^1.1.2, fastboot@^1.1.3:
+ version "1.1.3"
+ resolved "https://registry.yarnpkg.com/fastboot/-/fastboot-1.1.3.tgz#56c5f56415c5ae8de2db539c0d3ecbcd65538f8b"
+ dependencies:
+ chalk "^2.0.1"
+ cookie "^0.3.1"
+ debug "^3.0.0"
+ exists-sync "0.0.4"
+ najax "^1.0.2"
+ rsvp "^4.7.0"
+ simple-dom "^1.0.0"
+ source-map-support "^0.5.0"
+
+fastboot@^1.1.4-beta.1:
+ version "1.1.4-beta.1"
+ resolved "https://registry.yarnpkg.com/fastboot/-/fastboot-1.1.4-beta.1.tgz#860f8af2bd032b3a7477fdf6e1a64b034a02829f"
+ dependencies:
+ chalk "^2.0.1"
+ cookie "^0.3.1"
+ debug "^3.0.0"
+ exists-sync "0.0.4"
+ najax "^1.0.2"
+ rsvp "^4.7.0"
+ simple-dom "^1.0.0"
+ source-map-support "^0.5.0"
+
faye-websocket@~0.10.0:
version "0.10.0"
resolved "https://registry.yarnpkg.com/faye-websocket/-/faye-websocket-0.10.0.tgz#4e492f8d04dfb6f89003507f6edbf2d501e7c6f4"
@@ -4021,6 +4144,12 @@ hosted-git-info@^2.1.4, hosted-git-info@^2.6.0:
version "2.6.0"
resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.6.0.tgz#23235b29ab230c576aab0d4f13fc046b0b038222"
+html-encoding-sniffer@^1.0.2:
+ version "1.0.2"
+ resolved "https://registry.yarnpkg.com/html-encoding-sniffer/-/html-encoding-sniffer-1.0.2.tgz#e70d84b94da53aa375e11fe3a351be6642ca46f8"
+ dependencies:
+ whatwg-encoding "^1.0.1"
+
http-cache-semantics@3.8.1:
version "3.8.1"
resolved "https://registry.yarnpkg.com/http-cache-semantics/-/http-cache-semantics-3.8.1.tgz#39b0e16add9b605bf0a9ef3d9daaf4843b4cacd2"
@@ -4490,6 +4619,10 @@ jade@0.26.3:
commander "0.6.1"
mkdirp "0.3.0"
+jquery-deferred@^0.3.0:
+ version "0.3.1"
+ resolved "https://registry.yarnpkg.com/jquery-deferred/-/jquery-deferred-0.3.1.tgz#596eca1caaff54f61b110962b23cafea74c35355"
+
jquery@^3.3.1:
version "3.3.1"
resolved "https://registry.yarnpkg.com/jquery/-/jquery-3.3.1.tgz#958ce29e81c9790f31be7792df5d4d95fc57fbca"
@@ -4517,6 +4650,37 @@ jsbn@~0.1.0:
version "0.1.1"
resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513"
+jsdom@^11.5.1:
+ version "11.9.0"
+ resolved "https://registry.yarnpkg.com/jsdom/-/jsdom-11.9.0.tgz#58ac6dfd248d560d736b0202d74eedad55590cd9"
+ dependencies:
+ abab "^1.0.4"
+ acorn "^5.3.0"
+ acorn-globals "^4.1.0"
+ array-equal "^1.0.0"
+ cssom ">= 0.3.2 < 0.4.0"
+ cssstyle ">= 0.2.37 < 0.3.0"
+ data-urls "^1.0.0"
+ domexception "^1.0.0"
+ escodegen "^1.9.0"
+ html-encoding-sniffer "^1.0.2"
+ left-pad "^1.2.0"
+ nwmatcher "^1.4.3"
+ parse5 "4.0.0"
+ pn "^1.1.0"
+ request "^2.83.0"
+ request-promise-native "^1.0.5"
+ sax "^1.2.4"
+ symbol-tree "^3.2.2"
+ tough-cookie "^2.3.3"
+ w3c-hr-time "^1.0.1"
+ webidl-conversions "^4.0.2"
+ whatwg-encoding "^1.0.3"
+ whatwg-mimetype "^2.1.0"
+ whatwg-url "^6.4.0"
+ ws "^4.0.0"
+ xml-name-validator "^3.0.0"
+
jsesc@^1.3.0:
version "1.3.0"
resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-1.3.0.tgz#46c3fec8c1892b12b0833db9bc7622176dbab34b"
@@ -4646,6 +4810,10 @@ leek@0.0.24:
lodash.assign "^3.2.0"
rsvp "^3.0.21"
+left-pad@^1.2.0:
+ version "1.3.0"
+ resolved "https://registry.yarnpkg.com/left-pad/-/left-pad-1.3.0.tgz#5b8a3a7765dfe001261dde915589e782f8c94d1e"
+
levn@^0.3.0, levn@~0.3.0:
version "0.3.0"
resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee"
@@ -5008,6 +5176,10 @@ lodash.restparam@^3.0.0:
version "3.6.1"
resolved "https://registry.yarnpkg.com/lodash.restparam/-/lodash.restparam-3.6.1.tgz#936a4e309ef330a7645ed4145986c85ae5b20805"
+lodash.sortby@^4.7.0:
+ version "4.7.0"
+ resolved "https://registry.yarnpkg.com/lodash.sortby/-/lodash.sortby-4.7.0.tgz#edd14c824e2cc9c1e0b0a1b42bb5210516a42438"
+
lodash.support@~2.3.0:
version "2.3.0"
resolved "https://registry.yarnpkg.com/lodash.support/-/lodash.support-2.3.0.tgz#7eaf038af4f0d6aab776b44aa6dcfc80334c9bfd"
@@ -5093,6 +5265,10 @@ lodash@^4.0.0, lodash@^4.14.0, lodash@^4.16.1, lodash@^4.17.2, lodash@^4.17.4, l
version "4.17.5"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.5.tgz#99a92d65c0272debe8c96b6057bc8fbfa3bed511"
+lodash@^4.13.1:
+ version "4.17.10"
+ resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.10.tgz#1b7793cf7259ea38fb3661d4d38b3260af8ae4e7"
+
log-symbols@^2.2.0:
version "2.2.0"
resolved "https://registry.yarnpkg.com/log-symbols/-/log-symbols-2.2.0.tgz#5740e1c5d6f0dfda4ad9323b5332107ef6b4c40a"
@@ -5449,6 +5625,14 @@ mute-stream@0.0.7:
version "0.0.7"
resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab"
+najax@^1.0.2:
+ version "1.0.3"
+ resolved "https://registry.yarnpkg.com/najax/-/najax-1.0.3.tgz#11145f4d910446ea661d8ab7fcef53f6ad164ae5"
+ dependencies:
+ jquery-deferred "^0.3.0"
+ lodash.defaultsdeep "^4.6.0"
+ qs "^6.2.0"
+
nan@^2.10.0, nan@^2.3.0:
version "2.10.0"
resolved "https://registry.yarnpkg.com/nan/-/nan-2.10.0.tgz#96d0cd610ebd58d4b4de9cc0c6828cda99c7548f"
@@ -5646,6 +5830,10 @@ number-is-nan@^1.0.0:
version "1.0.1"
resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d"
+nwmatcher@^1.4.3:
+ version "1.4.4"
+ resolved "https://registry.yarnpkg.com/nwmatcher/-/nwmatcher-1.4.4.tgz#2285631f34a95f0d0395cd900c96ed39b58f346e"
+
oauth-sign@~0.8.1, oauth-sign@~0.8.2:
version "0.8.2"
resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.8.2.tgz#46a6ab7f0aead8deae9ec0565780b7d4efeb9d43"
@@ -5722,7 +5910,7 @@ optimist@^0.6.1:
minimist "~0.0.1"
wordwrap "~0.0.2"
-optionator@^0.8.2:
+optionator@^0.8.1, optionator@^0.8.2:
version "0.8.2"
resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.2.tgz#364c5e409d3f4d6301d6c0b4c05bba50180aeb64"
dependencies:
@@ -5822,6 +6010,10 @@ parse-passwd@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/parse-passwd/-/parse-passwd-1.0.0.tgz#6d5b934a456993b23d37f40a382d6f1666a8e5c6"
+parse5@4.0.0:
+ version "4.0.0"
+ resolved "https://registry.yarnpkg.com/parse5/-/parse5-4.0.0.tgz#6d78656e3da8d78b4ec0b906f7c08ef1dfe3f608"
+
parseqs@0.0.5:
version "0.0.5"
resolved "https://registry.yarnpkg.com/parseqs/-/parseqs-0.0.5.tgz#d5208a3738e46766e291ba2ea173684921a8b89d"
@@ -5924,6 +6116,10 @@ pluralize@^7.0.0:
version "7.0.0"
resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-7.0.0.tgz#298b89df8b93b0221dbf421ad2b1b1ea23fc6777"
+pn@^1.1.0:
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/pn/-/pn-1.1.0.tgz#e2f4cef0e219f463c179ab37463e4e1ecdccbafb"
+
portfinder@^1.0.7:
version "1.0.13"
resolved "https://registry.yarnpkg.com/portfinder/-/portfinder-1.0.13.tgz#bb32ecd87c27104ae6ee44b5a3ccbf0ebb1aede9"
@@ -5940,6 +6136,26 @@ prelude-ls@~1.1.2:
version "1.1.2"
resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54"
+prember-crawler@^0.1.0:
+ version "0.1.0"
+ resolved "https://registry.yarnpkg.com/prember-crawler/-/prember-crawler-0.1.0.tgz#e7629b01ca818f34f422f23c641132148c5b0874"
+ dependencies:
+ jsdom "^11.5.1"
+
+prember@0.4.0:
+ version "0.4.0"
+ resolved "https://registry.yarnpkg.com/prember/-/prember-0.4.0.tgz#55607d74babe74958e0c08d78da66e002dc02bea"
+ dependencies:
+ broccoli-debug "^0.6.3"
+ broccoli-merge-trees "^2.0.0"
+ broccoli-plugin "^1.3.0"
+ chalk "^2.3.0"
+ denodeify "^1.2.1"
+ ember-cli-babel "^6.6.0"
+ express "^4.16.2"
+ fastboot "^1.1.3"
+ mkdirp "^0.5.1"
+
prepend-http@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-2.0.0.tgz#e92434bfa5ea8c19f41cdfd401d741a3c819d897"
@@ -5998,7 +6214,11 @@ punycode@^1.4.1:
version "1.4.1"
resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e"
-qs@6.5.1, qs@^6.4.0, qs@~6.5.1:
+punycode@^2.1.0:
+ version "2.1.0"
+ resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.0.tgz#5f863edc89b96db09074bad7947bf09056ca4e7d"
+
+qs@6.5.1, qs@^6.2.0, qs@^6.4.0, qs@~6.5.1:
version "6.5.1"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8"
@@ -6232,7 +6452,21 @@ repeating@^2.0.0:
dependencies:
is-finite "^1.0.0"
-request@2:
+request-promise-core@1.1.1:
+ version "1.1.1"
+ resolved "https://registry.yarnpkg.com/request-promise-core/-/request-promise-core-1.1.1.tgz#3eee00b2c5aa83239cfb04c5700da36f81cd08b6"
+ dependencies:
+ lodash "^4.13.1"
+
+request-promise-native@^1.0.5:
+ version "1.0.5"
+ resolved "https://registry.yarnpkg.com/request-promise-native/-/request-promise-native-1.0.5.tgz#5281770f68e0c9719e5163fd3fab482215f4fda5"
+ dependencies:
+ request-promise-core "1.1.1"
+ stealthy-require "^1.1.0"
+ tough-cookie ">=2.3.3"
+
+request@2, request@^2.81.0, request@^2.83.0:
version "2.85.0"
resolved "https://registry.yarnpkg.com/request/-/request-2.85.0.tgz#5a03615a47c61420b3eb99b7dba204f83603e1fa"
dependencies:
@@ -6494,6 +6728,10 @@ sass-graph@^2.2.4:
scss-tokenizer "^0.2.3"
yargs "^7.0.0"
+sax@^1.2.4:
+ version "1.2.4"
+ resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9"
+
scss-tokenizer@^0.2.3:
version "0.2.3"
resolved "https://registry.yarnpkg.com/scss-tokenizer/-/scss-tokenizer-0.2.3.tgz#8eb06db9a9723333824d3f5530641149847ce5d1"
@@ -6598,6 +6836,10 @@ silent-error@^1.0.0, silent-error@^1.0.1, silent-error@^1.1.0:
dependencies:
debug "^2.2.0"
+simple-dom@^1.0.0:
+ version "1.3.0"
+ resolved "https://registry.yarnpkg.com/simple-dom/-/simple-dom-1.3.0.tgz#8473e0d34e340544b061410dba3faf4f1b7aa282"
+
simple-git@^1.10.0:
version "1.92.0"
resolved "https://registry.yarnpkg.com/simple-git/-/simple-git-1.92.0.tgz#6061468eb7d19f0141078fc742e62457e910f547"
@@ -6737,6 +6979,13 @@ source-map-support@^0.4.0, source-map-support@^0.4.15:
dependencies:
source-map "^0.5.6"
+source-map-support@^0.5.0:
+ version "0.5.5"
+ resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.5.tgz#0d4af9e00493e855402e8ec36ebed2d266fceb90"
+ dependencies:
+ buffer-from "^1.0.0"
+ source-map "^0.6.0"
+
source-map-url@^0.3.0:
version "0.3.0"
resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.3.0.tgz#7ecaf13b57bcd09da8a40c5d269db33799d4aaf9"
@@ -6755,16 +7004,16 @@ source-map@^0.5.6, source-map@^0.5.7, source-map@~0.5.0, source-map@~0.5.1:
version "0.5.7"
resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc"
+source-map@^0.6.0, source-map@~0.6.1:
+ version "0.6.1"
+ resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263"
+
source-map@~0.1.x:
version "0.1.43"
resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.1.43.tgz#c24bc146ca517c1471f5dacbe2571b2b7f9e3346"
dependencies:
amdefine ">=0.0.4"
-source-map@~0.6.1:
- version "0.6.1"
- resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263"
-
sourcemap-validator@^1.0.5:
version "1.1.0"
resolved "https://registry.yarnpkg.com/sourcemap-validator/-/sourcemap-validator-1.1.0.tgz#00454547d1682186e1498a7208e022e8dfa8738f"
@@ -6856,6 +7105,10 @@ stdout-stream@^1.4.0:
dependencies:
readable-stream "^2.0.1"
+stealthy-require@^1.1.0:
+ version "1.1.1"
+ resolved "https://registry.yarnpkg.com/stealthy-require/-/stealthy-require-1.1.1.tgz#35b09875b4ff49f26a777e509b3090a3226bf24b"
+
strict-uri-encode@^1.0.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/strict-uri-encode/-/strict-uri-encode-1.1.0.tgz#279b225df1d582b1f54e65addd4352e18faa0713"
@@ -6976,6 +7229,10 @@ supports-color@^5.3.0:
dependencies:
has-flag "^3.0.0"
+symbol-tree@^3.2.2:
+ version "3.2.2"
+ resolved "https://registry.yarnpkg.com/symbol-tree/-/symbol-tree-3.2.2.tgz#ae27db38f660a7ae2e1c3b7d1bc290819b8519e6"
+
symlink-or-copy@^1.0.0, symlink-or-copy@^1.0.1, symlink-or-copy@^1.1.8:
version "1.2.0"
resolved "https://registry.yarnpkg.com/symlink-or-copy/-/symlink-or-copy-1.2.0.tgz#5d49108e2ab824a34069b68974486c290020b393"
@@ -7159,12 +7416,18 @@ to-regex@^3.0.1, to-regex@^3.0.2:
regex-not "^1.0.2"
safe-regex "^1.1.0"
-tough-cookie@~2.3.0, tough-cookie@~2.3.3:
+tough-cookie@>=2.3.3, tough-cookie@^2.3.3, tough-cookie@~2.3.0, tough-cookie@~2.3.3:
version "2.3.4"
resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.4.tgz#ec60cee38ac675063ffc97a5c18970578ee83655"
dependencies:
punycode "^1.4.1"
+tr46@^1.0.1:
+ version "1.0.1"
+ resolved "https://registry.yarnpkg.com/tr46/-/tr46-1.0.1.tgz#a8b13fd6bfd2489519674ccde55ba3693b706d09"
+ dependencies:
+ punycode "^2.1.0"
+
tree-sync@^1.2.1, tree-sync@^1.2.2:
version "1.2.2"
resolved "https://registry.yarnpkg.com/tree-sync/-/tree-sync-1.2.2.tgz#2cf76b8589f59ffedb58db5a3ac7cb013d0158b7"
@@ -7390,6 +7653,12 @@ verror@1.10.0:
core-util-is "1.0.2"
extsprintf "^1.2.0"
+w3c-hr-time@^1.0.1:
+ version "1.0.1"
+ resolved "https://registry.yarnpkg.com/w3c-hr-time/-/w3c-hr-time-1.0.1.tgz#82ac2bff63d950ea9e3189a58a65625fedf19045"
+ dependencies:
+ browser-process-hrtime "^0.1.2"
+
walk-sync@0.3.2, walk-sync@^0.3.0, walk-sync@^0.3.1, walk-sync@^0.3.2:
version "0.3.2"
resolved "https://registry.yarnpkg.com/walk-sync/-/walk-sync-0.3.2.tgz#4827280afc42d0e035367c4a4e31eeac0d136f75"
@@ -7437,6 +7706,10 @@ wcwidth@^1.0.1:
dependencies:
defaults "^1.0.3"
+webidl-conversions@^4.0.2:
+ version "4.0.2"
+ resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-4.0.2.tgz#a855980b1f0b6b359ba1d5d9fb39ae941faa63ad"
+
websocket-driver@>=0.5.1:
version "0.7.0"
resolved "https://registry.yarnpkg.com/websocket-driver/-/websocket-driver-0.7.0.tgz#0caf9d2d755d93aee049d4bdd0d3fe2cca2a24eb"
@@ -7448,10 +7721,28 @@ websocket-extensions@>=0.1.1:
version "0.1.3"
resolved "https://registry.yarnpkg.com/websocket-extensions/-/websocket-extensions-0.1.3.tgz#5d2ff22977003ec687a4b87073dfbbac146ccf29"
+whatwg-encoding@^1.0.1, whatwg-encoding@^1.0.3:
+ version "1.0.3"
+ resolved "https://registry.yarnpkg.com/whatwg-encoding/-/whatwg-encoding-1.0.3.tgz#57c235bc8657e914d24e1a397d3c82daee0a6ba3"
+ dependencies:
+ iconv-lite "0.4.19"
+
whatwg-fetch@^2.0.3:
version "2.0.4"
resolved "https://registry.yarnpkg.com/whatwg-fetch/-/whatwg-fetch-2.0.4.tgz#dde6a5df315f9d39991aa17621853d720b85566f"
+whatwg-mimetype@^2.0.0, whatwg-mimetype@^2.1.0:
+ version "2.1.0"
+ resolved "https://registry.yarnpkg.com/whatwg-mimetype/-/whatwg-mimetype-2.1.0.tgz#f0f21d76cbba72362eb609dbed2a30cd17fcc7d4"
+
+whatwg-url@^6.4.0:
+ version "6.4.1"
+ resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-6.4.1.tgz#fdb94b440fd4ad836202c16e9737d511f012fd67"
+ dependencies:
+ lodash.sortby "^4.7.0"
+ tr46 "^1.0.1"
+ webidl-conversions "^4.0.2"
+
which-module@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/which-module/-/which-module-1.0.0.tgz#bba63ca861948994ff307736089e3b96026c2a4f"
@@ -7515,6 +7806,13 @@ write@^0.2.1:
dependencies:
mkdirp "^0.5.1"
+ws@^4.0.0:
+ version "4.1.0"
+ resolved "https://registry.yarnpkg.com/ws/-/ws-4.1.0.tgz#a979b5d7d4da68bf54efe0408967c324869a7289"
+ dependencies:
+ async-limiter "~1.0.0"
+ safe-buffer "~5.1.0"
+
ws@~3.3.1:
version "3.3.3"
resolved "https://registry.yarnpkg.com/ws/-/ws-3.3.3.tgz#f1cf84fe2d5e901ebce94efaece785f187a228f2"
@@ -7527,6 +7825,10 @@ xdg-basedir@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/xdg-basedir/-/xdg-basedir-3.0.0.tgz#496b2cc109eca8dbacfe2dc72b603c17c5870ad4"
+xml-name-validator@^3.0.0:
+ version "3.0.0"
+ resolved "https://registry.yarnpkg.com/xml-name-validator/-/xml-name-validator-3.0.0.tgz#6ae73e06de4d8c6e47f9fb181f78d648ad457c6a"
+
xmldom@^0.1.19:
version "0.1.27"
resolved "https://registry.yarnpkg.com/xmldom/-/xmldom-0.1.27.tgz#d501f97b3bdb403af8ef9ecc20573187aadac0e9"
From bd5bd5d6ed4d68a6faadd1dd1b8b911ad02863a6 Mon Sep 17 00:00:00 2001
From: Miguel Camba
Date: Fri, 27 Apr 2018 17:47:32 +0200
Subject: [PATCH 25/34] Making helpers more async (#1100)
* Fix last set of tests
* Add two more tests
---
addon-test-support/helpers.js | 28 +-
tests/integration/components/constants.js | 11 -
.../components/power-select/a11y-test.js | 40 +-
.../power-select/custom-search-test.js | 112 +++--
.../customization-with-components-test.js | 14 +-
.../components/power-select/disabled-test.js | 6 +-
.../power-select/ember-data-test.js | 17 +-
.../power-select/general-behaviour-test.js | 104 +++--
.../components/power-select/groups-test.js | 12 +-
.../power-select/keyboard-control-test.js | 53 ++-
.../power-select/mouse-control-test.js | 3 +-
.../components/power-select/multiple-test.js | 32 +-
.../power-select/public-actions-test.js | 98 ++---
.../power-select/type-ahead-test.js | 62 +--
tests/integration/helpers-test.js | 8 +-
yarn.lock | 384 +++++++++---------
16 files changed, 473 insertions(+), 511 deletions(-)
diff --git a/addon-test-support/helpers.js b/addon-test-support/helpers.js
index 7a23932f2..922463c5f 100644
--- a/addon-test-support/helpers.js
+++ b/addon-test-support/helpers.js
@@ -1,6 +1,6 @@
import { deprecate } from '@ember/debug';
import { registerAsyncHelper } from '@ember/test';
-import { click, fillIn, keyEvent, triggerEvent, findAll } from 'ember-native-dom-helpers';
+import { click, fillIn, triggerKeyEvent, triggerEvent } from '@ember/test-helpers';
import {
selectChoose as _selectChoose,
selectSearch as _selectSearch,
@@ -15,19 +15,21 @@ import {
* given text
*/
export function findContains(selector, text) {
- return findAll(selector).filter((e) => e.textContent.trim().indexOf(text) > -1)[0];
+ return [].slice.apply(document.querySelectorAll(selector)).filter((e) => {
+ return e.textContent.trim().indexOf(text) > -1
+ })[0];
}
-export function nativeMouseDown(selectorOrDomElement, options) {
- triggerEvent(selectorOrDomElement, 'mousedown', options);
+export async function nativeMouseDown(selectorOrDomElement, options) {
+ return triggerEvent(selectorOrDomElement, 'mousedown', options);
}
-export function nativeMouseUp(selectorOrDomElement, options) {
- triggerEvent(selectorOrDomElement, 'mouseup', options);
+export async function nativeMouseUp(selectorOrDomElement, options) {
+ return triggerEvent(selectorOrDomElement, 'mouseup', options);
}
-export function triggerKeydown(domElement, k) {
- keyEvent(domElement, 'keydown', k);
+export async function triggerKeydown(domElement, k) {
+ return triggerKeyEvent(domElement, 'keydown', k);
}
export function typeInSearch(scopeOrText, text) {
@@ -49,7 +51,7 @@ export function typeInSearch(scopeOrText, text) {
return fillIn(selectors, text);
}
-export function clickTrigger(scope, options = {}) {
+export async function clickTrigger(scope, options = {}) {
let selector = '.ember-power-select-trigger';
if (scope) {
selector = `${scope} ${selector}`;
@@ -57,13 +59,13 @@ export function clickTrigger(scope, options = {}) {
return click(selector, options);
}
-export function nativeTouch(selectorOrDomElement) {
+export async function nativeTouch(selectorOrDomElement) {
triggerEvent(selectorOrDomElement, 'touchstart');
- triggerEvent(selectorOrDomElement, 'touchend');
+ return triggerEvent(selectorOrDomElement, 'touchend');
}
-export function touchTrigger() {
- nativeTouch('.ember-power-select-trigger');
+export async function touchTrigger() {
+ return nativeTouch('.ember-power-select-trigger');
}
export async function selectChoose(cssPathOrTrigger, valueOrSelector, optionIndex) {
diff --git a/tests/integration/components/constants.js b/tests/integration/components/constants.js
index 3df44873b..17bcef66a 100644
--- a/tests/integration/components/constants.js
+++ b/tests/integration/components/constants.js
@@ -130,14 +130,3 @@ export const namesStartingWithA = [
'Ashley',
'Axel'
];
-
-const ABC = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z'];
-export function charCode(letter) {
- let idx = ABC.indexOf(letter.toLowerCase());
-
- if (idx === -1) {
- return null;
- }
-
- return idx + 65;
-}
diff --git a/tests/integration/components/power-select/a11y-test.js b/tests/integration/components/power-select/a11y-test.js
index f2ae0f551..ec2d29274 100644
--- a/tests/integration/components/power-select/a11y-test.js
+++ b/tests/integration/components/power-select/a11y-test.js
@@ -18,7 +18,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown > .ember-power-select-options').hasAttribute('role', 'listbox', 'The top-level list has `role=listbox`');
let nestedOptionList = document.querySelectorAll('.ember-power-select-options .ember-power-select-options');
[].slice.call(nestedOptionList).forEach((e) => assert.dom(e).hasAttribute('role', 'group'));
@@ -34,7 +34,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown > .ember-power-select-options').hasAttribute('role', 'listbox', 'The top-level list has `role=listbox`');
let nestedOptionList = document.querySelectorAll('.ember-power-select-options .ember-power-select-options');
[].slice.call(nestedOptionList).forEach((e) => assert.dom(e).hasAttribute('role', 'group'));
@@ -50,7 +50,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
[].slice.call(document.querySelectorAll('.ember-power-select-option')).forEach((e) => assert.dom(e).hasAttribute('role', 'option'));
});
@@ -64,7 +64,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
[].slice.call(document.querySelectorAll('.ember-power-select-option')).forEach((e) => assert.dom(e).hasAttribute('role', 'option'));
});
@@ -79,7 +79,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom(findContains('.ember-power-select-option', 'two')).hasAttribute('aria-selected', 'true', 'the selected option has aria-selected=true');
assert.dom('.ember-power-select-option[aria-selected="false"]').exists({ count: numbers.length - 1 }, 'All other options have aria-selected=false');
});
@@ -95,7 +95,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom(findContains('.ember-power-select-option', 'two')).hasAttribute('aria-selected', 'true', 'the first selected option has aria-selected=true');
assert.dom(findContains('.ember-power-select-option', 'four')).hasAttribute('aria-selected', 'true', 'the second selected option has aria-selected=true');
assert.dom('.ember-power-select-option[aria-selected="false"]').exists({ count: numbers.length - 2 }, 'All other options have aria-selected=false');
@@ -111,7 +111,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom(findContains('.ember-power-select-option', 'one')).hasAttribute('aria-current', 'true', 'the highlighted option has aria-current=true');
assert.dom('.ember-power-select-option[aria-current="false"]').exists({ count: numbers.length - 1 }, 'All other options have aria-current=false');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
@@ -129,7 +129,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom(findContains('.ember-power-select-option', 'one')).hasAttribute('aria-current', 'true', 'the highlighted option has aria-current=true');
assert.dom('.ember-power-select-option[aria-current="false"]').exists({ count: numbers.length - 1 }, 'All other options have aria-current=false');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 40);
@@ -147,7 +147,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-option[aria-disabled=true]').exists({ count: 3 }, 'Three of them are disabled');
});
@@ -161,7 +161,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-option[aria-disabled=true]').exists({ count: 3 }, 'Three of them are disabled');
});
@@ -175,7 +175,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-trigger').hasAttribute('role', 'button', 'The trigger has role button');
assert.dom('.ember-power-select-trigger').hasAttribute('aria-owns', /^ember-basic-dropdown-content-ember\d+$/, 'aria-owns points to the dropdown');
});
@@ -190,7 +190,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-trigger').hasAttribute('role', 'button', 'The trigger has role button');
assert.dom('.ember-power-select-trigger').hasAttribute('aria-owns', /^ember-basic-dropdown-content-ember\d+$/, 'aria-owns points to the dropdown');
});
@@ -206,7 +206,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
assert.dom('.ember-power-select-trigger').doesNotHaveAttribute('aria-expanded', 'Not expanded');
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-trigger').hasAttribute('aria-expanded', 'true', 'Expanded');
});
@@ -221,7 +221,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
`);
assert.dom('.ember-power-select-trigger').doesNotHaveAttribute('aria-expanded', 'Not expanded');
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-trigger').hasAttribute('aria-expanded', 'true', 'Expanded');
});
@@ -235,7 +235,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-options').hasAttribute('id', /^ember-power-select-options-ember\d+$/, 'The search has a unique id');
});
@@ -249,7 +249,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-options').hasAttribute('id', /^ember-power-select-options-ember\d+$/, 'The search has a unique id');
});
@@ -263,7 +263,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-search-input').hasAttribute('type', 'search', 'The type of the input is `search`');
assert.dom('.ember-power-select-search-input').hasAttribute('aria-controls', /^ember-power-select-options-ember\d+$/, 'The `aria-controls` points to the id of the listbox');
});
@@ -278,7 +278,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('type', 'search', 'The type of the input is `search`');
assert.dom('.ember-power-select-trigger-multiple-input').hasAttribute('aria-controls', /^ember-power-select-options-ember\d+$/, 'The `aria-controls` points to the id of the listbox');
});
@@ -293,7 +293,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-options').hasAttribute('aria-controls', /^ember-power-select-trigger-ember\d+$/, 'The listbox controls the trigger');
});
@@ -307,7 +307,7 @@ module('Integration | Component | Ember Power Select (Accesibility)', function(h
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-options').hasAttribute('aria-controls', /^ember-power-select-trigger-ember\d+$/, 'The listbox controls the trigger');
});
diff --git a/tests/integration/components/power-select/custom-search-test.js b/tests/integration/components/power-select/custom-search-test.js
index 58ab08f7b..e44e701e0 100644
--- a/tests/integration/components/power-select/custom-search-test.js
+++ b/tests/integration/components/power-select/custom-search-test.js
@@ -3,7 +3,7 @@ import { later } from '@ember/runloop';
import { task, timeout } from 'ember-concurrency';
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render, settled, click} from '@ember/test-helpers';
+import { render, settled, click, waitFor } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
import { numbers, countries } from '../constants';
@@ -23,7 +23,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-option').hasText('Type to search', 'The dropdown shows the "type to search" message');
});
@@ -45,6 +45,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
}, 100);
}));
clickTrigger();
+ await waitFor('.ember-power-select-dropdown');
assert.dom('.ember-power-select-dropdown').doesNotIncludeText('Type to search', 'The type to search message doesn\'t show');
assert.dom('.ember-power-select-dropdown').includesText('Loading options...', '"Loading options..." message appears');
});
@@ -59,7 +60,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-option').hasText('Type to search');
assert.dom('.ember-power-select-option').hasClass('ember-power-select-option--search-message', 'The option with the search message has a special class');
});
@@ -74,7 +75,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-option').hasText('Type the name of the thing');
});
@@ -91,8 +92,8 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
- typeInSearch('teen');
+ await clickTrigger();
+ await typeInSearch('teen');
assert.dom('.ember-power-select-option').exists({ count: 7 });
});
@@ -113,7 +114,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
await settled()
@@ -137,9 +138,10 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown').includesText('Type to search', 'The type to search message is displayed');
typeInSearch('teen');
+ await waitFor('.ember-power-select-option:not(.ember-power-select-option--search-message)');
assert.dom('.ember-power-select-dropdown').doesNotIncludeText('Type to search', 'The type to search message dissapeared');
assert.dom('.ember-power-select-dropdown').includesText('Loading options...', '"Loading options..." message appears');
});
@@ -161,9 +163,8 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
- typeInSearch('teen');
- await settled();
+ await clickTrigger();
+ await typeInSearch('teen');
assert.dom('.ember-power-select-option').includesText('No results found', 'The default "No results" message renders');
});
@@ -184,7 +185,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
await settled();
assert.dom('.ember-power-select-option').includesText('Meec. Try again', 'The customized "No results" message renders');
@@ -209,7 +210,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
await settled();
assert.dom('.ember-power-select-dropdown .foo-bar').exists('The alternate block message gets rendered');
@@ -265,7 +266,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
await settled();
@@ -291,7 +292,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-option:nth-child(3)').hasAttribute('aria-current', 'true', 'The 3rd result is highlighted');
typeInSearch('teen');
@@ -313,7 +314,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
`);
await clickTrigger();
- typeInSearch('teen');
+ await typeInSearch('teen');
assert.dom('.ember-power-select-option').exists({ count: 7 }, 'Results are filtered');
assert.dom('.ember-power-select-search-input').hasValue('teen');
await click('#different-node');
@@ -332,7 +333,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
return new RSVP.Promise(function(resolve) {
later(function() {
resolve(numbers.filter((str) => str.indexOf(term) > -1));
- }, 50);
+ }, 150);
});
};
@@ -343,9 +344,10 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-option').exists({ count: 20 }, 'All the options are shown');
typeInSearch('teen');
+ await waitFor('.ember-power-select-option--loading-message');
assert.dom('.ember-power-select-option').exists({ count: 21 }, 'All the options are shown and also the loading message');
assert.dom('.ember-power-select-option').hasText('Loading options...');
await settled();
@@ -369,7 +371,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-option').exists({ count: 20 }, 'All the options are shown');
typeInSearch('teen');
@@ -449,7 +451,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
setTimeout(function() {
typeInSearch('t');
@@ -465,12 +467,11 @@ module('Integration | Component | Ember Power Select (Custom search function)',
});
test('The lastSearchedText of the yielded publicAPI in single selects is updated only when the async search for it finishes', async function(assert) {
- let done = assert.async();
assert.expect(3);
this.numbers = numbers;
this.searchFn = function(term) {
return new RSVP.Promise(function(resolve) {
- setTimeout(function() {
+ later(function() {
resolve(numbers.filter((str) => str.indexOf(term) > -1));
}, 100);
});
@@ -482,24 +483,21 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
- typeInSearch('teen');
- setTimeout(function() {
- assert.dom('.ember-power-select-option').hasText('thirteen:teen', 'The results and the lastSearchedText have updated');
- typeInSearch('four');
- assert.dom('.ember-power-select-option').hasText('Loading options...', 'There is a search going on');
- assert.dom('.ember-power-select-option:nth-child(2)').hasText('thirteen:teen', 'The results and the lastSearchedText are still the same because the search has not finished yet');
- done();
- }, 150);
+ await clickTrigger();
+ await typeInSearch('teen');
+ assert.dom('.ember-power-select-option').hasText('thirteen:teen', 'The results and the lastSearchedText have updated');
+ typeInSearch('four');
+ await waitFor('.ember-power-select-option--loading-message');
+ assert.dom('.ember-power-select-option').hasText('Loading options...', 'There is a search going on');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('thirteen:teen', 'The results and the lastSearchedText are still the same because the search has not finished yet');
});
test('The lastSearchedText of the yielded publicAPI in multiple selects is updated only when the async search for it finishes', async function(assert) {
- let done = assert.async();
assert.expect(3);
this.numbers = numbers;
this.searchFn = function(term) {
return new RSVP.Promise(function(resolve) {
- setTimeout(function() {
+ later(function() {
resolve(numbers.filter((str) => str.indexOf(term) > -1));
}, 100);
});
@@ -511,26 +509,23 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select-multiple}}
`);
- clickTrigger();
- typeInSearch('teen');
- setTimeout(function() {
- assert.dom('.ember-power-select-option').hasText('thirteen:teen', 'The results and the searchTerm have updated');
- typeInSearch('four');
- assert.dom('.ember-power-select-option').hasText('Loading options...', 'There is a search going on');
- assert.dom('.ember-power-select-option:nth-child(2)').hasText('thirteen:teen', 'The results and the searchTerm are still the same because the search has not finished yet');
- done();
- }, 150);
+ await clickTrigger();
+ await typeInSearch('teen');
+ assert.dom('.ember-power-select-option').hasText('thirteen:teen', 'The results and the searchTerm have updated');
+ typeInSearch('four');
+ await waitFor('.ember-power-select-option--loading-message');
+ assert.dom('.ember-power-select-option').hasText('Loading options...', 'There is a search going on');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('thirteen:teen', 'The results and the searchTerm are still the same because the search has not finished yet');
});
test('BUGFIX: Destroy a component why an async search is pending does not cause an error', async function(assert) {
- let done = assert.async();
assert.expect(0); // This test has no assertions. The fact that nothing fails is the proof that it works
this.numbers = numbers;
this.visible = true;
this.searchFn = function(term) {
return new RSVP.Promise(function(resolve) {
- setTimeout(function() {
+ later(function() {
resolve(numbers.filter((str) => str.indexOf(term) > -1));
}, 200);
});
@@ -544,12 +539,9 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/if}}
`);
- clickTrigger();
- typeInSearch('teen');
+ await clickTrigger();
+ await typeInSearch('teen');
this.set('visible', false);
- setTimeout(() => {
- done();
- }, 150);
});
test('BUGFIX: When the given options are a promise and a search function is provided, clearing the search must display the results of the original promise', async function(assert) {
@@ -566,11 +558,11 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-option').exists({ count: 20 }, 'There is 20 options');
- typeInSearch('teen');
+ await typeInSearch('teen');
assert.dom('.ember-power-select-option').exists({ count: 7 }, 'There is 7 options');
- typeInSearch('');
+ await typeInSearch('');
assert.dom('.ember-power-select-option').exists({ count: 20 }, 'There is 20 options again§');
});
@@ -607,7 +599,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
setTimeout(function() {
@@ -637,7 +629,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
setTimeout(function() {
@@ -669,7 +661,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/unless}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
setTimeout(() => {
@@ -699,7 +691,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
setTimeout(() => {
@@ -729,7 +721,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
setTimeout(function() {
@@ -759,7 +751,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
setTimeout(function() {
@@ -791,7 +783,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/unless}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
setTimeout(() => {
@@ -821,7 +813,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
typeInSearch('teen');
setTimeout(() => {
diff --git a/tests/integration/components/power-select/customization-with-components-test.js b/tests/integration/components/power-select/customization-with-components-test.js
index 2c6b249f4..93c0a464b 100644
--- a/tests/integration/components/power-select/customization-with-components-test.js
+++ b/tests/integration/components/power-select/customization-with-components-test.js
@@ -72,7 +72,7 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-options').includesText('Countries:', 'The given component is rendered');
assert.dom('.ember-power-select-options').includesText('3. Russia', 'The component has access to the options');
});
@@ -89,7 +89,7 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-options').includesText('Countries:', 'The given component is rendered');
assert.dom('.ember-power-select-options').includesText('3. RU', 'The component uses the field in the extra has to render the options');
});
@@ -112,7 +112,7 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown #custom-before-options-p-tag').exists('The custom component is rendered instead of the usual search bar');
assert.dom('.ember-power-select-dropdown #custom-before-options-p-tag').hasText('inception', 'The placeholder attribute is passed through.');
assert.dom('.ember-power-select-dropdown .ember-power-select-placeholder').exists('The placeholder component is passed through.');
@@ -131,7 +131,7 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown #custom-after-options-p-tag').exists('The custom component is rendered instead of the usual search bar');
assert.dom('.ember-power-select-search-input').exists('The search input is still visible');
});
@@ -202,7 +202,7 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown #custom-search-message-p-tag').exists('The custom component is rendered instead of the usual message');
});
@@ -240,7 +240,7 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-options .custom-component').exists({ count: numberOfGroups });
});
@@ -270,6 +270,6 @@ module('Integration | Component | Ember Power Select (Customization using compon
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
});
});
diff --git a/tests/integration/components/power-select/disabled-test.js b/tests/integration/components/power-select/disabled-test.js
index 1ec5905bf..f74f4336c 100644
--- a/tests/integration/components/power-select/disabled-test.js
+++ b/tests/integration/components/power-select/disabled-test.js
@@ -127,7 +127,7 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
`);
await clickTrigger();
- typeInSearch('Br');
+ await typeInSearch('Br');
assert.dom('.ember-power-select-option[aria-current="true"]').doesNotExist('Nothing is highlighted');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
@@ -145,7 +145,7 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
`);
await clickTrigger();
- typeInSearch('o'); // Finds ["Portugal", "United Kingdom"]
+ await typeInSearch('o'); // Finds ["Portugal", "United Kingdom"]
assert.dom('.ember-power-select-option').exists({ count: 2 }, 'There is two results');
assert.dom('.ember-power-select-option[aria-disabled="true"]').exists({ count: 1 }, 'One is disabled');
assert.dom('.ember-power-select-option[aria-current="true"]').exists({ count: 1 }, 'One element is highlighted');
@@ -197,7 +197,7 @@ module('Integration | Component | Ember Power Select (Disabled)', function(hooks
await clickTrigger();
assert.dom('.ember-power-select-group[aria-disabled="true"]').exists({ count: 1 }, 'one group is disabled');
- typeInSearch('fiv');
+ await typeInSearch('fiv');
assert.dom('.ember-power-select-group[aria-disabled="true"]').exists({ count: 1 }, 'one group is still disabled');
});
diff --git a/tests/integration/components/power-select/ember-data-test.js b/tests/integration/components/power-select/ember-data-test.js
index 5362d52bf..01379ab88 100644
--- a/tests/integration/components/power-select/ember-data-test.js
+++ b/tests/integration/components/power-select/ember-data-test.js
@@ -1,6 +1,6 @@
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render, settled, click } from '@ember/test-helpers';
+import { render, settled, click, waitFor } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger } from 'ember-power-select/test-support/helpers';
import emberDataInitializer from '../../../../initializers/ember-data';
@@ -27,11 +27,12 @@ module('Integration | Component | Ember Power Select (Ember-data integration)',
`);
this.set('users', this.store.findAll('user'));
- clickTrigger();
+ let promise = clickTrigger();
+ await waitFor('.ember-power-select-option');
assert.dom('.ember-power-select-option').hasText('Loading options...', 'The loading message appears while the promise is pending');
- await settled();
+ await promise;
assert.dom('.ember-power-select-option').exists({ count: 10 }, 'Once the collection resolves the options render normally');
- typeInSearch('2');
+ await typeInSearch('2');
assert.dom('.ember-power-select-option').exists({ count: 1 }, 'Filtering works');
});
@@ -46,12 +47,12 @@ module('Integration | Component | Ember Power Select (Ember-data integration)',
`);
this.set('users', this.store.query('user', { foo: 'bar' }));
- clickTrigger();
+ let promise = clickTrigger();
+ await waitFor('.ember-power-select-option');
assert.dom('.ember-power-select-option').hasText('Loading options...', 'The loading message appears while the promise is pending')
- await settled();
-
+ await promise;
assert.dom('.ember-power-select-option').exists({ count: 10 }, 'Once the collection resolves the options render normally');
- typeInSearch('2');
+ await typeInSearch('2');
assert.dom('.ember-power-select-option').exists({ count: 1 }, 'Filtering works');
});
diff --git a/tests/integration/components/power-select/general-behaviour-test.js b/tests/integration/components/power-select/general-behaviour-test.js
index d71c95ccd..123887474 100644
--- a/tests/integration/components/power-select/general-behaviour-test.js
+++ b/tests/integration/components/power-select/general-behaviour-test.js
@@ -1,12 +1,12 @@
import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
-import { render, click, triggerKeyEvent, triggerEvent, focus, settled } from '@ember/test-helpers';
+import { render, click, triggerKeyEvent, triggerEvent, focus, settled, waitFor } from '@ember/test-helpers';
import hbs from 'htmlbars-inline-precompile';
import { typeInSearch, clickTrigger, findContains } from 'ember-power-select/test-support/helpers';
import RSVP from 'rsvp';
import EmberObject, { get } from '@ember/object';
import { A } from '@ember/array';
-import { run } from '@ember/runloop';
+import { run, later } from '@ember/runloop';
import { numbers, names, countries } from '../constants';
import PromiseProxyMixin from '@ember/object/promise-proxy-mixin';
import ArrayProxy from '@ember/array/proxy';
@@ -126,12 +126,13 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
this.set('numbersPromise', new RSVP.Promise(function(resolve) {
- run.later(function() {
+ later(function() {
resolve(numbers);
}, 150);
}));
clickTrigger();
+ await waitFor('.ember-power-select-options');
assert.dom('.ember-power-select-option').hasText('Loading options...', 'The loading message appears while the promise is pending');
assert.dom('.ember-power-select-option').hasClass('ember-power-select-option--loading-message', 'The row has a special class to differentiate it from regular options');
await settled()
@@ -150,7 +151,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
this.set('numbersPromise', new RSVP.Promise(function(resolve) {
- run.later(function() {
+ later(function() {
resolve(numbers);
}, 100);
}));
@@ -292,7 +293,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
this.search = () => {
return new RSVP.Promise(function(resolve) {
resolve(data);
- run.later(function() {
+ later(function() {
data.pushObject('one');
}, 100);
});
@@ -321,7 +322,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
this.search = () => {
return new RSVP.Promise(function(resolve) {
resolve(data);
- run.later(function() {
+ later(function() {
data.pushObject('owner');
}, 100);
});
@@ -403,11 +404,11 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- typeInSearch('tw');
+ await typeInSearch('tw');
assert.dom('.ember-power-select-option').hasText('tw:two', 'Each option receives the public API');
await click('.ember-power-select-option');
await clickTrigger();
- typeInSearch('thr');
+ await typeInSearch('thr');
assert.dom('.ember-power-select-trigger').hasText('thr:two', 'The trigger also receives the public API');
});
@@ -435,7 +436,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
await clickTrigger();
assert.dom('.ember-power-select-option').exists({ count: 1 });
assert.dom('.ember-power-select-option').hasText('Type to search');
- typeInSearch('foo');
+ await typeInSearch('foo');
assert.dom('.ember-power-select-option').exists({ count: 1 });
assert.dom('.ember-power-select-option').hasText('No results found');
});
@@ -462,7 +463,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
assert.dom('.ember-power-select-option').exists({ count: 0 });
- typeInSearch('foo');
+ await typeInSearch('foo');
assert.dom('.ember-power-select-option').exists({ count: 1 });
assert.dom('.ember-power-select-option').hasText('No results found');
});
@@ -557,14 +558,14 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- typeInSearch('mar');
+ await typeInSearch('mar');
assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only 2 results match the search');
assert.dom('.ember-power-select-option:nth-child(1)').hasText('MarÃa');
assert.dom('.ember-power-select-option:nth-child(2)').hasText('Marta');
- typeInSearch('mari');
+ await typeInSearch('mari');
assert.dom('.ember-power-select-option').exists({ count: 1 }, 'Only 1 results match the search');
assert.dom('.ember-power-select-option:nth-child(1)').hasText('MarÃa');
- typeInSearch('o');
+ await typeInSearch('o');
assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only 2 results match the search');
assert.dom('.ember-power-select-option:nth-child(1)').hasText('Søren Larsen');
assert.dom('.ember-power-select-option:nth-child(2)').hasText('João');
@@ -585,9 +586,9 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- typeInSearch('on');
+ await typeInSearch('on');
assert.dom('.ember-power-select-option').hasText('No results found', 'No number ends in "on"');
- typeInSearch('teen');
+ await typeInSearch('teen');
assert.dom('.ember-power-select-option').exists({ count: 7 }, 'There is 7 number that end in "teen"');
});
@@ -672,14 +673,14 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- typeInSearch('mar');
+ await typeInSearch('mar');
assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only 2 results match the search');
assert.dom('.ember-power-select-option:nth-child(1)').hasText('MarÃa Murray');
assert.dom('.ember-power-select-option:nth-child(2)').hasText('Marta Stinson');
- typeInSearch('mari');
+ await typeInSearch('mari');
assert.dom('.ember-power-select-option').exists({ count: 1 }, 'Only 1 results match the search');
assert.dom('.ember-power-select-option:nth-child(1)').hasText('MarÃa Murray');
- typeInSearch('o');
+ await typeInSearch('o');
assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only 2 results match the search');
assert.dom('.ember-power-select-option:nth-child(1)').hasText('Søren Williams');
assert.dom('.ember-power-select-option:nth-child(2)').hasText('João Jin');
@@ -708,7 +709,7 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- typeInSearch('s');
+ await typeInSearch('s');
assert.dom('.ember-power-select-option').exists({ count: 3 }, 'Only 3 results match the search');
assert.dom('.ember-power-select-option:nth-child(1)').hasText('Søren Williams');
assert.dom('.ember-power-select-option:nth-child(2)').hasText('Marta Stinson');
@@ -755,11 +756,10 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
});
test('If the passed options is a promise that is resolved, searching should filter the results from a promise', async function(assert) {
- let done = assert.async();
assert.expect(5);
this.numbersPromise = new RSVP.Promise(function(resolve) {
- run.later(function() {
+ later(function() {
resolve(numbers);
}, 100);
});
@@ -770,17 +770,16 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
- setTimeout(function() {
- clickTrigger();
- typeInSearch('o');
+ await new RSVP.Promise((resolve) => setTimeout(resolve, 150));
- assert.dom('.ember-power-select-option').exists({ count: 4 }, 'The dropdown is opened and results shown.');
- assert.dom('.ember-power-select-option:nth-child(1)').hasText('one');
- assert.dom('.ember-power-select-option:nth-child(2)').hasText('two');
- assert.dom('.ember-power-select-option:nth-child(3)').hasText('four');
- assert.dom('.ember-power-select-option:nth-child(4)').hasText('fourteen');
- done();
- }, 150);
+ await clickTrigger();
+ await typeInSearch('o');
+
+ assert.dom('.ember-power-select-option').exists({ count: 4 }, 'The dropdown is opened and results shown.');
+ assert.dom('.ember-power-select-option:nth-child(1)').hasText('one');
+ assert.dom('.ember-power-select-option:nth-child(2)').hasText('two');
+ assert.dom('.ember-power-select-option:nth-child(3)').hasText('four');
+ assert.dom('.ember-power-select-option:nth-child(4)').hasText('fourteen');
});
test('Disabled single selects don\'t have a clear button even if `allowClear` is true', async function(assert) {
@@ -807,9 +806,10 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
this.set('selected', new RSVP.Promise(function(resolve) {
- run.later(resolve, numbers[3], 50);
+ later(resolve, numbers[3], 100);
}));
clickTrigger();
+ await waitFor('.ember-power-select-options')
assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one', 'The first element is highlighted');
assert.dom('.ember-power-select-option[aria-selected="true"]').doesNotExist('no element is selected');
assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
@@ -834,7 +834,6 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
});
test('If the passed selected element is a pending promise that resolves while the select is opened, the highlighted & selected elements get updated, along with the trigger', async function(assert) {
- let done = assert.async();
assert.expect(6);
this.numbers = numbers;
@@ -844,20 +843,19 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
{{/power-select}}
`);
this.set('selected', new RSVP.Promise(function(resolve) {
- run.later(resolve, numbers[3], 50);
+ later(resolve, numbers[3], 100);
}));
clickTrigger();
+ await waitFor('.ember-power-select-options')
assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one', 'The first element is highlighted');
assert.dom('.ember-power-select-option[aria-selected="true"]').doesNotExist('no element is selected');
assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
- setTimeout(function() {
- assert.dom('.ember-power-select-option[aria-current="true"]').hasText('four', 'The 4th element is highlighted');
- assert.dom('.ember-power-select-option[aria-selected="true"]').hasText('four', 'The 4th element is highlighted');
- assert.dom('.ember-power-select-trigger').hasText('four', 'The trigger has the proper content');
- done();
- }, 100);
+ await this.get('selected');
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('four', 'The 4th element is highlighted');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').hasText('four', 'The 4th element is highlighted');
+ assert.dom('.ember-power-select-trigger').hasText('four', 'The trigger has the proper content');
});
test('When a promise resolves it doesn\'t overwrite a previous value if it isn\'t the same promise it resolved from', async function(assert) {
@@ -871,33 +869,27 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
let promise1 = new RSVP.Promise(function(resolve) {
- run.later(resolve, numbers[3], 400);
+ later(resolve, numbers[3], 400);
});
let promise2 = new RSVP.Promise(function(resolve) {
- run.later(resolve, numbers[4], 300);
+ later(resolve, numbers[4], 300);
});
this.set('selected', promise1);
- await new RSVP.Promise(function(resolve) {
- run.later(resolve, 20);
- });
+ await new RSVP.Promise((resolve) => later(resolve, 20));
this.set('selected', promise2);
clickTrigger();
-
+ await waitFor('.ember-power-select-options');
assert.dom('.ember-power-select-option[aria-current="true"]').hasText('one', 'The first element is highlighted');
assert.dom('.ember-power-select-option[aria-selected="true"]').doesNotExist('no element is selected');
assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
- return new RSVP.Promise(function(resolve) {
- setTimeout(function() {
- assert.dom('.ember-power-select-option[aria-current="true"]').hasText('five', 'The 5th element is highlighted');
- assert.dom('.ember-power-select-option[aria-selected="true"]').hasText('five', 'The 5th element is highlighted');
- assert.dom('.ember-power-select-trigger').hasText('five', 'The trigger has the proper content');
- resolve();
- }, 500);
- });
+ await promise1;
+ assert.dom('.ember-power-select-option[aria-current="true"]').hasText('five', 'The 5th element is highlighted');
+ assert.dom('.ember-power-select-option[aria-selected="true"]').hasText('five', 'The 5th element is highlighted');
+ assert.dom('.ember-power-select-trigger').hasText('five', 'The trigger has the proper content');
});
// This test also fails randomly. Refactor.
@@ -1112,10 +1104,10 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
`);
await clickTrigger();
- typeInSearch('M');
+ await typeInSearch('M');
await click('.ember-power-select-option:nth-child(2)');
await clickTrigger();
- typeInSearch('i');
+ await typeInSearch('i');
assert.dom('.ember-power-select-option:nth-child(1)').hasAttribute('aria-selected', 'true', 'The item in the list is marked as selected');
await click('.ember-power-select-option:nth-child(1)');
assert.equal(onChangeInvocationsCount, 1);
diff --git a/tests/integration/components/power-select/groups-test.js b/tests/integration/components/power-select/groups-test.js
index 7961d2550..89dc4c7b6 100644
--- a/tests/integration/components/power-select/groups-test.js
+++ b/tests/integration/components/power-select/groups-test.js
@@ -20,7 +20,7 @@ module('Integration | Component | Ember Power Select (Groups)', function(hooks)
assert.notOk(find('.ember-power-select-dropdown'), 'Dropdown is not rendered');
- clickTrigger();
+ await clickTrigger();
let rootLevelGroups = document.querySelectorAll('.ember-power-select-dropdown > .ember-power-select-options > .ember-power-select-group');
let rootLevelOptions = document.querySelectorAll('.ember-power-select-dropdown > .ember-power-select-options > .ember-power-select-option');
@@ -54,7 +54,7 @@ module('Integration | Component | Ember Power Select (Groups)', function(hooks)
`);
assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is not rendered');
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-option').exists({ count: 4 });
assert.dom('.ember-power-select-option:nth-child(2)').hasText('Tigers');
});
@@ -68,13 +68,13 @@ module('Integration | Component | Ember Power Select (Groups)', function(hooks)
{{option}}
{{/power-select}}
`);
- clickTrigger();
- typeInSearch('ve');
+ await clickTrigger();
+ await typeInSearch('ve');
let groupNames = Array.from(document.querySelectorAll('.ember-power-select-group-name')).map((e) => e.textContent.trim());
let optionValues = Array.from(document.querySelectorAll('.ember-power-select-option')).map((e) => e.textContent.trim());
assert.deepEqual(groupNames, ['Mediums', 'Bigs', 'Fairly big', 'Really big'], 'Only the groups with matching options are shown');
assert.deepEqual(optionValues, ['five', 'seven', 'eleven', 'twelve'], 'Only the matching options are shown');
- typeInSearch('lve');
+ await typeInSearch('lve');
groupNames = Array.from(document.querySelectorAll('.ember-power-select-group-name')).map((e) => e.textContent.trim());
assert.deepEqual(groupNames, ['Bigs', 'Really big'], 'With no depth level');
});
@@ -105,7 +105,7 @@ module('Integration | Component | Ember Power Select (Groups)', function(hooks)
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
await click(document.querySelectorAll('.ember-power-select-group-name')[1]);
assert.dom('.ember-power-select-dropdown').exists('The select is still opened');
});
diff --git a/tests/integration/components/power-select/keyboard-control-test.js b/tests/integration/components/power-select/keyboard-control-test.js
index ac87433e1..beacc2bd2 100644
--- a/tests/integration/components/power-select/keyboard-control-test.js
+++ b/tests/integration/components/power-select/keyboard-control-test.js
@@ -5,6 +5,7 @@ import hbs from 'htmlbars-inline-precompile';
import { triggerKeydown, clickTrigger, typeInSearch } from 'ember-power-select/test-support/helpers';
import { numbers, numerals, countries, countriesWithDisabled, groupedNumbers, groupedNumbersWithDisabled } from '../constants';
import { triggerKeyEvent, focus } from '@ember/test-helpers';
+import RSVP from 'rsvp';
module('Integration | Component | Ember Power Select (Keyboard control)', function(hooks) {
setupRenderingTest(hooks);
@@ -155,7 +156,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
`);
await clickTrigger();
- typeInSearch('asjdnah');
+ await typeInSearch('asjdnah');
assert.dom('.ember-power-select-trigger').hasText('two', 'Two is selected');
assert.dom('.ember-power-select-option').hasText('No results found');
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
@@ -228,7 +229,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- focus('.ember-power-select-trigger');
+ await focus('.ember-power-select-trigger');
assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
assert.dom('.ember-power-select-dropdown').exists('The select is opened');
@@ -246,7 +247,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- focus('.ember-power-select-trigger');
+ await focus('.ember-power-select-trigger');
assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 32);
assert.dom('.ember-power-select-dropdown').exists('The select is opened');
@@ -264,7 +265,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- focus('.ember-power-select-trigger');
+ await focus('.ember-power-select-trigger');
assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
assert.dom('.ember-power-select-dropdown').exists('The select is opened');
@@ -280,7 +281,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- focus('.ember-power-select-trigger');
+ await focus('.ember-power-select-trigger');
assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 38);
assert.dom('.ember-power-select-dropdown').exists('The select is opened');
@@ -482,7 +483,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- focus('.ember-power-select-trigger');
+ await focus('.ember-power-select-trigger');
assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 82, { ctrlKey: true }); // r
assert.dom('.ember-power-select-trigger').doesNotIncludeText('three', '"three" is not selected');
@@ -511,7 +512,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
assert.equal(document.querySelector('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
triggerKeydown('.ember-power-select-trigger', 78); // n
triggerKeydown('.ember-power-select-trigger', 73); // i
- triggerKeydown('.ember-power-select-trigger', 78); // n
+ await triggerKeydown('.ember-power-select-trigger', 78); // n
assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
assert.dom('.ember-power-select-option[aria-current=true]').hasText('nine', 'The option containing "nine" has been highlighted');
assert.ok(document.querySelector('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
@@ -531,7 +532,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
assert.equal(document.querySelector('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
- triggerKeydown('.ember-power-select-trigger', 104); // Numpad 8
+ await triggerKeydown('.ember-power-select-trigger', 104); // Numpad 8
assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
assert.dom('.ember-power-select-option[aria-current=true]').hasText('853', 'The option containing "853" has been highlighted');
assert.ok(document.querySelector('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
@@ -553,7 +554,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
assert.equal(document.querySelector('.ember-power-select-options').scrollTop, 0, 'The list is not scrolled');
triggerKeydown('.ember-power-select-trigger', 78); // n
triggerKeydown('.ember-power-select-trigger', 73); // i
- triggerKeydown('.ember-power-select-trigger', 78); // n
+ await triggerKeydown('.ember-power-select-trigger', 78); // n
assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
assert.dom('.ember-power-select-option[aria-current=true]').hasText('nine', 'The option containing "nine" has been highlighted');
assert.ok(document.querySelector('.ember-power-select-options').scrollTop > 0, 'The list has scrolled');
@@ -561,7 +562,6 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
});
test('The typed string gets reset after 1s idle', async function(assert) {
- let done = assert.async();
assert.expect(5);
this.numbers = numbers;
@@ -571,18 +571,16 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- focus('.ember-power-select-trigger');
+ await focus('.ember-power-select-trigger');
assert.dom('.ember-power-select-dropdown').doesNotExist( 'The dropdown is closed');
- triggerKeydown('.ember-power-select-trigger', 84); // t
- triggerKeydown('.ember-power-select-trigger', 87); // w
+ await triggerKeydown('.ember-power-select-trigger', 84); // t
+ await triggerKeydown('.ember-power-select-trigger', 87); // w
assert.dom('.ember-power-select-trigger').hasText('two', '"two" has been selected');
assert.dom('.ember-power-select-dropdown').doesNotExist( 'The dropdown is still closed');
- setTimeout(function() {
- triggerKeydown('.ember-power-select-trigger', 79); // o
- assert.dom('.ember-power-select-trigger').hasText('one', '"one" has been selected, instead of "two", because the typing started over');
- assert.dom('.ember-power-select-dropdown').doesNotExist( 'The dropdown is still closed');
- done();
- }, 1100);
+ await new RSVP.Promise((resolve) => setTimeout(resolve, 1100));
+ await triggerKeydown('.ember-power-select-trigger', 79); // o
+ assert.dom('.ember-power-select-trigger').hasText('one', '"one" has been selected, instead of "two", because the typing started over');
+ assert.dom('.ember-power-select-dropdown').doesNotExist( 'The dropdown is still closed');
});
test('Type something that doesn\'t give you any result leaves the current selection', async function(assert) {
@@ -595,14 +593,14 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
{{/power-select}}
`);
- focus('.ember-power-select-trigger');
+ await focus('.ember-power-select-trigger');
assert.dom('.ember-power-select-trigger').hasText('', 'nothing is selected');
triggerKeydown('.ember-power-select-trigger', 78); // n
triggerKeydown('.ember-power-select-trigger', 73); // i
triggerKeydown('.ember-power-select-trigger', 78); // n
- triggerKeydown('.ember-power-select-trigger', 69); // e
+ await triggerKeydown('.ember-power-select-trigger', 69); // e
assert.dom('.ember-power-select-trigger').hasText('nine', 'nine has been selected');
- triggerKeydown('.ember-power-select-trigger', 87); // w
+ await triggerKeydown('.ember-power-select-trigger', 87); // w
assert.dom('.ember-power-select-trigger').hasText('nine', 'nine is still selected because "ninew" gave no results');
});
@@ -619,7 +617,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
triggerKeydown('.ember-power-select-trigger', 80); // p
- triggerKeydown('.ember-power-select-trigger', 79); // o
+ await triggerKeydown('.ember-power-select-trigger', 79); // o
assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
assert.dom('.ember-power-select-option[aria-current=true]').hasText('Portugal', 'The option containing "Portugal" has been highlighted');
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
@@ -638,7 +636,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
triggerKeydown('.ember-power-select-trigger', 69); // e
- triggerKeydown('.ember-power-select-trigger', 76); // l
+ await triggerKeydown('.ember-power-select-trigger', 76); // l
assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
assert.dom('.ember-power-select-option[aria-current=true]').hasText('eleven', 'The option containing "eleven" has been highlighted');
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
@@ -657,7 +655,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
- triggerKeydown('.ember-power-select-trigger', 85); // u
+ await triggerKeydown('.ember-power-select-trigger', 85); // u
assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
assert.dom('.ember-power-select-option[aria-current=true]').hasText('United Kingdom', 'The option containing "United Kingdom" has been highlighted');
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
@@ -676,7 +674,7 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is open');
triggerKeydown('.ember-power-select-trigger', 84); // t
- triggerKeydown('.ember-power-select-trigger', 87); // w
+ await triggerKeydown('.ember-power-select-trigger', 87); // w
assert.dom('.ember-power-select-trigger').hasText('', 'nothing has been selected');
assert.dom('.ember-power-select-option[aria-current=true]').hasText('twelve', 'The option containing "United Kingdom" has been highlighted');
assert.dom('.ember-power-select-dropdown').exists( 'The dropdown is still closed');
@@ -813,7 +811,8 @@ module('Integration | Component | Ember Power Select (Keyboard control)', functi
focus('.ember-power-select-trigger');
assert.dom('.ember-power-select-selected-item').hasText('25');
assert.expectAssertion(() => {
- triggerKeydown('.ember-power-select-trigger', 67); // c
+ let trigger = document.querySelector('.ember-power-select-trigger');
+ trigger.dispatchEvent(new KeyboardEvent('keydown', { bubbles: true, cancelable: true, keyCode: 67 }));
}, '{{power-select}} If you want the default filtering to work on options that are not plain strings, you need to provide `searchField`');
});
});
diff --git a/tests/integration/components/power-select/mouse-control-test.js b/tests/integration/components/power-select/mouse-control-test.js
index 5a2033dd9..7c1b0536b 100644
--- a/tests/integration/components/power-select/mouse-control-test.js
+++ b/tests/integration/components/power-select/mouse-control-test.js
@@ -116,7 +116,8 @@ module('Integration | Component | Ember Power Select (Mouse control)', function(
await clickTrigger(null, { clientY: 123 });
assert.dom('.ember-power-select-dropdown').exists('The select is opened');
- await triggerEvent('.ember-power-select-option:nth-child(2)', 'mouseup', { clientY: 124 });
+
+ await triggerEvent('.ember-power-select-option:nth-child(2)', 'mousedown', { clientY: 124 });
assert.dom('.ember-power-select-dropdown').exists('The select is still opened');
await triggerEvent('.ember-power-select-option:nth-child(2)', 'mouseup', { clientY: 125 });
assert.dom('.ember-power-select-dropdown').doesNotExist('The select is closed now');
diff --git a/tests/integration/components/power-select/multiple-test.js b/tests/integration/components/power-select/multiple-test.js
index 0078ebbc3..407ad8daa 100644
--- a/tests/integration/components/power-select/multiple-test.js
+++ b/tests/integration/components/power-select/multiple-test.js
@@ -172,7 +172,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- typeInSearch('four');
+ await typeInSearch('four');
assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only two items matched the criteria');
});
@@ -195,14 +195,14 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- typeInSearch('mar');
+ await typeInSearch('mar');
assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only 2 results match the search');
assert.dom('.ember-power-select-option:nth-child(1)').hasText('MarÃa Murray');
assert.dom('.ember-power-select-option:nth-child(2)').hasText('Marta Stinson');
- typeInSearch('mari');
+ await typeInSearch('mari');
assert.dom('.ember-power-select-option').exists({ count: 1 }, 'Only 1 results match the search');
assert.dom('.ember-power-select-option').hasText('MarÃa Murray');
- typeInSearch('o');
+ await typeInSearch('o');
assert.dom('.ember-power-select-option').exists({ count: 2 }, 'Only 2 results match the search');
assert.dom('.ember-power-select-option:nth-child(1)').hasText('Søren Williams');
assert.dom('.ember-power-select-option:nth-child(2)').hasText('João Jin');
@@ -223,9 +223,9 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- typeInSearch('on');
+ await typeInSearch('on');
assert.dom('.ember-power-select-option').hasText('No results found', 'No number ends in "on"');
- typeInSearch('teen');
+ await typeInSearch('teen');
assert.dom('.ember-power-select-option').exists({ count: 7 }, 'There is 7 number that end in "teen"');
});
@@ -248,7 +248,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- typeInSearch('teen');
+ await typeInSearch('teen');
setTimeout(function() {
assert.dom('.ember-power-select-option').exists({ count: 7 });
@@ -388,7 +388,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- typeInSearch('four');
+ await typeInSearch('four');
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 8);
assert.dom('.ember-power-select-dropdown').exists('The dropown is still opened');
});
@@ -591,7 +591,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- typeInSearch('fo');
+ await typeInSearch('fo');
assert.dom('.ember-power-select-option').exists({ count: 2 }, 'The dropdown is opened and results filtered');
});
@@ -612,7 +612,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- typeInSearch('fo');
+ await typeInSearch('fo');
let done = assert.async();
setTimeout(function() {
@@ -631,11 +631,11 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- typeInSearch('tw');
+ await typeInSearch('tw');
assert.dom('.ember-power-select-option').hasText('tw:two');
await click('.ember-power-select-option');
await clickTrigger();
- typeInSearch('thr');
+ await typeInSearch('thr');
assert.dom('.ember-power-select-trigger').includesText('thr:two', 'The trigger also receives the public API');
});
@@ -650,7 +650,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- typeInSearch('asjdnah');
+ await typeInSearch('asjdnah');
assert.dom('.ember-power-select-option').hasText('No results found');
assert.dom('.ember-power-select-trigger-multiple-input').hasValue('asjdnah');
await click('#other-thing');
@@ -670,7 +670,7 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
`);
await clickTrigger();
- typeInSearch('asjdnah');
+ await typeInSearch('asjdnah');
assert.dom('.ember-power-select-option').hasText('No results found');
await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
@@ -796,9 +796,9 @@ module('Integration | Component | Ember Power Select (Multiple)', function(hooks
{{/power-select-multiple}}
`);
- typeInSearch('M');
+ await typeInSearch('M');
await click('.ember-power-select-option:nth-child(2)');
- typeInSearch('Mi');
+ await typeInSearch('Mi');
assert.dom('.ember-power-select-option').hasAttribute('aria-selected', 'true', 'The item in the list is marked as selected');
await click('.ember-power-select-option'); // select the same user again should remove it
assert.dom('.ember-power-select-multiple-option').exists({ count: 0 });
diff --git a/tests/integration/components/power-select/public-actions-test.js b/tests/integration/components/power-select/public-actions-test.js
index 63d09c8d1..904ed6b90 100644
--- a/tests/integration/components/power-select/public-actions-test.js
+++ b/tests/integration/components/power-select/public-actions-test.js
@@ -48,8 +48,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- clickTrigger();
- typeInSearch('el');
+ await clickTrigger();
+ await typeInSearch('el');
});
test('The search action of multiple selects action receives the search term and the public API', async function(assert) {
@@ -67,8 +67,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- clickTrigger();
- typeInSearch('el');
+ await clickTrigger();
+ await typeInSearch('el');
});
test('The onchange of single selects action receives the selection and the public API', async function(assert) {
@@ -86,8 +86,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- clickTrigger();
- click('.ember-power-select-option');
+ await clickTrigger();
+ await click('.ember-power-select-option');
});
test('The onchange of multiple selects action receives the selection and the public API', async function(assert) {
@@ -105,8 +105,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- clickTrigger();
- click('.ember-power-select-option');
+ await clickTrigger();
+ await click('.ember-power-select-option');
});
test('The onkeydown of single selects action receives the public API and the keydown event when fired on the searchbox', async function(assert) {
@@ -124,9 +124,9 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
- triggerKeyEvent('.ember-power-select-search-input', 'keydown', 65);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 65);
});
test('The onkeydown can be used to easily allow to select on tab', async function(assert) {
@@ -146,9 +146,9 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- clickTrigger();
- await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
- await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
+ await clickTrigger();
+ triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
+ triggerKeyEvent('.ember-power-select-trigger', 'keydown', 40);
await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 9);
assert.dom('.ember-power-select-trigger').hasText('three', 'The highlighted options has been selected');
assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is opened');
@@ -169,9 +169,9 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
- triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 65);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 65);
});
test('returning false from the `onkeydown` action prevents the default behaviour in single selects', async function(assert) {
@@ -191,9 +191,9 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 13);
assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is still closed');
- triggerKeyEvent('.ember-power-select-trigger', 'keydown', 84); // 't'
+ await triggerKeyEvent('.ember-power-select-trigger', 'keydown', 84); // 't'
assert.dom('.ember-power-select-trigger').doesNotIncludeText('two', 'nothing was selected');
});
@@ -214,7 +214,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
+ await triggerKeyEvent('.ember-power-select-trigger-multiple-input', 'keydown', 13);
assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is still closed');
});
@@ -233,7 +233,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- focus('.ember-power-select-trigger');
+ await focus('.ember-power-select-trigger');
});
test('The onfocus of multiple selects action receives the public API and the focus event', async function(assert) {
@@ -251,7 +251,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- focus('.ember-power-select-trigger');
+ await focus('.ember-power-select-trigger');
});
test('The onfocus of multiple selects also gets called when the thing getting the focus is the searbox', async function(assert) {
@@ -270,7 +270,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- focus('.ember-power-select-trigger-multiple-input');
+ await focus('.ember-power-select-trigger-multiple-input');
});
test('The onblur of single selects action receives the public API and the event', async function(assert) {
@@ -289,8 +289,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
- focus('.ember-power-select-trigger');
- focus('#other-element');
+ await focus('.ember-power-select-trigger');
+ await focus('#other-element');
});
test('The onblur of multiple selects action receives the public API and the focus event', async function(assert) {
@@ -309,8 +309,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
- focus('.ember-power-select-trigger-multiple-input');
- focus('#other-element');
+ await focus('.ember-power-select-trigger-multiple-input');
+ await focus('#other-element');
});
test('The onblur of multiple selects also gets called when the thing getting the focus is the searbox', async function(assert) {
@@ -327,8 +327,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
- clickTrigger();
- focus('#other-element');
+ await clickTrigger();
+ await focus('#other-element');
});
test('the `onopen` action is invoked just before the dropdown opens', async function(assert) {
@@ -347,7 +347,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists('Dropdown is opened');
});
@@ -368,7 +368,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown didn\'t open');
});
@@ -389,7 +389,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown didn\'t open');
});
@@ -409,8 +409,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- clickTrigger();
- clickTrigger();
+ await clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown').doesNotExist('Dropdown is closed');
});
@@ -431,9 +431,9 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists('Dropdown is open');
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists('Dropdown didn\'t close');
});
@@ -454,9 +454,9 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists('Dropdown is open');
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists('Dropdown didn\'t close');
});
@@ -477,8 +477,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- clickTrigger();
- typeInSearch('tw');
+ await clickTrigger();
+ await typeInSearch('tw');
assert.dom('.ember-power-select-option').exists({ count: 3 }, 'There is three options');
assert.dom('.ember-power-select-option:nth-child(1)').hasText('two');
assert.dom('.ember-power-select-option:nth-child(2)').hasText('twelve');
@@ -502,8 +502,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- clickTrigger();
- typeInSearch('tw');
+ await clickTrigger();
+ await typeInSearch('tw');
assert.dom('.ember-power-select-option').exists({ count: 3 }, 'There is three options');
assert.dom('.ember-power-select-option:nth-child(1)').hasText('two');
assert.dom('.ember-power-select-option:nth-child(2)').hasText('twelve');
@@ -524,8 +524,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- clickTrigger();
- typeInSearch('tw');
+ await clickTrigger();
+ await typeInSearch('tw');
assert.dom('.ember-power-select-option').exists({ count: 20 }, 'There is the same options than before');
});
@@ -543,8 +543,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- clickTrigger();
- typeInSearch('tw');
+ await clickTrigger();
+ await typeInSearch('tw');
assert.dom('.ember-power-select-option').exists({ count: 20 }, 'There is the same options than before');
});
@@ -559,7 +559,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{option}}
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-option').exists({ count: 3 }, 'There is three options');
assert.dom('.ember-power-select-option[aria-current="true"]').hasText('baz', 'The third option is highlighted');
});
@@ -579,7 +579,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-search-input').hasValue('hello', 'The search text contains the searched string');
});
@@ -598,7 +598,7 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- clickTrigger();
+ await clickTrigger();
assert.dom('.ember-power-select-trigger-multiple-input').hasValue('hello', 'The search text contains the searched string');
});
@@ -617,8 +617,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
{{/power-select-multiple}}
`);
- clickTrigger();
- typeInSearch('el');
+ await clickTrigger();
+ await typeInSearch('el');
});
test('The single component invokes the `registerAPI` action with the public API object', async function(assert) {
diff --git a/tests/integration/components/power-select/type-ahead-test.js b/tests/integration/components/power-select/type-ahead-test.js
index fa925a0ea..23d23ca4a 100644
--- a/tests/integration/components/power-select/type-ahead-test.js
+++ b/tests/integration/components/power-select/type-ahead-test.js
@@ -2,13 +2,13 @@ import { module, test } from 'qunit';
import { setupRenderingTest } from 'ember-qunit';
import hbs from 'htmlbars-inline-precompile';
import { optionAtIndex } from 'ember-power-select/utils/group-utils';
-import { triggerKeydown, clickTrigger } from 'ember-power-select/test-support/helpers';
-import { charCode, namesStartingWithA } from '../constants';
-import { render, focus } from '@ember/test-helpers';
+import { clickTrigger } from 'ember-power-select/test-support/helpers';
+import { namesStartingWithA } from '../constants';
+import { render, focus, triggerKeyEvent } from '@ember/test-helpers';
const WITH_EPS_CLOSED = {
- beforeInteraction(trigger, assert) {
- focus(trigger);
+ async beforeInteraction(trigger, assert) {
+ await focus(trigger);
assert.dom(trigger).hasText('', 'no value selected');
assert.dom('.ember-power-select-dropdown').doesNotExist('The dropdown is closed');
},
@@ -26,8 +26,8 @@ const WITH_EPS_CLOSED = {
};
const WITH_EPS_OPEN = {
- beforeInteraction(trigger, assert) {
- clickTrigger();
+ async beforeInteraction(trigger, assert) {
+ await clickTrigger();
assert.dom('.ember-power-select-dropdown').exists('The dropdown is open');
},
@@ -43,10 +43,10 @@ const WITH_EPS_OPEN = {
}
};
-function typeString(trigger, str, times = 1) {
+async function typeString(trigger, str, times = 1) {
for (let j = 0; j < times; j++) {
for (let i = 0; i < str.length; i++) {
- triggerKeydown(trigger, charCode(str.charAt(i)));
+ await triggerKeyEvent(trigger, 'keydown', str.charAt(i));
}
}
}
@@ -58,14 +58,14 @@ module('Integration | Component | Ember Power Select (Type Ahead Native Behaviou
test(`(${state}) Repeating the first character cycles through the results`, async function(assert) {
this.names = namesStartingWithA;
await render(hbs`
- {{#power-select options=names onchange=(action (mut selected)) selected=selected searchEnabled=false as |option|}}
- {{option}}
- {{/power-select}}
- `);
+ {{#power-select options=names onchange=(action (mut selected)) selected=selected searchEnabled=false as |option|}}
+ {{option}}
+ {{/power-select}}
+ `);
let trigger = this.element.querySelector('.ember-power-select-trigger');
- helpers.beforeInteraction(trigger, assert);
- typeString(trigger, 'aaa');
+ await helpers.beforeInteraction(trigger, assert);
+ await typeString(trigger, 'aaa');
helpers.checkSelectedValue(helpers.valueAt(this.names, 'aaa'.length), trigger, assert);
});
@@ -78,9 +78,12 @@ module('Integration | Component | Ember Power Select (Type Ahead Native Behaviou
`);
let trigger = this.element.querySelector('.ember-power-select-trigger');
- helpers.beforeInteraction(trigger, assert);
+ await helpers.beforeInteraction(trigger, assert);
let { length } = namesStartingWithA;
- typeString(trigger, 'a', length + 1);
+ for(let i = 0; i < length; i++) {
+ triggerKeyEvent(trigger, 'keydown', 'a');
+ }
+ await triggerKeyEvent(trigger, 'keydown', 'a');
helpers.checkSelectedValue(helpers.valueAt(this.names, length + 1), trigger, assert);
});
@@ -93,10 +96,10 @@ module('Integration | Component | Ember Power Select (Type Ahead Native Behaviou
`);
let trigger = this.element.querySelector('.ember-power-select-trigger');
- helpers.beforeInteraction(trigger, assert);
- typeString(trigger, 'aa');
- helpers.checkSelectedValue(helpers.valueAt(this.names, 'aa'.length), trigger, assert);
- typeString(trigger, 'r');
+ await helpers.beforeInteraction(trigger, assert);
+ triggerKeyEvent(trigger, 'keydown', 'a');
+ triggerKeyEvent(trigger, 'keydown', 'a');
+ await triggerKeyEvent(trigger, 'keydown', 'r');
helpers.checkSelectedValue('Aaran', trigger, assert);
assert.notEqual('Aaran', helpers.valueAt(this.names, 'aar'.length), 'Aaran would not be selected unless aa was remembered');
});
@@ -110,8 +113,11 @@ module('Integration | Component | Ember Power Select (Type Ahead Native Behaviou
`);
let trigger = this.element.querySelector('.ember-power-select-trigger');
- helpers.beforeInteraction(trigger, assert);
- typeString(trigger, 'aara');
+ await helpers.beforeInteraction(trigger, assert);
+ triggerKeyEvent(trigger, 'keydown', 'a');
+ triggerKeyEvent(trigger, 'keydown', 'a');
+ triggerKeyEvent(trigger, 'keydown', 'r');
+ await triggerKeyEvent(trigger, 'keydown', 'a');
helpers.checkSelectedValue('Aaran', trigger, assert);
});
@@ -126,14 +132,14 @@ module('Integration | Component | Ember Power Select (Type Ahead Native Behaviou
{{/power-select}}
`);
let trigger = this.element.querySelector('.ember-power-select-trigger');
- helpers.beforeInteraction(trigger, assert);
- typeString(trigger, 'f', state === 'Open' ? 1 : 2); // Normalize open closed behaviour
+ await helpers.beforeInteraction(trigger, assert);
+ await typeString(trigger, 'f', state === 'Open' ? 1 : 2); // Normalize open closed behaviour
helpers.checkSelectedValue('Fab', trigger, assert);
- typeString(trigger, 'f', 2);
+ await typeString(trigger, 'f', 2);
helpers.checkSelectedValue('Fba', trigger, assert);
- typeString(trigger, 'f');
+ await typeString(trigger, 'f');
helpers.checkSelectedValue('FFba', trigger, assert);
- typeString(trigger, 'f');
+ await typeString(trigger, 'f');
helpers.checkSelectedValue('Fbb', trigger, assert);
});
});
diff --git a/tests/integration/helpers-test.js b/tests/integration/helpers-test.js
index c3c2683c1..028ecca76 100644
--- a/tests/integration/helpers-test.js
+++ b/tests/integration/helpers-test.js
@@ -17,8 +17,8 @@ module('Integration | Helpers', function(hooks) {
{{/power-select}}
`);
- clickTrigger();
- typeInSearch('one');
+ await clickTrigger();
+ await typeInSearch('one');
assert.ok(findContains('.ember-power-select-option', 'one'));
});
@@ -37,8 +37,8 @@ module('Integration | Helpers', function(hooks) {
`);
- clickTrigger('#single-select');
- typeInSearch('#single-select', 'one');
+ await clickTrigger('#single-select');
+ await typeInSearch('#single-select', 'one');
assert.ok(findContains('#single-select .ember-power-select-option', 'one'));
});
diff --git a/yarn.lock b/yarn.lock
index e9c88d3f0..17d7c7d5a 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -10,32 +10,32 @@
ember-compatibility-helpers "^1.0.0-beta.2"
"@ember/test-helpers@^0.7.18":
- version "0.7.21"
- resolved "https://registry.yarnpkg.com/@ember/test-helpers/-/test-helpers-0.7.21.tgz#1bb6555e7d201d86800671a0ba64e70d3d23a3a0"
+ version "0.7.22"
+ resolved "https://registry.yarnpkg.com/@ember/test-helpers/-/test-helpers-0.7.22.tgz#f8a0fb23d85dec2e7e07ec6138f93e1868ae3619"
dependencies:
broccoli-funnel "^2.0.1"
- ember-cli-babel "^6.10.0"
+ ember-cli-babel "^6.12.0"
ember-cli-htmlbars-inline-precompile "^1.0.0"
"@glimmer/compiler@^0.32.3":
- version "0.32.3"
- resolved "https://registry.yarnpkg.com/@glimmer/compiler/-/compiler-0.32.3.tgz#fc15780ec38aa62b60da600618ca1f43da6b979c"
+ version "0.32.8"
+ resolved "https://registry.yarnpkg.com/@glimmer/compiler/-/compiler-0.32.8.tgz#6cfe4770ccb537af8cded8daa9d5c6392239c69f"
dependencies:
- "@glimmer/interfaces" "^0.32.3"
- "@glimmer/syntax" "^0.32.3"
- "@glimmer/util" "^0.32.3"
- "@glimmer/wire-format" "^0.32.3"
+ "@glimmer/interfaces" "^0.32.8"
+ "@glimmer/syntax" "^0.32.8"
+ "@glimmer/util" "^0.32.8"
+ "@glimmer/wire-format" "^0.32.8"
simple-html-tokenizer "^0.4.1"
"@glimmer/di@^0.2.0":
version "0.2.0"
resolved "https://registry.yarnpkg.com/@glimmer/di/-/di-0.2.0.tgz#73bfd4a6ee4148a80bf092e8a5d29bcac9d4ce7e"
-"@glimmer/interfaces@^0.32.3":
- version "0.32.3"
- resolved "https://registry.yarnpkg.com/@glimmer/interfaces/-/interfaces-0.32.3.tgz#a328344d88490c1ae765ebe18ee357ed9a66f0fb"
+"@glimmer/interfaces@^0.32.8":
+ version "0.32.8"
+ resolved "https://registry.yarnpkg.com/@glimmer/interfaces/-/interfaces-0.32.8.tgz#c5dc252fb80079ed77e7bd3d98080097eec10b28"
dependencies:
- "@glimmer/wire-format" "^0.32.3"
+ "@glimmer/wire-format" "^0.32.8"
"@glimmer/resolver@^0.4.1":
version "0.4.3"
@@ -43,24 +43,24 @@
dependencies:
"@glimmer/di" "^0.2.0"
-"@glimmer/syntax@^0.32.3":
- version "0.32.3"
- resolved "https://registry.yarnpkg.com/@glimmer/syntax/-/syntax-0.32.3.tgz#f6b035948013728e646731d774ccd8c49f7d10d1"
+"@glimmer/syntax@^0.32.8":
+ version "0.32.8"
+ resolved "https://registry.yarnpkg.com/@glimmer/syntax/-/syntax-0.32.8.tgz#be5ddb7faceb01cfe441a1adb6ba917e1af3b7fa"
dependencies:
- "@glimmer/interfaces" "^0.32.3"
- "@glimmer/util" "^0.32.3"
+ "@glimmer/interfaces" "^0.32.8"
+ "@glimmer/util" "^0.32.8"
handlebars "^4.0.6"
simple-html-tokenizer "^0.4.1"
-"@glimmer/util@^0.32.3":
- version "0.32.3"
- resolved "https://registry.yarnpkg.com/@glimmer/util/-/util-0.32.3.tgz#b73ccc1b73097ba6ec1e250954a1a2e1eb83eb48"
+"@glimmer/util@^0.32.8":
+ version "0.32.8"
+ resolved "https://registry.yarnpkg.com/@glimmer/util/-/util-0.32.8.tgz#a79f78e931bb1b77ecea4517b621224fda95d26b"
-"@glimmer/wire-format@^0.32.3":
- version "0.32.3"
- resolved "https://registry.yarnpkg.com/@glimmer/wire-format/-/wire-format-0.32.3.tgz#2f684a6d88ba7162d32cd5f01bd0b83151cdb73d"
+"@glimmer/wire-format@^0.32.8":
+ version "0.32.8"
+ resolved "https://registry.yarnpkg.com/@glimmer/wire-format/-/wire-format-0.32.8.tgz#fca4721e293799968a05a5d91ef725fc3d6cbaad"
dependencies:
- "@glimmer/util" "^0.32.3"
+ "@glimmer/util" "^0.32.8"
"@sindresorhus/is@^0.7.0":
version "0.7.0"
@@ -109,13 +109,6 @@ ajv-keywords@^2.1.0:
version "2.1.1"
resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-2.1.1.tgz#617997fc5f60576894c435f940d819e135b80762"
-ajv@^4.9.1:
- version "4.11.8"
- resolved "https://registry.yarnpkg.com/ajv/-/ajv-4.11.8.tgz#82ffb02b29e662ae53bdc20af15947706739c536"
- dependencies:
- co "^4.6.0"
- json-stable-stringify "^1.0.1"
-
ajv@^5.1.0, ajv@^5.2.3, ajv@^5.3.0:
version "5.5.2"
resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965"
@@ -396,8 +389,8 @@ babel-code-frame@^6.22.0, babel-code-frame@^6.26.0:
js-tokens "^3.0.2"
babel-core@^6.14.0, babel-core@^6.24.1, babel-core@^6.26.0:
- version "6.26.0"
- resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-6.26.0.tgz#af32f78b31a6fcef119c87b0fd8d9753f03a0bb8"
+ version "6.26.3"
+ resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-6.26.3.tgz#b2e2f09e342d0f0c88e2f02e067794125e75c207"
dependencies:
babel-code-frame "^6.26.0"
babel-generator "^6.26.0"
@@ -409,15 +402,15 @@ babel-core@^6.14.0, babel-core@^6.24.1, babel-core@^6.26.0:
babel-traverse "^6.26.0"
babel-types "^6.26.0"
babylon "^6.18.0"
- convert-source-map "^1.5.0"
- debug "^2.6.8"
+ convert-source-map "^1.5.1"
+ debug "^2.6.9"
json5 "^0.5.1"
lodash "^4.17.4"
minimatch "^3.0.4"
path-is-absolute "^1.0.1"
- private "^0.1.7"
+ private "^0.1.8"
slash "^1.0.0"
- source-map "^0.5.6"
+ source-map "^0.5.7"
babel-generator@^6.26.0:
version "6.26.1"
@@ -680,8 +673,8 @@ babel-plugin-transform-es2015-modules-amd@^6.22.0, babel-plugin-transform-es2015
babel-template "^6.24.1"
babel-plugin-transform-es2015-modules-commonjs@^6.23.0, babel-plugin-transform-es2015-modules-commonjs@^6.24.1:
- version "6.26.0"
- resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-commonjs/-/babel-plugin-transform-es2015-modules-commonjs-6.26.0.tgz#0d8394029b7dc6abe1a97ef181e00758dd2e5d8a"
+ version "6.26.2"
+ resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-commonjs/-/babel-plugin-transform-es2015-modules-commonjs-6.26.2.tgz#58a793863a9e7ca870bdc5a881117ffac27db6f3"
dependencies:
babel-plugin-transform-strict-mode "^6.24.1"
babel-runtime "^6.26.0"
@@ -1162,15 +1155,11 @@ broccoli-debug@^0.6.1, broccoli-debug@^0.6.2, broccoli-debug@^0.6.3:
tree-sync "^1.2.2"
broccoli-file-creator@^1.0.0, broccoli-file-creator@^1.1.1:
- version "1.1.1"
- resolved "https://registry.yarnpkg.com/broccoli-file-creator/-/broccoli-file-creator-1.1.1.tgz#1b35b67d215abdfadd8d49eeb69493c39e6c3450"
+ version "1.2.0"
+ resolved "https://registry.yarnpkg.com/broccoli-file-creator/-/broccoli-file-creator-1.2.0.tgz#27f1b25b1b00e7bb7bf3d5d7abed5f4d5388df4d"
dependencies:
- broccoli-kitchen-sink-helpers "~0.2.0"
broccoli-plugin "^1.1.0"
- broccoli-writer "~0.1.1"
mkdirp "^0.5.1"
- rsvp "~3.0.6"
- symlink-or-copy "^1.0.1"
broccoli-filter@^0.1.11:
version "0.1.14"
@@ -1249,7 +1238,7 @@ broccoli-funnel@^2.0.0, broccoli-funnel@^2.0.1:
symlink-or-copy "^1.0.0"
walk-sync "^0.3.1"
-broccoli-kitchen-sink-helpers@^0.2.0, broccoli-kitchen-sink-helpers@^0.2.6, broccoli-kitchen-sink-helpers@~0.2.0, broccoli-kitchen-sink-helpers@~0.2.4:
+broccoli-kitchen-sink-helpers@^0.2.0, broccoli-kitchen-sink-helpers@^0.2.6, broccoli-kitchen-sink-helpers@~0.2.4:
version "0.2.9"
resolved "https://registry.yarnpkg.com/broccoli-kitchen-sink-helpers/-/broccoli-kitchen-sink-helpers-0.2.9.tgz#a5e0986ed8d76fb5984b68c3f0450d3a96e36ecc"
dependencies:
@@ -1646,17 +1635,9 @@ chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3:
strip-ansi "^3.0.0"
supports-color "^2.0.0"
-chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.3.1:
- version "2.3.2"
- resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.3.2.tgz#250dc96b07491bfd601e648d66ddf5f60c7a5c65"
- dependencies:
- ansi-styles "^3.2.1"
- escape-string-regexp "^1.0.5"
- supports-color "^5.3.0"
-
-chalk@^2.3.0:
- version "2.4.0"
- resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.0.tgz#a060a297a6b57e15b61ca63ce84995daa0fe6e52"
+chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.3.0, chalk@^2.3.1:
+ version "2.4.1"
+ resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.1.tgz#18c49ab16a037b6eb0152cc83e3471338215b66e"
dependencies:
ansi-styles "^3.2.1"
escape-string-regexp "^1.0.5"
@@ -1691,6 +1672,10 @@ chokidar@1.7.0:
optionalDependencies:
fsevents "^1.0.0"
+chownr@^1.0.1:
+ version "1.0.1"
+ resolved "https://registry.yarnpkg.com/chownr/-/chownr-1.0.1.tgz#e2a75042a9551908bebd25b8523d5f9769d79181"
+
circular-json@^0.3.1:
version "0.3.3"
resolved "https://registry.yarnpkg.com/circular-json/-/circular-json-0.3.3.tgz#815c99ea84f6809529d2f45791bdf82711352d66"
@@ -1785,8 +1770,8 @@ clone@^1.0.2:
resolved "https://registry.yarnpkg.com/clone/-/clone-1.0.4.tgz#da309cc263df15994c688ca902179ca3c7cd7c7e"
clone@^2.0.0:
- version "2.1.2"
- resolved "https://registry.yarnpkg.com/clone/-/clone-2.1.2.tgz#1b7f4b9f591f1e8f83670401600345a02887435f"
+ version "2.1.1"
+ resolved "https://registry.yarnpkg.com/clone/-/clone-2.1.1.tgz#d217d1e961118e3ac9a4b8bba3285553bf647cdb"
co@^4.6.0:
version "4.6.0"
@@ -1956,7 +1941,7 @@ continuable-cache@^0.3.1:
version "0.3.1"
resolved "https://registry.yarnpkg.com/continuable-cache/-/continuable-cache-0.3.1.tgz#bd727a7faed77e71ff3985ac93351a912733ad0f"
-convert-source-map@^1.5.0, convert-source-map@^1.5.1:
+convert-source-map@^1.5.1:
version "1.5.1"
resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.5.1.tgz#b8278097b9bc229365de5c62cf5fcaed8b5599e5"
@@ -2093,7 +2078,7 @@ debug@2.6.8:
dependencies:
ms "2.0.0"
-debug@2.6.9, debug@^2.1.0, debug@^2.1.1, debug@^2.1.3, debug@^2.2.0, debug@^2.3.3, debug@^2.4.0, debug@^2.6.8:
+debug@2.6.9, debug@^2.1.0, debug@^2.1.1, debug@^2.1.2, debug@^2.1.3, debug@^2.2.0, debug@^2.3.3, debug@^2.4.0, debug@^2.6.8, debug@^2.6.9:
version "2.6.9"
resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f"
dependencies:
@@ -2263,12 +2248,12 @@ ee-first@1.1.1:
resolved "https://registry.yarnpkg.com/ee-first/-/ee-first-1.1.1.tgz#590c61156b0ae2f4f0255732a158b266bc56b21d"
electron-to-chromium@^1.3.30:
- version "1.3.42"
- resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.42.tgz#95c33bf01d0cc405556aec899fe61fd4d76ea0f9"
+ version "1.3.44"
+ resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.44.tgz#ef6b150a60d523082388cadad88085ecd2fd4684"
ember-basic-dropdown@^1.0.0-beta.5:
- version "1.0.0-beta.5"
- resolved "https://registry.yarnpkg.com/ember-basic-dropdown/-/ember-basic-dropdown-1.0.0-beta.5.tgz#c59afd762985d9217be79ccb4e3192406a7ef432"
+ version "1.0.0-beta.7"
+ resolved "https://registry.yarnpkg.com/ember-basic-dropdown/-/ember-basic-dropdown-1.0.0-beta.7.tgz#afbdfec157ca0f3baf0ff77c335e89414c03c429"
dependencies:
ember-cli-babel "^6.12.0"
ember-cli-htmlbars "^2.0.3"
@@ -2411,8 +2396,8 @@ ember-cli-lodash-subset@^1.0.7:
resolved "https://registry.yarnpkg.com/ember-cli-lodash-subset/-/ember-cli-lodash-subset-1.0.12.tgz#af2e77eba5dcb0d77f3308d3a6fd7d3450f6e537"
ember-cli-mirage@^0.4.3:
- version "0.4.3"
- resolved "https://registry.yarnpkg.com/ember-cli-mirage/-/ember-cli-mirage-0.4.3.tgz#81470c2b9cdb2b88661c56be6aacb928945a9b3b"
+ version "0.4.6"
+ resolved "https://registry.yarnpkg.com/ember-cli-mirage/-/ember-cli-mirage-0.4.6.tgz#058084609536c339ffed1057ac9db0a0a36ab986"
dependencies:
broccoli-funnel "^1.0.2"
broccoli-merge-trees "^1.1.0"
@@ -2648,8 +2633,8 @@ ember-compatibility-helpers@^1.0.0-beta.2:
semver "^5.4.1"
ember-concurrency@^0.8.12:
- version "0.8.17"
- resolved "https://registry.yarnpkg.com/ember-concurrency/-/ember-concurrency-0.8.17.tgz#be47a90342f1960f4f57284c2fe5f7ce2396142a"
+ version "0.8.18"
+ resolved "https://registry.yarnpkg.com/ember-concurrency/-/ember-concurrency-0.8.18.tgz#20a9ac4ced6496ea4ebe52e88f4524a473871396"
dependencies:
babel-core "^6.24.1"
ember-cli-babel "^6.8.2"
@@ -2747,16 +2732,16 @@ ember-href-to@1.15.1:
ember-router-service-polyfill "^1.0.2"
ember-inflector@^2.0.0:
- version "2.2.0"
- resolved "https://registry.yarnpkg.com/ember-inflector/-/ember-inflector-2.2.0.tgz#edd273dfd1a29be27f14b195e2f0ed70e812d9e0"
+ version "2.3.0"
+ resolved "https://registry.yarnpkg.com/ember-inflector/-/ember-inflector-2.3.0.tgz#94797eba0eea98d902aa1e5da0f0aeef6053317f"
dependencies:
ember-cli-babel "^6.0.0"
ember-load-initializers@^1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/ember-load-initializers/-/ember-load-initializers-1.0.0.tgz#4919eaf06f6dfeca7e134633d8c05a6c9921e6e7"
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/ember-load-initializers/-/ember-load-initializers-1.1.0.tgz#4edacc0f3a14d9f53d241ac3e5561804c8377978"
dependencies:
- ember-cli-babel "^6.0.0-beta.7"
+ ember-cli-babel "^6.6.0"
ember-lodash@^4.17.3:
version "4.18.0"
@@ -2856,8 +2841,8 @@ ember-source-channel-url@^1.0.1:
got "^8.0.1"
ember-source@~3.1.0:
- version "3.1.0"
- resolved "https://registry.yarnpkg.com/ember-source/-/ember-source-3.1.0.tgz#21902747801c747b615f60168712968db3b433fc"
+ version "3.1.1"
+ resolved "https://registry.yarnpkg.com/ember-source/-/ember-source-3.1.1.tgz#9cf95e8a6d7568d60b8eda2aeda17ac8944e654b"
dependencies:
broccoli-funnel "^2.0.1"
broccoli-merge-trees "^2.0.0"
@@ -3182,9 +3167,9 @@ event-emitter@~0.3.5:
d "1"
es5-ext "~0.10.14"
-eventemitter3@1.x.x:
- version "1.2.0"
- resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-1.2.0.tgz#1c86991d816ad1e504750e73874224ecf3bec508"
+eventemitter3@^3.0.0:
+ version "3.1.0"
+ resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-3.1.0.tgz#090b4d6cdbd645ed10bf750d4b5407942d7ba163"
events-to-array@^1.0.1:
version "1.1.2"
@@ -3569,6 +3554,12 @@ flat-cache@^1.2.1:
graceful-fs "^4.1.2"
write "^0.2.1"
+follow-redirects@^1.0.0:
+ version "1.4.1"
+ resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.4.1.tgz#d8120f4518190f55aac65bb6fc7b85fcd666d6aa"
+ dependencies:
+ debug "^3.1.0"
+
for-in@^1.0.1, for-in@^1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80"
@@ -3680,6 +3671,12 @@ fs-extra@^5.0.0:
jsonfile "^4.0.0"
universalify "^0.1.0"
+fs-minipass@^1.2.5:
+ version "1.2.5"
+ resolved "https://registry.yarnpkg.com/fs-minipass/-/fs-minipass-1.2.5.tgz#06c277218454ec288df77ada54a03b8702aacb9d"
+ dependencies:
+ minipass "^2.2.1"
+
fs-sync@^1.0.4:
version "1.0.4"
resolved "https://registry.yarnpkg.com/fs-sync/-/fs-sync-1.0.4.tgz#2f94eade31862ec0a9f33a1c2546dfb1a3f3d1ae"
@@ -3704,21 +3701,13 @@ fs.realpath@^1.0.0:
resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f"
fsevents@^1.0.0, fsevents@^1.1.1:
- version "1.1.3"
- resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.1.3.tgz#11f82318f5fe7bb2cd22965a108e9306208216d8"
- dependencies:
- nan "^2.3.0"
- node-pre-gyp "^0.6.39"
-
-fstream-ignore@^1.0.5:
- version "1.0.5"
- resolved "https://registry.yarnpkg.com/fstream-ignore/-/fstream-ignore-1.0.5.tgz#9c31dae34767018fe1d249b24dada67d092da105"
+ version "1.2.2"
+ resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.2.tgz#4f598f0f69b273188ef4a62ca4e9e08ace314bbf"
dependencies:
- fstream "^1.0.0"
- inherits "2"
- minimatch "^3.0.0"
+ nan "^2.9.2"
+ node-pre-gyp "^0.9.0"
-fstream@^1.0.0, fstream@^1.0.10, fstream@^1.0.2:
+fstream@^1.0.0, fstream@^1.0.2:
version "1.0.11"
resolved "https://registry.yarnpkg.com/fstream/-/fstream-1.0.11.tgz#5c1fb1f117477114f0632a0eb4b71b3cb0fd3171"
dependencies:
@@ -3880,8 +3869,8 @@ global-prefix@^1.0.1:
which "^1.2.14"
globals@^11.0.1:
- version "11.4.0"
- resolved "https://registry.yarnpkg.com/globals/-/globals-11.4.0.tgz#b85c793349561c16076a3c13549238a27945f1bc"
+ version "11.5.0"
+ resolved "https://registry.yarnpkg.com/globals/-/globals-11.5.0.tgz#6bc840de6771173b191f13d3a9c94d441ee92642"
globals@^9.18.0:
version "9.18.0"
@@ -3954,10 +3943,6 @@ handlebars@^4.0.4, handlebars@^4.0.6:
optionalDependencies:
uglify-js "^2.6"
-har-schema@^1.0.5:
- version "1.0.5"
- resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-1.0.5.tgz#d263135f43307c02c602afc8fe95970c0151369e"
-
har-schema@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92"
@@ -3971,13 +3956,6 @@ har-validator@~2.0.6:
is-my-json-valid "^2.12.4"
pinkie-promise "^2.0.0"
-har-validator@~4.2.1:
- version "4.2.1"
- resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-4.2.1.tgz#33481d0f1bbff600dd203d75812a6a5fba002e2a"
- dependencies:
- ajv "^4.9.1"
- har-schema "^1.0.5"
-
har-validator@~5.0.3:
version "5.0.3"
resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.0.3.tgz#ba402c266194f15956ef15e0fcf242993f6a7dfd"
@@ -4065,7 +4043,7 @@ hash-for-dep@^1.0.2:
heimdalljs-logger "^0.1.7"
resolve "^1.4.0"
-hawk@3.1.3, hawk@~3.1.3:
+hawk@~3.1.3:
version "3.1.3"
resolved "https://registry.yarnpkg.com/hawk/-/hawk-3.1.3.tgz#078444bd7c1640b0fe540d2c9b73d59678e8e1c4"
dependencies:
@@ -4173,15 +4151,16 @@ http-errors@~1.6.2:
statuses ">= 1.4.0 < 2"
http-parser-js@>=0.4.0:
- version "0.4.11"
- resolved "https://registry.yarnpkg.com/http-parser-js/-/http-parser-js-0.4.11.tgz#5b720849c650903c27e521633d94696ee95f3529"
+ version "0.4.12"
+ resolved "https://registry.yarnpkg.com/http-parser-js/-/http-parser-js-0.4.12.tgz#b9cfbf4a2cf26f0fc34b10ca1489a27771e3474f"
http-proxy@^1.13.1, http-proxy@^1.9.0:
- version "1.16.2"
- resolved "https://registry.yarnpkg.com/http-proxy/-/http-proxy-1.16.2.tgz#06dff292952bf64dbe8471fa9df73066d4f37742"
+ version "1.17.0"
+ resolved "https://registry.yarnpkg.com/http-proxy/-/http-proxy-1.17.0.tgz#7ad38494658f84605e2f6db4436df410f4e5be9a"
dependencies:
- eventemitter3 "1.x.x"
- requires-port "1.x.x"
+ eventemitter3 "^3.0.0"
+ follow-redirects "^1.0.0"
+ requires-port "^1.0.0"
http-signature@~1.1.0:
version "1.1.1"
@@ -4203,15 +4182,21 @@ iconv-lite@0.4.19:
version "0.4.19"
resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.19.tgz#f7468f60135f5e5dad3399c0a81be9a1603a082b"
-iconv-lite@^0.4.13, iconv-lite@^0.4.17, iconv-lite@~0.4.13:
+iconv-lite@^0.4.13, iconv-lite@^0.4.17, iconv-lite@^0.4.4, iconv-lite@~0.4.13:
version "0.4.21"
resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.21.tgz#c47f8733d02171189ebc4a400f3218d348094798"
dependencies:
safer-buffer "^2.1.0"
+ignore-walk@^3.0.1:
+ version "3.0.1"
+ resolved "https://registry.yarnpkg.com/ignore-walk/-/ignore-walk-3.0.1.tgz#a83e62e7d272ac0e3b551aaa82831a19b69f82f8"
+ dependencies:
+ minimatch "^3.0.4"
+
ignore@^3.3.3, ignore@^3.3.6:
- version "3.3.7"
- resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.7.tgz#612289bfb3c220e186a58118618d5be8c1bab021"
+ version "3.3.8"
+ resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.8.tgz#3f8e9c35d38708a3a7e0e9abb6c73e7ee7707b2b"
imurmurhash@^0.1.4:
version "0.1.4"
@@ -4868,8 +4853,8 @@ locate-path@^2.0.0:
path-exists "^3.0.0"
lodash-es@^4.17.4:
- version "4.17.8"
- resolved "https://registry.yarnpkg.com/lodash-es/-/lodash-es-4.17.8.tgz#6fa8c8c5d337481df0bdf1c0d899d42473121e45"
+ version "4.17.10"
+ resolved "https://registry.yarnpkg.com/lodash-es/-/lodash-es-4.17.10.tgz#62cd7104cdf5dd87f235a837f0ede0e8e5117e05"
lodash._baseassign@^3.0.0:
version "3.2.0"
@@ -5261,11 +5246,7 @@ lodash@^3.10.0, lodash@^3.10.1:
version "3.10.1"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.10.1.tgz#5bf45e8e49ba4189e17d482789dfd15bd140b7b6"
-lodash@^4.0.0, lodash@^4.14.0, lodash@^4.16.1, lodash@^4.17.2, lodash@^4.17.4, lodash@^4.3.0, lodash@^4.5.1, lodash@^4.6.1, lodash@~4.17.4:
- version "4.17.5"
- resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.5.tgz#99a92d65c0272debe8c96b6057bc8fbfa3bed511"
-
-lodash@^4.13.1:
+lodash@^4.0.0, lodash@^4.13.1, lodash@^4.14.0, lodash@^4.16.1, lodash@^4.17.2, lodash@^4.17.4, lodash@^4.3.0, lodash@^4.5.1, lodash@^4.6.1, lodash@~4.17.4:
version "4.17.10"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.10.tgz#1b7793cf7259ea38fb3661d4d38b3260af8ae4e7"
@@ -5534,6 +5515,19 @@ minimist@~0.0.1:
version "0.0.10"
resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.10.tgz#de3f98543dbf96082be48ad1a0c7cda836301dcf"
+minipass@^2.2.1, minipass@^2.2.4:
+ version "2.2.4"
+ resolved "https://registry.yarnpkg.com/minipass/-/minipass-2.2.4.tgz#03c824d84551ec38a8d1bb5bc350a5a30a354a40"
+ dependencies:
+ safe-buffer "^5.1.1"
+ yallist "^3.0.0"
+
+minizlib@^1.1.0:
+ version "1.1.0"
+ resolved "https://registry.yarnpkg.com/minizlib/-/minizlib-1.1.0.tgz#11e13658ce46bc3a70a267aac58359d1e0c29ceb"
+ dependencies:
+ minipass "^2.2.1"
+
mixin-deep@^1.2.0:
version "1.3.1"
resolved "https://registry.yarnpkg.com/mixin-deep/-/mixin-deep-1.3.1.tgz#a49e7268dce1a0d9698e45326c5626df3543d0fe"
@@ -5633,7 +5627,7 @@ najax@^1.0.2:
lodash.defaultsdeep "^4.6.0"
qs "^6.2.0"
-nan@^2.10.0, nan@^2.3.0:
+nan@^2.10.0, nan@^2.9.2:
version "2.10.0"
resolved "https://registry.yarnpkg.com/nan/-/nan-2.10.0.tgz#96d0cd610ebd58d4b4de9cc0c6828cda99c7548f"
@@ -5658,6 +5652,14 @@ natural-compare@^1.4.0:
version "1.4.0"
resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7"
+needle@^2.2.0:
+ version "2.2.0"
+ resolved "https://registry.yarnpkg.com/needle/-/needle-2.2.0.tgz#f14efc69cee1024b72c8b21c7bdf94a731dc12fa"
+ dependencies:
+ debug "^2.1.2"
+ iconv-lite "^0.4.4"
+ sax "^1.2.4"
+
negotiator@0.6.1:
version "0.6.1"
resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.1.tgz#2b327184e8992101177b28563fb5e7102acd0ca9"
@@ -5722,25 +5724,24 @@ node-notifier@^5.0.1:
shellwords "^0.1.1"
which "^1.3.0"
-node-pre-gyp@^0.6.39:
- version "0.6.39"
- resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.6.39.tgz#c00e96860b23c0e1420ac7befc5044e1d78d8649"
+node-pre-gyp@^0.9.0:
+ version "0.9.1"
+ resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.9.1.tgz#f11c07516dd92f87199dbc7e1838eab7cd56c9e0"
dependencies:
detect-libc "^1.0.2"
- hawk "3.1.3"
mkdirp "^0.5.1"
+ needle "^2.2.0"
nopt "^4.0.1"
+ npm-packlist "^1.1.6"
npmlog "^4.0.2"
rc "^1.1.7"
- request "2.81.0"
rimraf "^2.6.1"
semver "^5.3.0"
- tar "^2.2.1"
- tar-pack "^3.4.0"
+ tar "^4"
node-sass@^4.7.2:
- version "4.8.3"
- resolved "https://registry.yarnpkg.com/node-sass/-/node-sass-4.8.3.tgz#d077cc20a08ac06f661ca44fb6f19cd2ed41debb"
+ version "4.9.0"
+ resolved "https://registry.yarnpkg.com/node-sass/-/node-sass-4.9.0.tgz#d1b8aa855d98ed684d6848db929a20771cc2ae52"
dependencies:
async-foreach "^0.1.3"
chalk "^1.1.1"
@@ -5798,6 +5799,10 @@ normalize-url@2.0.1:
query-string "^5.0.1"
sort-keys "^2.0.0"
+npm-bundled@^1.0.1:
+ version "1.0.3"
+ resolved "https://registry.yarnpkg.com/npm-bundled/-/npm-bundled-1.0.3.tgz#7e71703d973af3370a9591bafe3a63aca0be2308"
+
npm-git-info@^1.0.0:
version "1.0.3"
resolved "https://registry.yarnpkg.com/npm-git-info/-/npm-git-info-1.0.3.tgz#a933c42ec321e80d3646e0d6e844afe94630e1d5"
@@ -5811,6 +5816,13 @@ npm-package-arg@^6.0.0:
semver "^5.5.0"
validate-npm-package-name "^3.0.0"
+npm-packlist@^1.1.6:
+ version "1.1.10"
+ resolved "https://registry.yarnpkg.com/npm-packlist/-/npm-packlist-1.1.10.tgz#1039db9e985727e464df066f4cf0ab6ef85c398a"
+ dependencies:
+ ignore-walk "^3.0.1"
+ npm-bundled "^1.0.1"
+
npm-run-path@^2.0.0:
version "2.0.2"
resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-2.0.2.tgz#35a9232dfa35d7067b4cb2ddf2357b1871536c5f"
@@ -5887,7 +5899,7 @@ on-headers@~1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/on-headers/-/on-headers-1.0.1.tgz#928f5d0f470d49342651ea6794b0857c100693f7"
-once@^1.3.0, once@^1.3.3:
+once@^1.3.0:
version "1.4.0"
resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1"
dependencies:
@@ -6086,10 +6098,6 @@ pathval@^1.0.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/pathval/-/pathval-1.1.0.tgz#b942e6d4bde653005ef6b71361def8727d0645e0"
-performance-now@^0.2.0:
- version "0.2.0"
- resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-0.2.0.tgz#33ef30c5c77d4ea21c5a53869d91b56d8f2555e5"
-
performance-now@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b"
@@ -6175,7 +6183,7 @@ printf@^0.2.3:
version "0.2.5"
resolved "https://registry.yarnpkg.com/printf/-/printf-0.2.5.tgz#c438ca2ca33e3927671db4ab69c0e52f936a4f0f"
-private@^0.1.6, private@^0.1.7, private@~0.1.5:
+private@^0.1.6, private@^0.1.8, private@~0.1.5:
version "0.1.8"
resolved "https://registry.yarnpkg.com/private/-/private-0.1.8.tgz#2381edb3689f7a53d653190060fcf822d2f368ff"
@@ -6226,10 +6234,6 @@ qs@~6.3.0:
version "6.3.2"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.3.2.tgz#e75bd5f6e268122a2a0e0bda630b2550c166502c"
-qs@~6.4.0:
- version "6.4.0"
- resolved "https://registry.yarnpkg.com/qs/-/qs-6.4.0.tgz#13e26d28ad6b0ffaa91312cd3bf708ed351e7233"
-
query-string@^5.0.1:
version "5.1.1"
resolved "https://registry.yarnpkg.com/query-string/-/query-string-5.1.1.tgz#a78c012b71c17e05f2e3fa2319dd330682efb3cb"
@@ -6239,11 +6243,11 @@ query-string@^5.0.1:
strict-uri-encode "^1.0.0"
quibble@^0.5.1:
- version "0.5.3"
- resolved "https://registry.yarnpkg.com/quibble/-/quibble-0.5.3.tgz#3dfd53206fc6873f61c96f3bece63b69747b4d0c"
+ version "0.5.5"
+ resolved "https://registry.yarnpkg.com/quibble/-/quibble-0.5.5.tgz#669fb731520a923e0a98f8076b7eb55e409f73f9"
dependencies:
lodash "^4.17.2"
- resolve "^1.5.0"
+ resolve "^1.7.1"
quick-temp@^0.1.0, quick-temp@^0.1.2, quick-temp@^0.1.3, quick-temp@^0.1.5, quick-temp@^0.1.8:
version "0.1.8"
@@ -6323,7 +6327,7 @@ read-pkg@^1.0.0:
normalize-package-data "^2.3.2"
path-type "^1.0.0"
-readable-stream@^2, readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.6, readable-stream@^2.1.4, readable-stream@^2.2.2:
+readable-stream@^2, readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.6, readable-stream@^2.2.2:
version "2.3.6"
resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.6.tgz#b11c27d88b8ff1fbe070643cf94b0c79ae1b0aaf"
dependencies:
@@ -6493,33 +6497,6 @@ request@2, request@^2.81.0, request@^2.83.0:
tunnel-agent "^0.6.0"
uuid "^3.1.0"
-request@2.81.0:
- version "2.81.0"
- resolved "https://registry.yarnpkg.com/request/-/request-2.81.0.tgz#c6928946a0e06c5f8d6f8a9333469ffda46298a0"
- dependencies:
- aws-sign2 "~0.6.0"
- aws4 "^1.2.1"
- caseless "~0.12.0"
- combined-stream "~1.0.5"
- extend "~3.0.0"
- forever-agent "~0.6.1"
- form-data "~2.1.1"
- har-validator "~4.2.1"
- hawk "~3.1.3"
- http-signature "~1.1.0"
- is-typedarray "~1.0.0"
- isstream "~0.1.2"
- json-stringify-safe "~5.0.1"
- mime-types "~2.1.7"
- oauth-sign "~0.8.1"
- performance-now "^0.2.0"
- qs "~6.4.0"
- safe-buffer "^5.0.1"
- stringstream "~0.0.4"
- tough-cookie "~2.3.0"
- tunnel-agent "^0.6.0"
- uuid "^3.0.0"
-
request@~2.79.0:
version "2.79.0"
resolved "https://registry.yarnpkg.com/request/-/request-2.79.0.tgz#4dfe5bf6be8b8cdc37fcf93e04b65577722710de"
@@ -6566,7 +6543,7 @@ require-uncached@^1.0.3:
caller-path "^0.1.0"
resolve-from "^1.0.0"
-requires-port@1.x.x:
+requires-port@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff"
@@ -6591,7 +6568,7 @@ resolve@1.5.0:
dependencies:
path-parse "^1.0.5"
-resolve@^1.1.3, resolve@^1.1.6, resolve@^1.1.7, resolve@^1.3.0, resolve@^1.3.3, resolve@^1.4.0, resolve@^1.5.0:
+resolve@^1.1.3, resolve@^1.1.6, resolve@^1.1.7, resolve@^1.3.0, resolve@^1.3.3, resolve@^1.4.0, resolve@^1.5.0, resolve@^1.7.1:
version "1.7.1"
resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.7.1.tgz#aadd656374fd298aee895bc026b8297418677fd3"
dependencies:
@@ -6627,7 +6604,7 @@ right-align@^0.1.1:
dependencies:
align-text "^0.1.1"
-rimraf@2, rimraf@^2.1.4, rimraf@^2.2.8, rimraf@^2.3.2, rimraf@^2.3.4, rimraf@^2.4.3, rimraf@^2.4.4, rimraf@^2.5.1, rimraf@^2.5.3, rimraf@^2.5.4, rimraf@^2.6.1:
+rimraf@2, rimraf@^2.1.4, rimraf@^2.2.8, rimraf@^2.3.2, rimraf@^2.3.4, rimraf@^2.4.3, rimraf@^2.4.4, rimraf@^2.5.3, rimraf@^2.5.4, rimraf@^2.6.1:
version "2.6.2"
resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.2.tgz#2ed8150d24a16ea8651e6d6ef0f47c4158ce7a36"
dependencies:
@@ -6687,10 +6664,14 @@ rx@^4.1.0:
version "4.1.0"
resolved "https://registry.yarnpkg.com/rx/-/rx-4.1.0.tgz#a5f13ff79ef3b740fe30aa803fb09f98805d4782"
-safe-buffer@5.1.1, safe-buffer@^5.0.1, safe-buffer@^5.1.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1:
+safe-buffer@5.1.1:
version "5.1.1"
resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853"
+safe-buffer@^5.0.1, safe-buffer@^5.1.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1:
+ version "5.1.2"
+ resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d"
+
safe-json-parse@~1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/safe-json-parse/-/safe-json-parse-1.0.1.tgz#3e76723e38dfdda13c9b1d29a1e07ffee4b30b57"
@@ -7224,8 +7205,8 @@ supports-color@^2.0.0:
resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7"
supports-color@^5.3.0:
- version "5.3.0"
- resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.3.0.tgz#5b24ac15db80fa927cf5227a4a33fd3c4c7676c0"
+ version "5.4.0"
+ resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.4.0.tgz#1c6b337402c2137605efe19f10fec390f6faab54"
dependencies:
has-flag "^3.0.0"
@@ -7257,20 +7238,7 @@ tap-parser@^5.1.0:
optionalDependencies:
readable-stream "^2"
-tar-pack@^3.4.0:
- version "3.4.1"
- resolved "https://registry.yarnpkg.com/tar-pack/-/tar-pack-3.4.1.tgz#e1dbc03a9b9d3ba07e896ad027317eb679a10a1f"
- dependencies:
- debug "^2.2.0"
- fstream "^1.0.10"
- fstream-ignore "^1.0.5"
- once "^1.3.3"
- readable-stream "^2.1.4"
- rimraf "^2.5.1"
- tar "^2.2.1"
- uid-number "^0.0.6"
-
-tar@^2.0.0, tar@^2.2.1:
+tar@^2.0.0:
version "2.2.1"
resolved "https://registry.yarnpkg.com/tar/-/tar-2.2.1.tgz#8e4d2a256c0e2185c6b18ad694aec968b83cb1d1"
dependencies:
@@ -7278,6 +7246,18 @@ tar@^2.0.0, tar@^2.2.1:
fstream "^1.0.2"
inherits "2"
+tar@^4:
+ version "4.4.1"
+ resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.1.tgz#b25d5a8470c976fd7a9a8a350f42c59e9fa81749"
+ dependencies:
+ chownr "^1.0.1"
+ fs-minipass "^1.2.5"
+ minipass "^2.2.4"
+ minizlib "^1.1.0"
+ mkdirp "^0.5.0"
+ safe-buffer "^5.1.1"
+ yallist "^3.0.2"
+
temp@0.8.3:
version "0.8.3"
resolved "https://registry.yarnpkg.com/temp/-/temp-0.8.3.tgz#e0c6bc4d26b903124410e4fed81103014dfc1f59"
@@ -7295,8 +7275,8 @@ testdouble@^3.2.6:
stringify-object-es5 "^2.5.0"
testem@^2.0.0:
- version "2.2.1"
- resolved "https://registry.yarnpkg.com/testem/-/testem-2.2.1.tgz#7bcda44eeb34287d918b3c8b9c6863d26a616557"
+ version "2.4.0"
+ resolved "https://registry.yarnpkg.com/testem/-/testem-2.4.0.tgz#c74e9bbc5269dc102dad6b95979888c397c6e712"
dependencies:
backbone "^1.1.2"
bluebird "^3.4.6"
@@ -7519,10 +7499,6 @@ uglify-to-browserify@~1.0.0:
version "1.0.2"
resolved "https://registry.yarnpkg.com/uglify-to-browserify/-/uglify-to-browserify-1.0.2.tgz#6e0924d6bda6b5afe349e39a6d632850a0f882b7"
-uid-number@^0.0.6:
- version "0.0.6"
- resolved "https://registry.yarnpkg.com/uid-number/-/uid-number-0.0.6.tgz#0ea10e8035e8eb5b8e4449f06da1c730663baa81"
-
ultron@~1.1.0:
version "1.1.1"
resolved "https://registry.yarnpkg.com/ultron/-/ultron-1.1.1.tgz#9fe1536a10a664a65266a1e3ccf85fd36302bc9c"
@@ -7535,8 +7511,8 @@ underscore.string@~3.3.4:
util-deprecate "^1.0.2"
underscore@>=1.8.3:
- version "1.8.3"
- resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.8.3.tgz#4f3fb53b106e6097fcf9cb4109f2a5e9bdfa5022"
+ version "1.9.0"
+ resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.9.0.tgz#31dbb314cfcc88f169cd3692d9149d81a00a73e4"
union-value@^1.0.0:
version "1.0.0"
@@ -7849,6 +7825,10 @@ yallist@^2.1.2:
version "2.1.2"
resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52"
+yallist@^3.0.0, yallist@^3.0.2:
+ version "3.0.2"
+ resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.0.2.tgz#8452b4bb7e83c7c188d8041c1a837c773d6d8bb9"
+
yam@^0.0.24:
version "0.0.24"
resolved "https://registry.yarnpkg.com/yam/-/yam-0.0.24.tgz#11e9630444735f66a561d29221407de6d037cd95"
From 8a0583ee8f692541b278f2ddd89d82e531fa543d Mon Sep 17 00:00:00 2001
From: Miguel Camba
Date: Fri, 27 Apr 2018 22:58:31 +0200
Subject: [PATCH 26/34] Improve component's behavior in beta (#1104)
---
addon/components/power-select.js | 7 ++++++-
package.json | 4 ++--
.../components/power-select/custom-search-test.js | 2 +-
.../components/power-select/general-behaviour-test.js | 3 ++-
yarn.lock | 4 ++--
5 files changed, 13 insertions(+), 7 deletions(-)
diff --git a/addon/components/power-select.js b/addon/components/power-select.js
index aea42a4f4..787d30e09 100644
--- a/addon/components/power-select.js
+++ b/addon/components/power-select.js
@@ -108,7 +108,12 @@ export default Component.extend({
init() {
this._super(...arguments);
this._publicAPIActions = {
- search: (...args) => this.send('search', ...args),
+ search: (...args) => {
+ if (this.get('isDestroying')) {
+ return;
+ }
+ return this.send('search', ...args)
+ },
highlight: (...args) => this.send('highlight', ...args),
select: (...args) => this.send('select', ...args),
choose: (...args) => this.send('choose', ...args),
diff --git a/package.json b/package.json
index 0cd32690c..550fbbd96 100644
--- a/package.json
+++ b/package.json
@@ -45,7 +45,7 @@
"ember-basic-dropdown": "^1.0.0-beta.5",
"ember-cli-babel": "^6.11.0",
"ember-cli-htmlbars": "^2.0.1",
- "ember-concurrency": "^0.8.12",
+ "ember-concurrency": "^0.8.18",
"ember-text-measurer": "^0.4.0",
"ember-truth-helpers": "^2.0.0"
},
@@ -75,7 +75,7 @@
"ember-native-dom-helpers": "^0.6.2",
"ember-qunit-assert-helpers": "^0.2.1",
"ember-resolver": "^4.0.0",
- "ember-source": "~3.1.0",
+ "ember-source": "~3.1.1",
"ember-source-channel-url": "^1.0.1",
"ember-try": "^0.2.23",
"eslint-plugin-ember": "^5.0.0",
diff --git a/tests/integration/components/power-select/custom-search-test.js b/tests/integration/components/power-select/custom-search-test.js
index e44e701e0..a4a9db46e 100644
--- a/tests/integration/components/power-select/custom-search-test.js
+++ b/tests/integration/components/power-select/custom-search-test.js
@@ -663,7 +663,7 @@ module('Integration | Component | Ember Power Select (Custom search function)',
await clickTrigger();
typeInSearch('teen');
-
+ // await new RSVP.Promise((resolve) => setTimeout(resolve, 50));
setTimeout(() => {
this.set('hideSelect', true);
}, 50);
diff --git a/tests/integration/components/power-select/general-behaviour-test.js b/tests/integration/components/power-select/general-behaviour-test.js
index 123887474..56a7cace0 100644
--- a/tests/integration/components/power-select/general-behaviour-test.js
+++ b/tests/integration/components/power-select/general-behaviour-test.js
@@ -1176,7 +1176,8 @@ module('Integration | Component | Ember Power Select (General behavior)', functi
assert.dom('.ember-power-select-option[aria-selected="true"]').doesNotExist('no element is selected');
assert.dom('.ember-power-select-trigger').hasText('', 'Nothing is selected yet');
- await this.mainUser.bestie;
+ await this.get('mainUser.bestie');
+ await settled();
assert.dom('.ember-power-select-option[aria-current="true"]').hasText('Lucius', 'The 4th element is highlighted');
assert.dom('.ember-power-select-option[aria-selected="true"]').hasText('Lucius', 'The 4th element is highlighted');
assert.dom('.ember-power-select-trigger').hasText('Lucius', 'The trigger has the proper content');
diff --git a/yarn.lock b/yarn.lock
index 17d7c7d5a..cbc535b5e 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -2632,7 +2632,7 @@ ember-compatibility-helpers@^1.0.0-beta.2:
ember-cli-version-checker "^2.0.0"
semver "^5.4.1"
-ember-concurrency@^0.8.12:
+ember-concurrency@^0.8.18:
version "0.8.18"
resolved "https://registry.yarnpkg.com/ember-concurrency/-/ember-concurrency-0.8.18.tgz#20a9ac4ced6496ea4ebe52e88f4524a473871396"
dependencies:
@@ -2840,7 +2840,7 @@ ember-source-channel-url@^1.0.1:
dependencies:
got "^8.0.1"
-ember-source@~3.1.0:
+ember-source@~3.1.1:
version "3.1.1"
resolved "https://registry.yarnpkg.com/ember-source/-/ember-source-3.1.1.tgz#9cf95e8a6d7568d60b8eda2aeda17ac8944e654b"
dependencies:
From 820a0d496bc5242a1b644749de685f3788016bc0 Mon Sep 17 00:00:00 2001
From: cibernox
Date: Fri, 27 Apr 2018 23:10:09 +0200
Subject: [PATCH 27/34] Fix typo
---
tests/dummy/app/templates/public-pages/docs/test-helpers.hbs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/dummy/app/templates/public-pages/docs/test-helpers.hbs b/tests/dummy/app/templates/public-pages/docs/test-helpers.hbs
index 8aaed3f58..a8d70c57a 100644
--- a/tests/dummy/app/templates/public-pages/docs/test-helpers.hbs
+++ b/tests/dummy/app/templates/public-pages/docs/test-helpers.hbs
@@ -36,7 +36,7 @@
{{code-snippet name="test-helpers-2-js.js"}}
-It also allows to pass a complec CSS selector where using the text of the option is not
+It also allows to pass a complex CSS selector where using the text of the option is not
convenient:
{{code-snippet name="test-helpers-3-js.js"}}
From 0b18f7a721ca2299777e2c5832c0f99d374834f8 Mon Sep 17 00:00:00 2001
From: Pablo Brasero
Date: Sun, 29 Apr 2018 21:46:22 +0100
Subject: [PATCH 28/34] Remove native dom helpers (#1105)
* Remove dependency on ember-native-dom-helpers
* Not used any more
---
addon-test-support/index.js | 40 ++++++++++++++++++-------------------
package.json | 1 -
yarn.lock | 7 -------
3 files changed, 20 insertions(+), 28 deletions(-)
diff --git a/addon-test-support/index.js b/addon-test-support/index.js
index 17ca1c50b..8c149e07d 100644
--- a/addon-test-support/index.js
+++ b/addon-test-support/index.js
@@ -1,5 +1,4 @@
import { click, fillIn, settled } from '@ember/test-helpers';
-import { find, findAll } from 'ember-native-dom-helpers';
import { warn } from '@ember/debug';
export async function selectChoose(cssPathOrTrigger, valueOrSelector, optionIndex) {
@@ -8,13 +7,13 @@ export async function selectChoose(cssPathOrTrigger, valueOrSelector, optionInde
if (cssPathOrTrigger.classList.contains('ember-power-select-trigger')) {
trigger = cssPathOrTrigger;
} else {
- trigger = find('.ember-power-select-trigger', cssPathOrTrigger);
+ trigger = cssPathOrTrigger.querySelector('.ember-power-select-trigger');
}
} else {
- trigger = find(`${cssPathOrTrigger} .ember-power-select-trigger`);
+ trigger = document.querySelector(`${cssPathOrTrigger} .ember-power-select-trigger`);
if (!trigger) {
- trigger = find(cssPathOrTrigger);
+ trigger = document.querySelector(cssPathOrTrigger);
}
if (!trigger) {
@@ -27,7 +26,7 @@ export async function selectChoose(cssPathOrTrigger, valueOrSelector, optionInde
}
let contentId = `${trigger.attributes['aria-owns'].value}`;
- let content = find(`#${contentId}`);
+ let content = document.querySelector(`#${contentId}`);
// If the dropdown is closed, open it
if (!content || content.classList.contains('ember-basic-dropdown-content-placeholder')) {
await click(trigger);
@@ -35,11 +34,12 @@ export async function selectChoose(cssPathOrTrigger, valueOrSelector, optionInde
}
// Select the option with the given text
- let options = findAll(`#${contentId} .ember-power-select-option`);
- let potentialTargets = options.filter((opt) => opt.textContent.indexOf(valueOrSelector) > -1);
+ let options = document.querySelectorAll(`#${contentId} .ember-power-select-option`);
+ let potentialTargets = [].slice.apply(options).filter((opt) => opt.textContent.indexOf(valueOrSelector) > -1);
if (potentialTargets.length === 0) {
- potentialTargets = findAll(`#${contentId} ${valueOrSelector}`);
+ potentialTargets = document.querySelectorAll(`#${contentId} ${valueOrSelector}`);
}
+ console.log("PT", potentialTargets)
if (potentialTargets.length > 1) {
let filteredTargets = [].slice.apply(potentialTargets).filter((t) => t.textContent.trim() === valueOrSelector);
if (optionIndex === undefined) {
@@ -63,10 +63,10 @@ export async function selectSearch(cssPathOrTrigger, value) {
trigger = cssPathOrTrigger;
} else {
let triggerPath = `${cssPathOrTrigger} .ember-power-select-trigger`;
- trigger = find(triggerPath);
+ trigger = document.querySelector(triggerPath);
if (!trigger) {
triggerPath = cssPathOrTrigger;
- trigger = find(triggerPath);
+ trigger = document.querySelector(triggerPath);
}
if (!trigger) {
@@ -79,24 +79,24 @@ export async function selectSearch(cssPathOrTrigger, value) {
}
let contentId = `${trigger.attributes['aria-owns'].value}`;
- let isMultipleSelect = !!find('.ember-power-select-trigger-multiple-input', trigger);
+ let isMultipleSelect = !!trigger.querySelector('.ember-power-select-trigger-multiple-input');
- let content = find(`#${contentId}`);
+ let content = document.querySelector(`#${contentId}`);
let dropdownIsClosed = !content || content.classList.contains('ember-basic-dropdown-content-placeholder');
if (dropdownIsClosed) {
await click(trigger);
await settled();
}
- let isDefaultSingleSelect = !!find('.ember-power-select-search-input');
+ let isDefaultSingleSelect = !!document.querySelector('.ember-power-select-search-input');
if (isMultipleSelect) {
- await fillIn(find('.ember-power-select-trigger-multiple-input', trigger), value);
+ await fillIn(trigger.querySelector('.ember-power-select-trigger-multiple-input'), value);
} else if (isDefaultSingleSelect) {
await fillIn('.ember-power-select-search-input', value);
} else { // It's probably a customized version
- let inputIsInTrigger = !!find('.ember-power-select-trigger input[type=search]', trigger);
+ let inputIsInTrigger = !!trigger.querySelector('.ember-power-select-trigger input[type=search]');
if (inputIsInTrigger) {
- await fillIn(find('input[type=search]', trigger), value);
+ await fillIn(trigger.querySelector('input[type=search]'), value);
} else {
await fillIn(`#${contentId} .ember-power-select-search-input[type=search]`, 'input');
}
@@ -106,10 +106,10 @@ export async function selectSearch(cssPathOrTrigger, value) {
export async function removeMultipleOption(cssPath, value) {
let elem;
- let items = findAll(`${cssPath} .ember-power-select-multiple-options > li`);
- let item = items.find((el) => el.textContent.indexOf(value) > -1);
+ let items = document.querySelectorAll(`${cssPath} .ember-power-select-multiple-options > li`);
+ let item = [].slice.apply(items).find((el) => el.textContent.indexOf(value) > -1);
if (item) {
- elem = find('.ember-power-select-multiple-remove-btn', item);
+ elem = item.querySelector('.ember-power-select-multiple-remove-btn');
}
try {
await click(elem);
@@ -121,7 +121,7 @@ export async function removeMultipleOption(cssPath, value) {
}
export async function clearSelected(cssPath) {
- let elem = find(`${cssPath} .ember-power-select-clear-btn`);
+ let elem = document.querySelector(`${cssPath} .ember-power-select-clear-btn`);
try {
await click(elem);
return settled();
diff --git a/package.json b/package.json
index 550fbbd96..e9a69dbfa 100644
--- a/package.json
+++ b/package.json
@@ -72,7 +72,6 @@
"ember-href-to": "1.15.1",
"ember-load-initializers": "^1.0.0",
"ember-maybe-import-regenerator": "^0.1.6",
- "ember-native-dom-helpers": "^0.6.2",
"ember-qunit-assert-helpers": "^0.2.1",
"ember-resolver": "^4.0.0",
"ember-source": "~3.1.1",
diff --git a/yarn.lock b/yarn.lock
index cbc535b5e..575c66f8a 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -2769,13 +2769,6 @@ ember-maybe-in-element@^0.1.3:
dependencies:
ember-cli-babel "^6.11.0"
-ember-native-dom-helpers@^0.6.2:
- version "0.6.2"
- resolved "https://registry.yarnpkg.com/ember-native-dom-helpers/-/ember-native-dom-helpers-0.6.2.tgz#ad1f82d64ac9abdd612022f4f390bdb6653b3d39"
- dependencies:
- broccoli-funnel "^1.1.0"
- ember-cli-babel "^6.6.0"
-
ember-qunit-assert-helpers@^0.2.1:
version "0.2.1"
resolved "https://registry.yarnpkg.com/ember-qunit-assert-helpers/-/ember-qunit-assert-helpers-0.2.1.tgz#4a77f8ff252e47cc53db6fa7fb4becb426de8d29"
From 69dd655e22749e55d0339b342f4d49fcbd8927e8 Mon Sep 17 00:00:00 2001
From: cibernox
Date: Sun, 29 Apr 2018 22:51:46 +0200
Subject: [PATCH 29/34] Update changelog
---
CHANGELOG.md | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 2994415a4..783ebe371 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,9 @@
# Master
+- [INTERNAL] Stop using `ember-native-dom-helpers`. Use regular helpers in `@ember/test-helpers`. This
+ causes some subtle changes in asynchrony on the provided test helpers, but if people are using them
+ as intended (with async/await) there should be no noticeable changes.
+
# 2.0.0-beta.5
- [BUGFIX] Remove redundant `self.` preceeding many well know globals like document or window
From dbd8548e464b477342918d91cf4fa5e1724f964c Mon Sep 17 00:00:00 2001
From: cibernox
Date: Mon, 30 Apr 2018 23:05:23 +0200
Subject: [PATCH 30/34] v2.0.0
---
CHANGELOG.md | 2 ++
package.json | 4 ++--
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 783ebe371..a6b639c7d 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,7 @@
# Master
+# 2.0.0
+- [INTERNAL] Update to `ember-basic-dropdown` 1.0.0!!
- [INTERNAL] Stop using `ember-native-dom-helpers`. Use regular helpers in `@ember/test-helpers`. This
causes some subtle changes in asynchrony on the provided test helpers, but if people are using them
as intended (with async/await) there should be no noticeable changes.
diff --git a/package.json b/package.json
index e9a69dbfa..4dc91d0f4 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "ember-power-select",
- "version": "2.0.0-beta.5",
+ "version": "2.0.0",
"description": "The extensible select component built for ember",
"keywords": [
"ember-addon",
@@ -42,7 +42,7 @@
"vendor"
],
"dependencies": {
- "ember-basic-dropdown": "^1.0.0-beta.5",
+ "ember-basic-dropdown": "^1.0.0",
"ember-cli-babel": "^6.11.0",
"ember-cli-htmlbars": "^2.0.1",
"ember-concurrency": "^0.8.18",
From dc46c339160ae31add22ca1a341bc40d225511bb Mon Sep 17 00:00:00 2001
From: Miguel Camba
Date: Wed, 2 May 2018 15:21:11 +0200
Subject: [PATCH 31/34] Update ember-concurrency to fix bug in beta and canary
(#1106)
---
package.json | 2 +-
.../components/power-select/public-actions-test.js | 2 +-
yarn.lock | 12 ++++++------
3 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/package.json b/package.json
index 4dc91d0f4..0189487f6 100644
--- a/package.json
+++ b/package.json
@@ -45,7 +45,7 @@
"ember-basic-dropdown": "^1.0.0",
"ember-cli-babel": "^6.11.0",
"ember-cli-htmlbars": "^2.0.1",
- "ember-concurrency": "^0.8.18",
+ "ember-concurrency": "^0.8.19",
"ember-text-measurer": "^0.4.0",
"ember-truth-helpers": "^2.0.0"
},
diff --git a/tests/integration/components/power-select/public-actions-test.js b/tests/integration/components/power-select/public-actions-test.js
index 904ed6b90..ca2515933 100644
--- a/tests/integration/components/power-select/public-actions-test.js
+++ b/tests/integration/components/power-select/public-actions-test.js
@@ -125,8 +125,8 @@ module('Integration | Component | Ember Power Select (Public actions)', function
`);
await clickTrigger();
- triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 65);
+ await triggerKeyEvent('.ember-power-select-search-input', 'keydown', 13);
});
test('The onkeydown can be used to easily allow to select on tab', async function(assert) {
diff --git a/yarn.lock b/yarn.lock
index 575c66f8a..fa431f74b 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -2251,9 +2251,9 @@ electron-to-chromium@^1.3.30:
version "1.3.44"
resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.44.tgz#ef6b150a60d523082388cadad88085ecd2fd4684"
-ember-basic-dropdown@^1.0.0-beta.5:
- version "1.0.0-beta.7"
- resolved "https://registry.yarnpkg.com/ember-basic-dropdown/-/ember-basic-dropdown-1.0.0-beta.7.tgz#afbdfec157ca0f3baf0ff77c335e89414c03c429"
+ember-basic-dropdown@^1.0.0:
+ version "1.0.0"
+ resolved "https://registry.yarnpkg.com/ember-basic-dropdown/-/ember-basic-dropdown-1.0.0.tgz#bbafcaab986ba86dfe8d02b0f8529984229bd738"
dependencies:
ember-cli-babel "^6.12.0"
ember-cli-htmlbars "^2.0.3"
@@ -2632,9 +2632,9 @@ ember-compatibility-helpers@^1.0.0-beta.2:
ember-cli-version-checker "^2.0.0"
semver "^5.4.1"
-ember-concurrency@^0.8.18:
- version "0.8.18"
- resolved "https://registry.yarnpkg.com/ember-concurrency/-/ember-concurrency-0.8.18.tgz#20a9ac4ced6496ea4ebe52e88f4524a473871396"
+ember-concurrency@^0.8.19:
+ version "0.8.19"
+ resolved "https://registry.yarnpkg.com/ember-concurrency/-/ember-concurrency-0.8.19.tgz#71b9c175ba077865310029cb4bdb880e17d5155e"
dependencies:
babel-core "^6.24.1"
ember-cli-babel "^6.8.2"
From 5e7b02d1ba685eef8ac4b09cc7bf33211d1c9d79 Mon Sep 17 00:00:00 2001
From: cibernox
Date: Wed, 9 May 2018 22:08:59 +0200
Subject: [PATCH 32/34] Drop node 4
---
package.json | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/package.json b/package.json
index 0189487f6..0cd09a5c1 100644
--- a/package.json
+++ b/package.json
@@ -90,7 +90,7 @@
"testdouble": "^3.2.6"
},
"engines": {
- "node": "^4.5 || 6.* || >= 7.*"
+ "node": "6.* || >= 7.*"
},
"ember-addon": {
"configPath": "tests/dummy/config"
From 5b56ec6ab1cf2f194e22f659a2b3299e0fd8dd9e Mon Sep 17 00:00:00 2001
From: Alex DiLiberto
Date: Sat, 10 Mar 2018 20:04:42 -0500
Subject: [PATCH 33/34] Fix: add extra hash to power-select-multiple
selectedItemComponent
---
.../power-select-multiple/trigger.hbs | 4 ++--
.../components/selected-item-country.hbs | 4 ++--
.../customization-with-components-test.js | 22 +++++++++++++++++++
3 files changed, 26 insertions(+), 4 deletions(-)
diff --git a/addon/templates/components/power-select-multiple/trigger.hbs b/addon/templates/components/power-select-multiple/trigger.hbs
index 49d8b0d54..4974bcc84 100644
--- a/addon/templates/components/power-select-multiple/trigger.hbs
+++ b/addon/templates/components/power-select-multiple/trigger.hbs
@@ -10,7 +10,7 @@
{{/unless}}
{{#if selectedItemComponent}}
- {{component selectedItemComponent option=(readonly opt) select=(readonly select)}}
+ {{component selectedItemComponent extra=(readonly extra) option=(readonly opt) select=(readonly select)}}
{{else}}
{{yield opt select}}
{{/if}}
@@ -36,4 +36,4 @@
onkeydown={{action "onKeydown"}}>
{{/if}}
-
\ No newline at end of file
+
diff --git a/tests/dummy/app/templates/components/selected-item-country.hbs b/tests/dummy/app/templates/components/selected-item-country.hbs
index ec9ae4ef9..f268ff64d 100644
--- a/tests/dummy/app/templates/components/selected-item-country.hbs
+++ b/tests/dummy/app/templates/components/selected-item-country.hbs
@@ -1,2 +1,2 @@
-
-{{select.selected.name}}
\ No newline at end of file
+
+{{select.selected.name}}
diff --git a/tests/integration/components/power-select/customization-with-components-test.js b/tests/integration/components/power-select/customization-with-components-test.js
index 93c0a464b..7edce38d1 100644
--- a/tests/integration/components/power-select/customization-with-components-test.js
+++ b/tests/integration/components/power-select/customization-with-components-test.js
@@ -272,4 +272,26 @@ module('Integration | Component | Ember Power Select (Customization using compon
await clickTrigger();
});
+
+ test('the power-select-multiple `selectedItemComponent` receives the `extra` hash', async function(assert) {
+ assert.expect(1);
+
+ this.countries = countries;
+ this.country = [countries[1]]; // Spain
+
+ await render(hbs`
+