Adam Bien's Weblog

Java EE 7 Sample With JPA Integration Tests Released

The v0.0.3 version of Java EE Boundary Control Entity project is available.

New in this version are automated JPA integration tests:


public class RegistrationIT {

    EntityManager em;
    EntityTransaction tx;

    @Before
    public void initEM() {
        this.em = Persistence.createEntityManagerFactory("integration-test").createEntityManager();
        this.tx = this.em.getTransaction();
    }
  (...)
}

Execute:


mvn archetype:generate -Dfilter=com.airhacks:javaee-bce-archetype

then


mvn clean install
mvn failsafe:integration-test

See you at Java EE Workshops at MUC Airport or on demand and in a location very near you: airhacks.io!


NEW workshop: HTML 5 and JavaScript Essentials, Three days in April 2017: from Java EE 7 Architectures over Microservices to Performance, Troubleshooting and Monitoring
On demand workshops: Java EE 7: Bootstrap, Effective, Testing and Microservices available for streaming.

Newsletter: airhacks.news

A book about rethinking Java EE Patterns

Comments:

Post a Comment:
  • HTML Syntax: NOT allowed
realworldpatterns.com
Online Workshops
...the last 150 posts
...the last 10 comments
License