Wallaby ordering tests

Hi,

I can’t find in Wallaby documentation if there is a possibility to set an order in which tests will run. Any suggestions?

Not sure you can. Whats the issue?

In my tests I am first creating a user and then I am logging him in. However, it’s often in other order, where it tries to log in a user that was not created yet.

Easiest way is to start every test with the sign in flow and then go to the page you want to test. But Im not a wallaby expert

1 Like

Thanks, I did think of this option however I was wondering if there is such a possibility. It does exist in Selenium so I hoped to find some similarities.

To answer the original question: it looks like what you want is to add the option --seed 0 to your mix test, which will make all tests execute in the order they are defined on the files. Here’re the docs for reference.

But as @andreaseriksson pointed out, the best would be to not rely on that because you lose some benefits like async testing too, for example.

1 Like