Skip to content

Commit

Permalink
fix(tests): fix e2e tests for the Typeahead demo (#5644)
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitry-zhemchugov authored Feb 5, 2020
1 parent 0b4721d commit 690f836
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions cypress/full/typeahead_page_spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,14 +75,14 @@ describe('Typeahead demo page test suite', () => {
typeahead.isElementVisible(asyncData, typeahead.cardHeader);
typeahead.isPreviewExist(asyncData, formTemplate);
typeahead.isElementVisible(asyncData, typeahead.inputSelector);
typeahead.isInputHaveAttrs(asyncData, [{ attr: 'placeholder', value: 'Locations loaded with timeout' }]);
typeahead.isInputHaveAttrs(asyncData, [{ attr: 'placeholder', value: 'Locations loaded via observable' }]);
});

it('when user starts to type a name of a State a drop-down with matches is shown, only 7 matches are shown',
it('when user starts to type a name of a State a drop-down with matches is shown, only 20 matches are shown',
() => {
typeahead.clearInputAndSendKeys(asyncData, 'a');
typeahead.isElementVisible(asyncData, typeahead.activeDropdown);
typeahead.isDropdownHasNItems(typeahead.dropdownBtn, 7);
typeahead.isDropdownHasNItems(typeahead.dropdownBtn, 20);
});

it('when user clicks on any item in typeahead drop-down, then typeahead container auto-fills with a selected State',
Expand Down Expand Up @@ -436,7 +436,7 @@ describe('Typeahead demo page test suite', () => {
typeahead.isElementVisible(scrollable, typeahead.inputSelector);
});

it.only(`when there are any matches then a drop-down with a list of States matches is shown. user is able to scroll
it(`when there are any matches then a drop-down with a list of States matches is shown. user is able to scroll
down/up to see the matches list`, () => {
typeahead.clearInputAndSendKeys(scrollable, textToInput);
typeahead.isElementVisible(scrollable, typeahead.activeDropdown);
Expand Down

0 comments on commit 690f836

Please sign in to comment.