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

Support platformVersion capability when filtering devices #576

Merged

Conversation

kandji-joel
Copy link
Contributor

I'd like to be able to target devices with a specific sdk (appium:platformVersion).

I tried to use appium:minSDK while adding appium:maxSDK however found this to not work when device sdk couldn't be casted to a number (e.g. 16.1.1).

So the easiest way to support my workflow was to consider platformVersion when filtering devices by capability

@saikrishna321
Copy link
Member

saikrishna321 commented Dec 8, 2022

@JoelWhitney This PR will only filter devices which has exactMatch to the platformVersion?

@kandji-joel
Copy link
Contributor Author

kandji-joel commented Dec 8, 2022

@saikrishna321 yes, exactly. If appium:platformVersion is provided as a capability than it will only return a device if there is an exact match, so requesting a device that is sdk 16.1.1 would not return a device that is 16.1.

Also, while testing this, I found that appium:minSDK does not work if you have devices on patch versions e.g. 15.7.1. In this case, requesting a device that has a minSDK of 16 will still return the 15.7.1 device — I’ll had a separate issue for this.

@SrinivasanTarget
Copy link
Member

@kandji-joel Can you please update the readme?

@kandji-joel
Copy link
Contributor Author

@SrinivasanTarget I updated the readme to include appium:platformVersion in table of capabilities

@saikrishna321 saikrishna321 merged commit 15f6633 into AppiumTestDistribution:main Dec 8, 2022
@kandji-joel
Copy link
Contributor Author

@saikrishna321
Copy link
Member

@kandji-joel Released now. Please check

@kandji-joel
Copy link
Contributor Author

@saikrishna321 Looks good, thank you!

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