JUnit, Java's most ubiquitous testing framework, is getting an update. In part one of our JUnit 5 coverage, we looked at how we got here and wrote some preliminary tests. In part two, we take a closer look at how to run tests and at some of the very cool new features JUnit 5 brings to the table for us developers.
JUnit, Java's most ubiquitous testing framework, is getting an update. Yes, JUnit 5 is a complete rewrite that decouples "JUnit the Platform" from "JUnit the Tool" and makes the platform available to other testing frameworks, which might very well redefine the future of testing on the JVM. More than that, it evolves the API and has a very promising extension model.
Automated acceptance testing reduces time wasted in manual testing and bug fixing, and when combined with Behaviour-Driven Development, can guide development effort. But it requires skill, practice and discipline. The Screenplay Pattern helps teams address these difficulties and is where you may end up by mercilessly refactoring Page Objects using SOLID design principles.
In this important and thorough treatise “Integration Testing from the Trenches” Nicolas Frankel starts from basics and develops integration testing with a casual formalism that's intuitive and fun.
Using so-called "matcher libraries" to implement custom assertions to make tests more readable and maintainable. 2
Hadoop MapReduce jobs have a unique code architecture that raises interesting issues for test-driven development. In this article Michael Spicuzza shows how to use MRUnit to solve these problems. 1
Bertrand Paquet and Gael Lazzari of Octo Technology explore Unit Testing GWT applications and introduce their own open source gwt-test-utils framework. 2
Interview and Book Excerpt: Hani Suleiman & Cedric Beust, "Next Generation Java Testing: TestNG and Advanced Concepts"
InfoQ.com recently interviewed Next Generation Java Testing: TestNG and Advanced Concepts authors Hani Suleiman and Cédric Beust. InfoQ is also pleased to offer a chapter excerpt, "Mocks and Stubs". 4
Iterative and continuous are terms that are often used in reference to testing of software. This new InfoQ article takes a look at whether the same concepts can be applied to performance tuning. 16
Srini & Kavitha Penchikala give an overview of the support provided by Spring framework in the areas of unit and integration testing, with a sample application. 16
Continuous Integration has become a standard development best practice - but it's not always done well. InfoQ presents advice and examples in Chapter 6: Continuous Testing from a new CI book. 4
Today, almost every modern application consumes or produces XML. Stefan Bodewig explains the challenges in testing XML-based applications, and shows how to use the XMLUnit Java Framework to do so. 8