Skip to content
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

chore: Remove the obsolete coverage-related stuff #677

Merged
merged 1 commit into from
Oct 18, 2023
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
3 changes: 0 additions & 3 deletions lib/constraints.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,6 @@ const UIAUTOMATOR2_CONSTRAINTS = {
skipServerInstallation: {
isBoolean: true,
},
androidCoverageEndIntent: {
isString: true,
},
disableSuppressAccessibilityService: {
isBoolean: true,
},
Expand Down
23 changes: 0 additions & 23 deletions lib/driver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -686,14 +686,6 @@ class AndroidUiautomator2Driver
`and waiting for '${appWaitPackage}/${appWaitActivity}'`
);

if (this.caps.androidCoverage) {
this.log.info(
`androidCoverage is configured. ` +
` Starting instrumentation of '${this.caps.androidCoverage}'...`
);
await this.adb!.androidCoverage(this.caps.androidCoverage, appWaitPackage!, appWaitActivity!);
return;
}
if (
this.opts.noReset &&
!this.opts.forceAppLaunch &&
Expand Down Expand Up @@ -771,21 +763,6 @@ class AndroidUiautomator2Driver
})
);

if (this.caps.androidCoverage) {
this.log.info('Shutting down the adb process of instrumentation...');
await this.adb.endAndroidCoverage();
// Use this broadcast intent to notify it's time to dump coverage to file
if (this.caps.androidCoverageEndIntent) {
this.log.info(
`Sending intent broadcast '${this.caps.androidCoverageEndIntent}' at the end of instrumenting.`
);
await this.adb.broadcast(this.caps.androidCoverageEndIntent);
} else {
this.log.warn(
'No androidCoverageEndIntent is configured in caps. Possibly you cannot get coverage file.'
);
}
}
if (this.opts.appPackage) {
if (
!this.isChromeSession &&
Expand Down
Loading