Uploaded image for project: 'Arquillian'
  1. Arquillian
  2. ARQ-1250

arquillian-junit-standalone doesn't execute @Before

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Major Major
    • None
    • 1.0.3.Final
    • None
    • None

      In following code, before() method won't be called at all:

      @RunWith(Arquillian.class)
      public class BeforeTestCase {
      
          private boolean initialized = false;
      
          @Before
          public void before() {
              initialized = true;
          }
      
          @Test
          public void test() {
              Assert.assertTrue("@Before should have initialized test", initialized);
          }
      }
      
      <dependency>
          <groupId>org.jboss.arquillian.junit</groupId>
          <artifactId>arquillian-junit-standalone</artifactId>
          <scope>test</scope>
      </dependency>
      

      When changed to arquillian-junit-container, everything works fine.

              lfryc Lukáš Fryč (Inactive)
              lfryc Lukáš Fryč (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: