O'Reilly logo

JUnit in Action, Second Edition by Gary Gregory, Vincent Massol, Felipe Leme, Petar Tahchiev

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

Chapter 14. Server-side Java testing with Cactus

Good design at good times. Make it run, make it run right.

Kent Beck, Test Driven Development: By Example

This chapter covers

  • Drawbacks of mock objects
  • Testing inside the container with Cactus
  • How Cactus works
  • Integrating Cactus with other projects, including Ant and Maven

In the second part of the book we explained what mock objects are and how to benefit from using them. We also described different techniques for unit testing your server-side code, and we even compared these techniques against each other. The one thing that you should be aware of now is that there is no absolute truth—the best techniques to use depend on the situation you’re currently in. For example, in most cases you ...

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