Cypress is asserting in the original HTML source of the page (view-source
) instead of the DOM, is that ok?
#15114
Unanswered
melibe23
asked this question in
Questions and Help
Replies: 1 comment
-
What is the markup for your meta robots element? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Current tag in DOM Chrome:
My test:it(

Check "meta[name="robots"]
, function() {cy.get(
meta[name="robots"]
).should(
exist
).and("have.attr", "content", "null");
});
Outcome:
image
Expected (or maybe I am wrong) > attr CONTENT should exist and its value should be the string "null".
This is happening because Cypress is asserting in the original HTML source of the page (view-source) instead of the DOM, is that ok?
Data:
Cypress Version 6.4.0
Chrome Version 88.0.4324.150 (Official Build) (x86_64)
MacOS Catalina 10.15.7 (19H2)
Beta Was this translation helpful? Give feedback.
All reactions