Last active
December 14, 2015 17:48
-
-
Save PiotrNowicki/5124212 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@RunWith(Arquillian.class) | |
public class BusinessLogicTest { | |
// without .addAsManifestResource(EmptyAsset.INSTANCE, "beans.xml") Arquillian is not injecting the EJB here (its null). | |
@EJB | |
BusinessLogic bl; | |
@Deployment | |
public static JavaArchive createDeployment() { | |
return ShrinkWrap.create(JavaArchive.class) | |
.addPackages(true, "com.piotrnowicki.spikes").addAsManifestResource("META-INF/persistence.xml", "persistence.xml").addAsManifestResource(EmptyAsset.INSTANCE, "beans.xml"); | |
} | |
@Test | |
public void should_create_greeting() { | |
System.out.println("Inside: " + bl); | |
bl.test(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment