Error: ReferenceError: window is not defined #11562
sdoigmm
started this conversation in
Technical Discussion
Replies: 1 comment
-
@sdoigmm WebdriverIO runs in a Node.js context and not in the browser (unless you use the browser runner). Therefor you can't use the |
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
-
My test has
await(await $('.upper-canvas')).moveTo(862,242); await(await $('.upper-canvas')).click();
but this position is missed by about 200px to the left.
To debug this I created a file
test.js
:(I want to console.log the position clicked by
$('.upper-canvas')).click();
).In my original test file I have
import getCursorPosition from '../pageobjects/test';
When running my test I receive an error
Error: ReferenceError: window is not defined
.This might be easy to fix for an experienced programmer.
Help appreciated.
Beta Was this translation helpful? Give feedback.
All reactions