featurist / browser-monkey

Reliable DOM testing
https://browsermonkey.org
53 stars 6 forks source link

shouldHave arrays of attributes #61

Closed dereke closed 7 years ago

dereke commented 7 years ago

allow shouldHave to assert an array of attribues exist on matched elements

  monkey.find('img').shouldHave({
    attributes: [
      {src: '/a.png', alt: 'some picture of an a'},
      {src: '/b.jpg', alt: 'b as a jpg'},
    ]
  })