On Thu, 01 May 2014 10:01:19 -0400, Atila Neves <[email protected]>
wrote:
On Thursday, 1 May 2014 at 11:44:12 UTC, w0rp wrote:
On Thursday, 1 May 2014 at 11:05:55 UTC, Jacob Carlborg wrote:
On 2014-04-30 23:35, Andrei Alexandrescu wrote:
Agreed. I think we should look into parallelizing all unittests. --
Andrei
I recommend running the tests in random order as well.
This is a bad idea. Tests could fail only some of the time. Even if
bugs are missed, I would prefer it if tests did exactly the same thing
every time.
They _should_ do exactly the same thing every time. Which is why running
in threads or at random is a great way to enforce that.
But not a great way to debug it.
If your test failure depends on ordering, then the next run will be random
too.
Proposal runtime parameter for pre-main consumption:
./myprog --rndunit[=seed]
To run unit tests randomly. Prints out as first order of business the seed
value before starting. That way, you can repeat the exact same ordering
for debugging.
-Steve