-
Notifications
You must be signed in to change notification settings - Fork 0
Build Unification - WDIO Mocha, Cucumber, Jasmine #15
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
base: v8
Are you sure you want to change the base?
Conversation
|
LGTM, lets, get another review |
| import type { Options } from '@wdio/types' | ||
|
|
||
| import { BROWSERSTACK_TESTHUB_UUID } from '../constants.js' | ||
| const logDir = 'logs' |
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.
Please add a line after import statements
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.
Done
| } | ||
| if (percySnapshot && percySnapshot.percyScreenshot) { | ||
| screenshotHandler = percySnapshot.percyScreenshot | ||
| screenshotHandler = (browser: WebdriverIO.Browser | WebdriverIO.MultiRemoteBrowser | string, screenshotName: any, options?: any) => { |
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.
Can we give types to screenshotName and options?
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.
Percy screenshot method accepts arguments with method overloading. Arguments accepted are either (browser, name, options) or (name, options) where options can be in any format. Hence I've kept the parameter types to any.
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.
screenshotName should be string only no?
| } | ||
| if (percyAppScreenshot) { | ||
| screenshotAppHandler = percyAppScreenshot | ||
| screenshotAppHandler = (driverOrName: any, nameOrOptions?: any, options?: any) => { |
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.
here also
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.
| } | ||
|
|
||
| if (this._options.testObservability) { | ||
| const shouldSetupPercy = this._options.percy || (isUndefined(this._options.percy) && this._options.app) |
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.
percy auto-enabled needs to be handled?
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.
The condition after || is for auto enabling percy for App sessions.
| if (!passed) { | ||
| this._failReasons.push((error && error.message) || 'Unknown Error') | ||
| } | ||
| await this._accessibilityHandler?.afterTest(this._suiteTitle, test) |
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.
why changing order?
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.
So that the data being populated for saving Accessibility test results is correctly populated (ref) (specifically test uuid)
| import { BStackLogger } from '../bstackLogger.js' | ||
|
|
||
| import { shouldProcessEventForTesthub } from '../testHub/utils.js' | ||
| class Listener { |
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.
Please add line after import
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.
Done.
|
|
||
| try { | ||
| const url = `${DATA_ENDPOINT}/${eventUrl}` | ||
| const url = `${ENDPOINT}/${eventUrl}` |
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.
ENDPOINT ? intended ?
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.
Changed.
Proposed changes
Types of changes
Checklist
Backport Request
//: # (The current
mainbranch is the development branch for WebdriverIO v9. If your change should be released to the current major version of WebdriverIO (v8), please raise another PR with the same changes against thev8branch.)v9and doesn't need to be back-ported#XXXXXFurther comments
Reviewers: @webdriverio/project-committers