-
-
Save trivial-search/0196e7db468c4bd60faf3aa9a2b3c681 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
it('verify the total count and existence of a particular element in the dropdown',() => { | |
// get the element and it's associated children | |
cy.get('#sort-by-menu-header > div > ul').children() | |
// perform the assertion on existence of a particular item in the drop down | |
.should('contain','New Arrivals') | |
// perform the assertion on the number of children i.e. options in the drop down | |
.and('have.length','6') | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment