O'Reilly logo

Quality Code: Software Testing Principles, Practices, and Patterns by Stephen Vance

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. Test-Driven Java

The first example demonstrates the use of test-driven development to create a new application in Java. I call the project WebRetriever; it is basically a work-alike of a subset of the command-line curl(1)1 command found in most Linux distributions and Mac OS X. If you are not familiar with curl, it is a tool for retrieving content over the internet that can be specified as URIs, including authentication, cookie management, and many more features.

1. http://curl.haxx.se/docs/manpage.html

The project has the benefit of being relatively small and straightforward, yet ripe for a number of the techniques from the book, in no small part due to its use of the network and, more specifically, the Apache HttpClient2 library. ...

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