O'Reilly logo

Spring Persistence with Hibernate by Ahmad Seddighi

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Summary

Unit testing, a critical part of application development, ensures that the application works as expected. A good practice for unit testing is to execute test classes automatically.

A test class is implemented for each Java class. Each test class includes the required methods for testing an application class in isolation from other application and test classes.

JUnit is a Java framework that simplifies test development. Using JUnit, you can easily verify that the method invocation results match the expected values. Extensions exist for the JUnit framework, such as Cactus, JMeter, DbUnit, HttpUnit, and so on.

To implement a test class with JUnit 3.8 and before, you only need to create a subclass of TestCase, and then implement the initialization ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required