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
Sorry, the example is described in #231. If you have multiple test classes using the resource, the second test class to run using the resource will have problems if the tests are not run in a fork.
I understand this a little better now. The forkCount is 1 by default. It's the reuseForks bit that is actually important. It makes each test class run in a new VM, which means each test class individually triggers VM shutdown hooks, which causes the appropriate shutdown steps to happen before a new mongo/lightblue-rest can be stood up.
A fix would be to make those not VM shutdown hooks and just call them at the end of the rule like normal rules.
Taken from discussion in #231
You have to tell surefire to run the tests in a fork for this to work:
This should probably be documented somewhere. Another solution would be to find a way to remove this requirement.
Thanks!
The text was updated successfully, but these errors were encountered: