Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions lib/types.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import {type HTTPHeaders} from '@appium/types';

// WebDriverAgentLib/Utilities/FBSettings.h
export interface WDASettings {
elementResponseAttribute?: string;
Expand Down Expand Up @@ -92,6 +94,7 @@ export interface WebDriverAgentArgs {
resultBundleVersion?: string;
reqBasePath?: string;
launchTimeout?: number;
extraRequestHeaders?: HTTPHeaders;
}

export interface AppleDevice {
Expand Down Expand Up @@ -138,4 +141,5 @@ export interface XcodeBuildArgs {
allowProvisioningDeviceRegistration?: boolean;
resultBundlePath?: string;
resultBundleVersion?: string;
extraRequestHeaders?: HTTPHeaders;
}
3 changes: 3 additions & 0 deletions lib/webdriveragent.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
agentPath: string;
readonly args: WebDriverAgentArgs;
private readonly log: AppiumLogger;
readonly device: AppleDevice;

Check warning on line 43 in lib/webdriveragent.ts

View workflow job for this annotation

GitHub Actions / node_test (20)

Member device should be declared before all private instance field definitions

Check warning on line 43 in lib/webdriveragent.ts

View workflow job for this annotation

GitHub Actions / node_test (22)

Member device should be declared before all private instance field definitions

Check warning on line 43 in lib/webdriveragent.ts

View workflow job for this annotation

GitHub Actions / node_test (24)

Member device should be declared before all private instance field definitions
readonly platformVersion?: string;
readonly platformName?: string;
readonly iosSdkVersion?: string;
Expand Down Expand Up @@ -346,6 +346,7 @@
timeout: this.wdaConnectionTimeout,
keepAlive: true,
scheme: this.url.protocol ? this.url.protocol.replace(':', '') : 'http',
headers: this.args.extraRequestHeaders,
};
if (this.args.reqBasePath) {
proxyOpts.reqBasePath = this.args.reqBasePath;
Expand Down Expand Up @@ -560,10 +561,12 @@
*/
private async getStatus(timeoutMs: number = 0): Promise<StringRecord | null> {
const noSessionProxy = new NoSessionProxy({
scheme: this.url.protocol ? this.url.protocol.replace(':', '') : 'http',
server: this.url.hostname ?? undefined,
port: parseInt(this.url.port ?? '', 10) || undefined,
base: this.basePath,
timeout: 3000,
headers: this.args.extraRequestHeaders,
});

const sendGetStatus = async () =>
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@
"typescript": "^6.0.2"
},
"dependencies": {
"@appium/base-driver": "^10.0.0-rc.1",
"@appium/base-driver": "^10.3.0",
"@appium/strongbox": "^1.0.0-rc.1",
"@appium/support": "^7.0.0-rc.1",
"appium-ios-device": "^3.0.0",
Expand Down
Loading