JUnit in Action, Second Edition
- 7h 10m
- Felipe Leme, Gary Gregory, Petar Tahchiev, Vincent Massol
- Manning Publications
- 2011
When JUnit was first introduced a decade ago by Kent Beck and Erich Gamma, the Agile movement was in its infancy, "Test Driven Development" was unknown, and unit testing was just starting to move into the typical developer's vocabulary. Today, most developers acknowledge the benefits of unit testing and rely on the increasingly sophisticated tools now available. The recently released JUnit 4.5 represents the state of the art in unit testing frameworks, and provides significant new features to improve the Java development process.
JUnit in Action, Second Edition is an up-to-date guide to unit testing Java applications (including Java EE applications) using the JUnit framework and its extensions. This book provides techniques for solving real-world problems such as testing AJAX applications, using mocks to achieve testing isolation, in-container testing for Java EE and database applications, and test automation.
Written to help readers exploit JUnit 4.5, the book covers recent innovations such as the new annotations that simplify test writing, improved exception handling, and the new assertion methods. You'll also discover how to use JUnit extensions to test new application styles and frameworks including Ajax, OSGi, and HTML-based presentation layers.
Using a sample-driven approach, various unit testing strategies are covered, such as how to unit test EJBs, database applications, and web applications. Also addressed are testing strategies using freely available open source frameworks and tools, and how to unit test in isolation with Mock Objects. The book will also bring you up to speed on the latest thinking in TDD, BDD, Continuous Integration, and other practices related to unit testing.
About the Authors
Peter Tahchiev is a software engineer with HP and the Jakarta Cactus lead developer. Felipe Leme is a JCP member and contributor to DbUnit and Cactus.
Gary Gregory is a Java developer with 20+ years of experience who currently develops application servers for legacy integration.
Vincent Massol was the author of the first edition of JUnit in Action.
Petar Tahchiev is a software engineer with Hewlett Packard and serves as the Jakarta Cactus lead developer and a Jakarta PMC member with the Apache Software Foundation.
Felipe Leme lives in California and has worked as a software engineer with Java since 1996. He is a four-time repeat speaker at JavaOne, has written dozens of Java-related articles, and contributed to many open source projects including DbUnit and Jakarta Cactus.
Vincent Massol authored the original JUnit in Action and is a leading member of the Apache community. He lives near Paris and is Chief Technology Officer of XWiki which develops open source enterprise wikis and collaborative software products.
Gary Gregory is an active member of The Apache Software Foundation, the Apache Jakarta Project Management Committee and contributes regularly to various Apache Commons projects. He lives in California.
In this Book
-
About This Book
-
JUnit Jump-Start
-
Exploring Core JUnit
-
Mastering JUnit
-
Software Testing Principles
-
Test Coverage and Development
-
Coarse-Grained Testing with Stubs
-
Testing with Mock Objects
-
In-Container Testing
-
Running JUnit Tests from Ant
-
Running JUnit Tests from Maven2
-
Continuous Integration Tools
-
Presentation-Layer Testing
-
Ajax Testing
-
Server-Side Java Testing with Cactus
-
Testing JSF Applications
-
Testing OSGi Components
-
Testing Database Access
-
Testing JPA-Based Applications
-
JUnit on Steroids