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

Default description for asserting on enabled state is incorrect #2107

Open
1 task done
Fishbowler opened this issue Oct 22, 2024 · 1 comment · May be fixed by #2111
Open
1 task done

Default description for asserting on enabled state is incorrect #2107

Fishbowler opened this issue Oct 22, 2024 · 1 comment · May be fixed by #2111

Comments

@Fishbowler
Copy link
Contributor

Is there an existing issue for this?

  • I have searched the existing issues and didn't find mine.

Steps to reproduce

Given a demo app that shows a button called "Form Test" on the homepage (you know, like this one: https://github.com/mobile-dev-inc/demo_app) then run this flow:

appId: com.example.example
---

- launchApp

- assertNotVisible:
    text: 'Form Test'
    enabled: false

Actual results

║ ✅ Assert that "Form Test" is not visible

Expected results

║ ✅ Assert that "Form Test" (that is not enabled) is not visible

Would accept any less clumsy version of that text too :D

About app

Is the Demo App.
https://github.com/mobile-dev-inc/demo_app

About environment

Linux, Java 17.

Logs

No response

Maestro version

1.39.0

How did you install Maestro?

install script (https://get.maestro.mobile.dev)

Anything else?

It's not catered for.

override fun description(): String {
val optional = if (optional || condition.visible?.optional == true || condition.notVisible?.optional == true ) "(Optional) " else ""
return label ?: "Assert that $optional${condition.description()}"
}

Copy link

linear bot commented Oct 22, 2024

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 a pull request may close this issue.

1 participant