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

Add number_of_retries feature #306

Open
ChrisBAshton opened this issue Oct 30, 2015 · 0 comments
Open

Add number_of_retries feature #306

ChrisBAshton opened this issue Oct 30, 2015 · 0 comments

Comments

@ChrisBAshton
Copy link
Contributor

Suggested addition to the YAML config api (at the root level of the file, i.e. not under a path):

number_of_retries: 1 # default 0

This value will determine the number of times Wraith will take a fresh screenshot if one of the paths in your file generates an unacceptable diff. For example, you might visit /foo and take a screenshot but the server was under strain and unable to deliver your CSS stylesheet in time, thereby failing your Wraith test. With number_of_retries set to n, Wraith will take the screenshot again and again, either until the test passes (Wraith succeeds) or until n has been reached (Wraith fails).

Random one-offs do happen. The web isn't perfect. Servers can be slow, or down, as can our client internet connection. We use Wraith to test that our application renders consistently while we make changes to the code - we DON'T use Wraith to test the integrity of our servers. That's better suited to load testing.

You might run a Wraith test and 9/10 times it will pass, but occasionally it won't. It's very frustrating for a 30-minute CI build to fail because of one path, on one environment, at one screen size, having a momentary hiccough.

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

No branches or pull requests

1 participant