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

Pass the tests in both Day and Night mode #358

Closed
rocboronat opened this issue Aug 4, 2020 · 6 comments · Fixed by #359
Closed

Pass the tests in both Day and Night mode #358

rocboronat opened this issue Aug 4, 2020 · 6 comments · Fixed by #359
Labels

Comments

@rocboronat
Copy link
Member

Sometimes, when you develop the Night Mode you put there some if clauses.

It would be great that Barista passes the tests in both Day and Night mode, magically, just to try all the paths the code has.

@alorma
Copy link
Member

alorma commented Aug 4, 2020

You mean adding a Rule into our BaristaRule to run all tests twice? Or make it optional?

@alorma
Copy link
Member

alorma commented Aug 4, 2020

Also, we can create a rule to pass tests in both modes, day and night, but as an independent rule

@rocboronat
Copy link
Member Author

Ammmm I think that by default it should try both if the device offers the dark mode. But it should be easy to disable, in case the developer thinks it's not needed, either because the app code doesn't change between day and night or because it slows the tests too much.

@alorma
Copy link
Member

alorma commented Aug 4, 2020

Done in #359

@Sloy
Copy link
Member

Sloy commented Aug 4, 2020

I would not enable it by default because it can break things. For example, if the user depends on Orchestrator to clear the app data between tests. You need to know what you're doing.

@alorma alorma mentioned this issue Aug 4, 2020
@rocboronat rocboronat added the wip label Aug 18, 2020
@rocboronat
Copy link
Member Author

Let's go with just having the Night Mode Rule. I will add it to my own project Rule chain so that will do the job.

Thanks @alorma for the PR and @Sloy for the comments! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants