Arquillian test not failing

91 Views Asked by At

When dependency injection in Arquillian test class fails, maven still claims that all tests are run and are passed. This is major issue if we have hundreds of tests and some tests show as Green in Jenkins, but in reality they are not driven at all.

Is there a way to make the above test fail in Jenkins/Maven? One can use any Interface long as there is no implementation added to deployment.

@ExtendWith(ArquillianExtension.class)
class FailingArquillianTestIssueIT {

@Inject
DummyInterface dummyInterface;

@Deployment(testable = true)
public static JavaArchive create() throws Exception {

    JavaArchive archive = ShrinkWrap.create(JavaArchive.class).addAsManifestResource(EmptyAsset.INSTANCE,
            "beans.xml");

    return archive;

}

@Test
void test1() {

    assertTrue(false);

}

}

enter image description here

0

There are 0 best solutions below