Skip to content

Commit

Permalink
fix: correctly convert JWP capabilities to W3C
Browse files Browse the repository at this point in the history
The `processConfig()` function attempts to convert capabilities from the
deprecated JWP format to the new standard W3C one.

Fix the logic for detecting when capabilites are in JWP format.
(Previously, the logic was inverted.)
  • Loading branch information
gkalpak authored Oct 19, 2022
1 parent 69dcb82 commit c283d97
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/process-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ export function processConfig(config: any = {}, args: any = {}) {
};

// transform JWP capabilities into W3C capabilities for backward compatibility
if (isW3C(args)) {
if (!isW3C(args)) {
args.browserVersion = args.browserVersion || args.version || 'latest'
args.platformName = args.platformName || args.platform || 'Windows 10'
args['sauce:options'] = {...capabilitiesFromConfig, ...(args['sauce:options'] || {})}
Expand Down

0 comments on commit c283d97

Please sign in to comment.