Is there any way I can get the test result in the teardown (@After) method? I\'d like to do clean up after the tests depending on the result.
@After
Could not
Yes, if you use TestNG, it is a standard function, your @After method can look like this:
@AfterTest public void cleanUp( ITestResult result ) { boolean success = result.isSuccess(); ....