I have a test suite where I am logging out of the system in @After
and closing the browser in @AfterClass
. I am trying to use @Rule
to
What about using the ExternalResource rule ?
Looks like you it can give you enough flexibility to what you need.
And if this is not exactly what you need, take a look at the source code of external resource.
It's quite understandble how to implement a rule for example that will work only after the test invocation.