I need some way to execute code before/after each test. This code should be the same for all tests and test cases globally. I was hoping I could use RunListener, but it seems that I need to alter all the tests (or their parent class) to specify custom test runner or use JUnitCore for it to work.
Is there any way I can register this listener without affecting the code base? (there are many many tests and I would need to alter a lot of them for the listener to work)