Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

cypress check attribute for each element

cy.get('ul')
  .find('li')
  .each((el) => {
  	expect(Cypress.$(el)).to.have.class(
  		'classname'
  	)
 })
Source by www.webtips.dev #
 
PREVIOUS NEXT
Tagged: #cypress #check #attribute #element
ADD COMMENT
Topic
Name
2+5 =