Skip to content

refactor: Replace non-W3C API calls with corresponding extension calls in app management#1883

Merged
mykola-mokhnach merged 3 commits intoappium:masterfrom
mykola-mokhnach:extensions
Apr 14, 2023
Merged

refactor: Replace non-W3C API calls with corresponding extension calls in app management#1883
mykola-mokhnach merged 3 commits intoappium:masterfrom
mykola-mokhnach:extensions

Conversation

@mykola-mokhnach
Copy link
Copy Markdown
Contributor

Change list

Eventually we should avoid creating wrappers for non-W3C-compatible endpoints as these endpoints are mostly legacy from mobile-specific commands. We should only provide mobile: extension for these.

I don't want to remove existing wrappers though as this could create extra headaches for clients. These should work same way as before, but call corresponding extensions under the hood.

I would say it makes sense to introduce similar changes to other clients as well (e.g. Python/Dotnet/Ruby)

cc @KazuCocoa @jlipps @Dor-bl

args.put("bundleId", bundleId);
args.put("appId", bundleId);
Optional.ofNullable(options).map(BaseOptions::build).ifPresent(args::putAll);
return CommandExecutionHelper.executeScript(this, "mobile: terminateApp", args);
Copy link
Copy Markdown
Member

@KazuCocoa KazuCocoa Apr 14, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

btw, does this include for mac2 driver as well? Then, mac2 driver needs macos instead of mobile
https://github.com/appium/appium-mac2-driver#macos-terminateapp
(queryAppState etc as well)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no, only AndroidDriver and IOSDriver implement this interface

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants