xUnit Test Patterns: Refactoring Test Code by Gerard Meszaros, Martin Fowler (Foreword by)

BUY IT NEW

  • $59.99 Online price
    $47.99 Member price
    (Save 20%)
    Limited Time Offer! Everyone receives the Member Price on books.
    See Details
  • skip to cart
  • Add To List uiAction=GetAllLists&page=List&pageType=list&ean=9780131495050&productCode=BK&maxCount=100&threshold=3

GET FREE SHIPPING ON ORDERS OF $25 OR MORE

DELIVERY & GIFT DETAILS:

Usually ships within 24 hours

Delivery Time and Shipping Rates

Eligible for gift wrap & gift message.

BUY IT USED

6 copies from $42.77

See All Available

Pick Me Up

Reserve it at BN.com & pick it up in 60 minutes at your local store.

Enter a zip code

(Hardcover)

  • Pub. Date: June 2007
  • 944pp
  • Sales Rank: 288,270

    Reader Rating: (1 ratings)

    Detailed Rating: "Professionals" See All

    Buy it Used: 6 copies from $42.77 See All Available

    Customers who bought this also bought

     
    • Overview
    • Editorial Reviews
    • Customer Reviews
    • Features

    Product Details

    • Pub. Date: June 2007
    • Publisher: Addison-Wesley
    • Format: Hardcover, 944pp
    • Sales Rank: 288,270

    Synopsis

    XUnit Test Patterns uses the practice of patterns to share proven techniques for writing automated tests using the XUnit family (e.g., JUnit and NUnit) of test automation frameworks. When properly applied, these patterns result in tests that are easier to write, easier to understand, more robust and repeatable, easier to maintain, and ultimately more cost-effective.

    • Maximize software return on investment by learning how to refactor test code and reduce or prevent crippling test maintenance.
    • All patterns are introduced with a narrative section discussing the principles behind each one.
    • Includes a comprehensive glossary of testing and test automation terms.

    Software testing has received renewed attention with the widespread adoption of Extreme Programming and other agile methodologies. The under-appreciated practice of testing provides a timely and accurate measurement--a reality check--so that developers know whether any new action needs to be taken. And automated software testing ensures that once the software works, it is not accidentally broken during subsequent software development or maintenance activities.

    More Reviews and Recommendations

    Biography

    Gerard Meszaros is a Senior Consultant with ClearStream Consulting, Inc., an Alberta-based advanced technology consulting firm. Over the years he has been involved in a wide range of large-scale, corporate-wide projects, offering specialist services and vast experience to some of the most successful organizations worldwide.

    Customer Reviews

    • Reader Rating:
    • Ratings: 1Reviews: 1

    Great, easy to read and invaluable! Definitely a relevant TDD/Patterns reference that's a must haveby MattPenner

    Reader Rating:
    See Detailed Ratings

    May 14, 2009: x/Unit patterns is a great book that fills a void I unconsciously would run into in projects using TDD. While several great books have been written about how to design and refactor our application code not much critical practical attention has been given to how to write test code. Most of it has been "do what I do" or heated discussions on why one strategy is better than another. I would often see "smells" end up in my test code, which I would attempt to refactor out. Yet, since I am still learning TDD I would often re-refactor my TDD code because I would often change my mind about why I made a change. I would also question whether or not I really was improving my project code by refactoring my TDD code.

    xUnit Test Patterns definitely is a great addition to this space and fills a much needed gap. It helps put much needed background, concrete analysis and details around these areas. It will easily become a staple in the modern developer's reference collection.

    This is not an intro to TDD book. If you do not use TDD and are wondering just what it is I would suggest you look elsewhere. If I had been given this book when I was entering the TDD space I would have been overwhelmed.

    If you have used TDD on a project or two, with varying success, this would be a great book. It's a very easy read with a basic understanding of TDD. It opened my eyes on exactly why TAD (test after development) was much worse than simply "don't do it that way". It allows me to help explain TDD much better than saying, "just because you're supposed to". Gerard explains the very fundamental reason behind the various hot & controversial strategies and where they may each be used with confidence. Of course, he explains why it may be very bad to use in certain situations, which are usually producing smells in our test code.

    In the first half Gerard gives a very thorough tour through the TDD space including the benefits of using TDD, various strategies and their pros/cons, details of how most xUnit frameworks work and so on. Most of this is probably fairly familiar ground for those who are intermediate in TDD but it's a very quick read through. It filled in a few holes for me, but most importantly, like other refactoring/patterns books it helps put a concrete framework and names around the various methods. It helps facilitate great conversations where developers using TDD can speak on a common ground, an area that, at least in my circles, has been lacking.

    The 2nd half details the actual patterns. Much in Fowler-academic pattern style, each pattern is listed with its name, what it attempts to accomplish, pros/cons and samples of use. He includes a vast amount of patterns, many of which I have ran into yet not been able to put my finger on why I decided to use it in one project and not another. He also makes a great case why the same pattern may be very useful in one context but an anti-pattern in another. Looking at the various pros/cons I really began to fill out my arsenal, if you will, with strategies I used to dismiss, however, in certain difficult contexts they would have actually fit the need perfectly.

    If you have been using TDD in your projects, with whatever level of success, I would definitely recommend you add this book to your collection. As I said above, it's a quick yet detailed read and adds much needed tools to your TDD tool belt.