Simulation is not cleared when running tests
I can't understand why but after 24510f16 Simulation.Instance
is no longer null when I start the tests. Somehow unity keeps its state from playmode. What's even stranger is that this problem seems to persist even with a fresh start of the editor and without entering playmode before running the tests. (I put a breakpoint inside Simulation.CreateOnce()
and it looks like this function is not called during testing.)
As a result, when testing people a visitorArrivalChance
of 0.01 is used instead of 1 which obviously results in failed tests.
I've been looking for the root of the issue for some time now but I'm still clueless. I didn't add anything closely related to the construction of Simulation
in the commit mentioned above.
The only solution I see right now is to change the tests such that Simulation
is reinitialised properly before each test.