maestro icon indicating copy to clipboard operation
maestro copied to clipboard

Allow platform specific identifiers for tapOn and assertions

Open tajchert opened this issue 3 years ago • 1 comments
trafficstars

As most apps have very similar UX flows on both platforms, however in most cases developers do not use same id's for views on both platforms - it would be great to have the support of platform-specific id's. One that would use different for Android and iOS depending on which platform tests are running at.

Proposition:

- assertVisible:
    id: productName
- assertVisible:
    id:
      ios: productDescription
      android: product_desc

So on both platform we have a common id of productName but we have different id for product description so iOS will use productDescription and android would use product_desc. Assertion is just an example as this feature should be connected to id's in other usages as well (ex. tapOn as well).

This would allow to share across platforms most of the test in many apps (in my case it would probably allow to have 95% of same tests).

tajchert avatar Oct 23 '22 00:10 tajchert

This could be quite a nice feature!

simon-gilmurray avatar Oct 23 '22 12:10 simon-gilmurray