File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -191,7 +191,7 @@ will not work:
191
191
cy .origin (' https://example.cypress.io' , () => {
192
192
cy .visit (' /' )
193
193
cy .get (' h1' ) // Yields an element, which can't be serialized...
194
- }).contains (' CYPRESS ' ) // ...so this will fail
194
+ }).contains (' Kitchen Sink ' ) // ...so this will fail
195
195
```
196
196
197
197
Instead, you must explicitly yield a serializable value:
@@ -201,8 +201,8 @@ Instead, you must explicitly yield a serializable value:
201
201
``` js
202
202
cy .origin (' https://example.cypress.io' , () => {
203
203
cy .visit (' /' )
204
- cy .get (' h1' ).invoke (' textContent ' ) // Yields a string...
205
- }).should (' equal' , ' CYPRESS ' ) // 👍
204
+ cy .get (' h1' ).invoke (' text ' ) // Yields a string...
205
+ }).should (' equal' , ' Kitchen Sink ' ) // 👍
206
206
```
207
207
208
208
### Navigating to secondary origin with cy.visit
You can’t perform that action at this time.
0 commit comments