Home | History | Annotate | Download | only in alwaysrun
      1 package test.alwaysrun;
      2 
      3 import org.testng.annotations.AfterClass;
      4 import org.testng.annotations.BeforeClass;
      5 
      6 public class AlwaysRunAfter2 {
      7 
      8   private static boolean m_success = true;
      9 
     10   @BeforeClass
     11   public void setUpShouldFail() {
     12     throw new RuntimeException("Failing in setUp");
     13   }
     14 
     15   // Should not be run
     16   @AfterClass
     17   public void tearDown() {
     18     m_success = false;
     19   }
     20 
     21   static public boolean success() {
     22     return m_success;
     23   }
     24 }
     25