Search in sources :

Example 11 with InSequence

use of org.jboss.arquillian.junit.InSequence in project deltaspike by apache.

the class JtaTransactionalRepositoryAbstractTest method dep_scoped_bean_should_be_empty_after_tx.

@Test
@InSequence(32)
public void dep_scoped_bean_should_be_empty_after_tx() throws Exception {
    // when
    Simple simple = simpleClientDep.getSimple();
    // then
    assertNotNull(simple);
}
Also used : Simple(org.apache.deltaspike.data.test.ee7.domain.Simple) Test(org.junit.Test) InSequence(org.jboss.arquillian.junit.InSequence)

Example 12 with InSequence

use of org.jboss.arquillian.junit.InSequence in project deltaspike by apache.

the class JtaTransactionalRepositoryAbstractTest method should_save_when_dep_scoped_bean_is_found.

@Test
@InSequence(31)
public void should_save_when_dep_scoped_bean_is_found() throws Exception {
    // when
    Simple simple = simpleClientDep.createSimple("dependent");
    Simple found = repository.findOptionalByName("dependent");
    // then
    assertNull(simple);
    assertNull(found);
}
Also used : Simple(org.apache.deltaspike.data.test.ee7.domain.Simple) Test(org.junit.Test) InSequence(org.jboss.arquillian.junit.InSequence)

Example 13 with InSequence

use of org.jboss.arquillian.junit.InSequence in project deltaspike by apache.

the class JtaTransactionalRepositoryInterfaceTest method should_save_in_transaction.

@Test
@InSequence(2)
public void should_save_in_transaction() throws Exception {
    // given
    Simple simple = new Simple(NAME);
    // when
    simple = repository.save(simple);
    // then
    assertNotNull(simple.getId());
    assertTrue(wrapper.isRunInTx());
}
Also used : Simple(org.apache.deltaspike.data.test.ee7.domain.Simple) Test(org.junit.Test) InSequence(org.jboss.arquillian.junit.InSequence)

Example 14 with InSequence

use of org.jboss.arquillian.junit.InSequence in project deltaspike by apache.

the class DeltaSpikeTransactionalRepositoryAbstractTest method should_save_in_transaction.

@Test
@InSequence(2)
public void should_save_in_transaction() throws Exception {
    // given
    Simple simple = new Simple(NAME);
    // when
    simple = repository.save(simple);
    // then
    assertNotNull(simple.getId());
    assertTrue(wrapper.isRunInTx());
}
Also used : Simple(org.apache.deltaspike.data.test.ee7.domain.Simple) Test(org.junit.Test) InSequence(org.jboss.arquillian.junit.InSequence)

Example 15 with InSequence

use of org.jboss.arquillian.junit.InSequence in project deltaspike by apache.

the class JtaTransactionalRepositoryAbstractTest method should_save_when_app_scoped_bean_is_found.

@Test
@InSequence(21)
public void should_save_when_app_scoped_bean_is_found() throws Exception {
    // when
    Simple simple = simpleClientApp.createSimple("application scoped");
    Simple found = repository.findOptionalByName("application scoped");
    // then
    assertNotNull(simple);
    assertNotNull(found);
    assertEquals("application scoped", found.getName());
}
Also used : Simple(org.apache.deltaspike.data.test.ee7.domain.Simple) Test(org.junit.Test) InSequence(org.jboss.arquillian.junit.InSequence)

Aggregations

InSequence (org.jboss.arquillian.junit.InSequence)103 Test (org.junit.Test)103 Simple (org.apache.deltaspike.data.test.ee7.domain.Simple)18 ModelNode (org.jboss.dmr.ModelNode)14 URL (java.net.URL)13 ModelControllerClient (org.jboss.as.controller.client.ModelControllerClient)8 PartitionManager (org.picketlink.idm.PartitionManager)7 StringTokenizer (java.util.StringTokenizer)6 IdentityManager (org.picketlink.idm.IdentityManager)6 RouteBuilder (org.apache.camel.builder.RouteBuilder)5 House (org.apache.deltaspike.data.test.ee7.domain.House)5 HttpResponse (org.apache.http.HttpResponse)5 HttpGet (org.apache.http.client.methods.HttpGet)5 OperateOnDeployment (org.jboss.arquillian.container.test.api.OperateOnDeployment)5 ManagementClient (org.jboss.as.arquillian.container.ManagementClient)5 EntityTest (org.jboss.as.test.integration.jpa.hibernate.EntityTest)5 User (org.picketlink.idm.model.basic.User)5 Date (java.util.Date)4 InitialContext (javax.naming.InitialContext)4 RunAsClient (org.jboss.arquillian.container.test.api.RunAsClient)4