Fix: WDIO integration using MCP#219
Merged
gaurav-singh-9227 merged 3 commits intobrowserstack:mainfrom Jan 30, 2026
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR aims to fix WebdriverIO (WDIO) integration in the BrowserStack MCP server by aligning framework enums, configuration maps, and handlers, and bumping the package version.
Changes:
- Reclassifies
webdriveriofrom a testing framework to a browser automation framework in shared types and BrowserStack SDK configuration (SUPPORTED_CONFIGURATIONS), and updates both BrowserStack-only and Percy+BrowserStack handlers to branch ondetectedBrowserAutomationFramework === "webdriverio". - Updates the user-facing RCA guidance text to explicitly mention using the RCA tool.
- Bumps the MCP server version to
1.2.11inpackage.json,package-lock.json, andserver.json.
Notes on behavior:
- With
webdriverioremoved fromSDKSupportedTestingFrameworkEnumbut still used as a testing-framework key inpercy-automate/frameworks.tsandpercy-bstack/frameworks.ts, Percy Automate and Percy+BrowserStack WDIO configurations will now be reported as unsupported viacheckPercyIntegrationSupportandgetPercyInstructionsunless those maps are updated to treat WebdriverIO as a browser automation framework (with testing frameworks likemocha/cucumber).
Reviewed changes
Copilot reviewed 8 out of 9 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
src/tools/sdk-utils/percy-bstack/handler.ts |
Switches WDIO special-casing to use detectedBrowserAutomationFramework === "webdriverio" so Percy+BrowserStack uses the correct SDK configuration path. |
src/tools/sdk-utils/common/utils.ts |
Tweaks the critical RCA follow-up message to explicitly mention using the RCA tool in non–Percy Web runs. |
src/tools/sdk-utils/common/types.ts |
Adds webdriverio to SDKSupportedBrowserAutomationFrameworkEnum, removes it from SDKSupportedTestingFrameworkEnum, and keeps ConfigMapping typings in sync—this is the source of the WDIO reclassification. |
src/tools/sdk-utils/bstack/sdkHandler.ts |
Aligns BrowserStack SDK-only flow so WDIO is handled as a browser automation framework (special-cased along with Cypress). |
src/tools/sdk-utils/bstack/frameworks.ts |
Updates SUPPORTED_CONFIGURATIONS so Node.js WDIO instructions live under webdriverio (automation framework) with mocha/cucumber testing frameworks. |
src/tools/sdk-utils/bstack/constants.ts |
Mirrors the WDIO move in the lower-level SUPPORTED_CONFIGURATIONS, assigning webdriverioInstructions under the webdriverio automation framework. |
server.json |
Updates the registered MCP server version to 1.2.11. |
package.json |
Bumps package version to 1.2.11 to reflect the WDIO integration changes. |
package-lock.json |
Syncs lockfile metadata with the new 1.2.11 package version. |
Comments suppressed due to low confidence (1)
src/tools/sdk-utils/common/types.ts:45
- Changing WebdriverIO from a testing framework to a browser automation framework in these enums without updating all of the corresponding configuration maps appears to break existing Percy flows. In particular,
SDKSupportedTestingFrameworkEnumno longer includeswebdriverio, butcheckPercyIntegrationSupportfor Percy Automate still relies onSDKSupportedTestingFrameworkEnumvalues when callingisPercyAutomateFrameworkSupported, whilesrc/tools/sdk-utils/percy-automate/frameworks.tsstill defines WebdriverIO support under theseleniumdriver withwebdriverioas the testing framework key. Similarly, Percy+BrowserStack usesgetPercyInstructionsbacked byPERCY_INSTRUCTIONSinsrc/tools/sdk-utils/percy-bstack/frameworks.ts, which currently defines WebdriverIO underseleniumwithwebdriverioas the testing framework key; with WebdriverIO now only present inSDKSupportedBrowserAutomationFrameworkEnum, Percy instructions for WebdriverIO via the MCP schemas can no longer be resolved. To avoid regressions and to make the MCP schemas consistent, either keepwebdriverioavailable in the testing enum, or (preferably) update the Percy Automate and Percy+BrowserStack configuration maps so that WebdriverIO is modeled as a browser automation framework (with appropriate testing frameworks likemocha/cucumber) in line with these enum changes.
export enum SDKSupportedBrowserAutomationFrameworkEnum {
playwright = "playwright",
selenium = "selenium",
cypress = "cypress",
webdriverio = "webdriverio",
}
export type SDKSupportedBrowserAutomationFramework =
keyof typeof SDKSupportedBrowserAutomationFrameworkEnum;
export enum SDKSupportedTestingFrameworkEnum {
jest = "jest",
codeceptjs = "codeceptjs",
playwright = "playwright",
pytest = "pytest",
robot = "robot",
behave = "behave",
cucumber = "cucumber",
nightwatch = "nightwatch",
mocha = "mocha",
junit4 = "junit4",
junit5 = "junit5",
testng = "testng",
cypress = "cypress",
nunit = "nunit",
mstest = "mstest",
xunit = "xunit",
specflow = "specflow",
reqnroll = "reqnroll",
rspec = "rspec",
serenity = "serenity",
}
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
gaurav-singh-9227
approved these changes
Jan 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.