How do you check for a background image in nightwatch? How do you make sure a background image is correctly loaded? Background image is loaded using css.
Hope this helps:
browser.waitForElementVisible('.someSelector', 15000)
browser.expect.element('.someSelector').to.have.css('background-image').which.equals('url("https://www.someimage.com/image1.png")');
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With