Details
-
Bug
-
Resolution: Done
-
Blocker
-
None
Description
https://github.com/infinispan/infinispan/pull/4508 wrapped TestNG`s ITestNGMethod in our own NamedTestMethod. But because NamedTestMethod doesn't implement equals(), TestNG doesn't properly keep track of methods that have already run, and never runs @AfterClass methods.
This means threads started by AbstractInfinispanTest.fork() and cache managers started by tests with @CleanupAfterTest are not properly stopped. In turn, that makes it impossible to run two tests with the same name, and eventually the test suite can no longer start new threads.