You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Feb 13, 2020. It is now read-only.
Tests that use hard-coded data tend to be brittle and difficult to parallelize. Depending on static fixtures is an easy crutch to get started, but it will burn you eventually. It's better to randomize test data from the start, which allows your tests to run independently of each other.
Test::Right provides the DataFactory to solve this. In your tests, you can use data[:foo] instead of "foo" anywhere you need a string, and each time you'll get a new, unique string. Use this same identifier throughout an individual test to consistently identify your widgets, then throw it away when the test is finished.