-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
wip: Upgrade to webdriverio 9 #100
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #100 +/- ##
==========================================
+ Coverage 91.11% 92.32% +1.21%
==========================================
Files 18 18
Lines 394 391 -3
Branches 63 55 -8
==========================================
+ Hits 359 361 +2
+ Misses 31 30 -1
+ Partials 4 0 -4 ☔ View full report in Codecov by Sentry. |
@@ -52,7 +53,8 @@ export default abstract class BrowserCreator { | |||
await browser.setTimeout({ implicit: options.implicitTimeout, script: options.scriptTimeout }); | |||
|
|||
if (!browser.isMobile) { | |||
await browser.$('body').then(body => body.moveTo({ xOffset: 0, yOffset: 0 })); | |||
const body = await browser.$('//body'); | |||
body.moveTo({ xOffset: 0, yOffset: 0 }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is the return of moveTo
? Is it a promise?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah good catch! webdriverio 9 does a lot more promise chaining magic under the hood, so it might be that it handles this anyway, but makes sense to make it more explicit
Issue #, if available: AWSUI-51276
Description of changes:
WIP of upgrading to webdriverio. However, some outstanding bugs need to be fixed on webdriverio side before this can continue:
$('body')
returns no results in v9 webdriverio/webdriverio#13440By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.