or
Sign in to turn on 1-Click ordering
Sell Us Your Item
For a $8.51 Gift Card
Trade in
More Buying Choices
Have one to sell? Sell yours here
Tell the Publisher!
I'd like to read this book on Kindle

Don't have a Kindle? Get your Kindle here, or download a FREE Kindle Reading App.
Sorry, this item is not available in
Image not available for
Color:
Image not available

To view this video download Flash Player

 

Test Driven Development: By Example [Paperback]

Kent Beck
3.9 out of 5 stars  See all reviews (47 customer reviews)

Buy New
$33.32 & FREE Shipping. Details
Rent
$25.43 & this item ships for FREE with Super Saver Shipping. Details
In Stock.
Ships from and sold by Amazon.com. Gift-wrap available.
In Stock.
Rented by RentU and Fulfilled by Amazon.
Want it tomorrow, June 20? Choose One-Day Shipping at checkout. Details
Free Two-Day Shipping for College Students with Amazon Student

Shop the new tech.book(store)
New! Introducing the tech.book(store), a hub for Software Developers and Architects, Networking Administrators, TPMs, and other technology professionals to find highly-rated and highly-relevant career resources. Shop books on programming and big data, or read this week's blog posts by authors and thought-leaders in the tech industry. > Shop now

Book Description

November 18, 2002 0321146530 978-0321146533 1
Quite simply, test-driven development is meant to eliminate fear in application development. While some fear is healthy (often viewed as a conscience that tells programmers to "be careful!"), the author believes that byproducts of fear include tentative, grumpy, and uncommunicative programmers who are unable to absorb constructive criticism. When programming teams buy into TDD, they immediately see positive results. They eliminate the fear involved in their jobs, and are better equipped to tackle the difficult challenges that face them. TDD eliminates tentative traits, it teaches programmers to communicate, and it encourages team members to seek out criticism However, even the author admits that grumpiness must be worked out individually! In short, the premise behind TDD is that code should be continually tested and refactored. Kent Beck teaches programmers by example, so they can painlessly and dramatically increase the quality of their work.

Frequently Bought Together

Test Driven Development: By Example + Clean Code: A Handbook of Agile Software Craftsmanship + Refactoring: Improving the Design of Existing Code
Price for all three: $112.39

Buy the selected items together


Editorial Reviews

From the Back Cover

Clean code that works--now. This is the seeming contradiction that lies behind much of the pain of programming. Test-driven development replies to this contradiction with a paradox--test the program before you write it.

A new idea? Not at all. Since the dawn of computing, programmers have been specifying the inputs and outputs before programming precisely. Test-driven development takes this age-old idea, mixes it with modern languages and programming environments, and cooks up a tasty stew guaranteed to satisfy your appetite for clean code that works--now.

Developers face complex programming challenges every day, yet they are not always readily prepared to determine the best solution. More often than not, such difficult projects generate a great deal of stress and bad code. To garner the strength and courage needed to surmount seemingly Herculean tasks, programmers should look to test-driven development (TDD), a proven set of techniques that encourage simple designs and test suites that inspire confidence.

By driving development with automated tests and then eliminating duplication, any developer can write reliable, bug-free code no matter what its level of complexity. Moreover, TDD encourages programmers to learn quickly, communicate more clearly, and seek out constructive feedback.

Readers will learn to:

  • Solve complicated tasks, beginning with the simple and proceeding to the more complex.
  • Write automated tests before coding.
  • Grow a design organically by refactoring to add design decisions one at a time.
  • Create tests for more complicated logic, including reflection and exceptions.
  • Use patterns to decide what tests to write.
  • Create tests using xUnit, the architecture at the heart of many programmer-oriented testing tools.
  • This book follows two TDD projects from start to finish, illustrating techniques programmers can use to easily and dramatically increase the quality of their work. The examples are followed by references to the featured TDD patterns and refactorings. With its emphasis on agile methods and fast development strategies, Test-Driven Development is sure to inspire readers to embrace these under-utilized but powerful techniques.



    0321146530B10172002

    About the Author

    Kent Beck consistently challenges software engineering dogma, promoting ideas like patterns, test-driven development, and Extreme Programming. Currently affiliated with Three Rivers Institute and Agitar Software, he is the author of many Addison-Wesley titles.




    Product Details

    • Paperback: 240 pages
    • Publisher: Addison-Wesley Professional; 1 edition (November 18, 2002)
    • Language: English
    • ISBN-10: 0321146530
    • ISBN-13: 978-0321146533
    • Product Dimensions: 7.6 x 0.5 x 9.2 inches
    • Shipping Weight: 1.1 pounds (View shipping rates and policies)
    • Average Customer Review: 3.9 out of 5 stars  See all reviews (47 customer reviews)
    • Amazon Best Sellers Rank: #20,346 in Books (See Top 100 in Books)

    More About the Author

    Discover books, learn about writers, read author blogs, and more.

    Customer Reviews

    You can really get a feel for the way that TDD can help make your project better. Matthew Haines  |  7 reviewers made a similar statement
    The books is probably written for better minds where mine fell short by a long distance. Mohammad Nafees Sharif Butt  |  2 reviewers made a similar statement
    Most Helpful Customer Reviews
    34 of 35 people found the following review helpful
    5.0 out of 5 stars Fail, Run, Run Clean February 4, 2003
    Format:Paperback
    The are a small number of writers who can teach programming skills effectively. Kent Beck is one of them. There are a small set of practices that you can adopt on your own that will have an clearly observable impact on the quality of your results and the quality of your work day. Test Driven Develoment (TDD) is one of them. If you are a software developer, you want to buy, read and study this book.

    TDD fits development into a three micro-phase cycle: create a test that embodies your requirement, write code that passes the test, make the code run clean. Each phase has different goals, patterns and pitfalls. Like any good coach, Beck walks you through these in detail. He uses multiple examples: most notably a business model in Java and a unit testing framework in Phython. He follows up with a question and answer section that reviews common patterns in test driven development cycle.

    The level of learning involved in doing TDD is profound. The best way to read the book is to do the book. Skills come from doing not reading. I did the examples (in another language) and it made all the difference in what I learned.

    A footnote for managers: TDD is the opening wedge for a set of practices known as extreme programming (XP) or agile development. Test driven development is powerful enough to work on its own for the single delevoper. If you want to realize its full value, however, you need to embrace the full set of XP practices for the whole organization.

    Comment | 
    Was this review helpful to you?
    38 of 41 people found the following review helpful
    4.0 out of 5 stars Good introduction, but light on real-world development November 28, 2003
    Format:Paperback
    If you've never done or are curious about TDD, this is a great book to carefully walk you through learning how and why to do it. After following its practices a bit, I've also found it an indispensible way to write new projects, modules, and code. However, the book doesn't address what happens when:
    - The code base is old, and doesn't have any tests or isn't designed testable. It makes it hard to do anything other than introduce integration-level tests and tweak to success.
    - You're writing UI code for a serious application. It's straightforward to solve for a dialog framework, but when you're integrating with a major windowing framework that embeds serious functionality (Avalon, in my case), there are a whole set of issues he doesn't talk about.
    - Design is part of your deliverable. I don't disagree that you can get pretty reasonble designs out of TDD & refactor. But I *do* disagree that, in practice, you get designs intended to version well, that your company is willing to support for the next decade or more. I've seen the code produced, and it just doesn't happen.

    A good introduction, nonetheless. But watch out before you put on the preacher-hat after reading it and doing the exercises -- at least try to do it in part of one large, real-world product.

    Was this review helpful to you?
    40 of 46 people found the following review helpful
    3.0 out of 5 stars A decent introduciton March 12, 2004
    Format:Paperback
    This Kent Beck title is an introduction to the world of Test-Driven Development (TDD). The book teaches the concepts of TDD by working through two complete sample projects. Along the way, Beck gives the reader valuable insight into the thought process and techniques behind successful test-driven development. When the reader has finished working through these sample projects, he should know enough about TDD to get started working on a TDD project.

    The book is divided into three sections. The first two sections are each walkthroughs of the aforementioned sample projects using TDD. The third section is a collection of notes and useful tips to try to get the most out of TDD. If you've ever read anything from Beck, then you should be familiar with his style. If you haven't, Beck is an engaging enough writer, and the text flows smoothly and is fairly pleasant to read.

    It would help to be familiar with some member of the xUnit family prior to reading this book. Beck uses Java and JUnit for the first section, but never really goes into discussing the JUnit API. Readers unfamiliar with xUnit may have no idea how to proceed with writing their own tests using one of these frameworks. True the API is simple enough that its functions may be ascertained simply by reading the code, but this is no reason not to provide explanation. The second sample project is an actual implementation of xUnit, so a bit more information may be gleaned here. Beck made the curious decision to use Python as the language of implementation for the second project, although he does provide explanation of the language's fundamentals. Finally, none of the sample projects are really complicated enough to do more than get us going on the path of TDD....

    If you are seeking a basic introduction to test-driven development, then you might enjoy this title. If you are a Java developer interested in exploring TDD more in-depth, there are better books out there. Read more ›

    Was this review helpful to you?
    55 of 69 people found the following review helpful
    2.0 out of 5 stars Poorly written...disappointing January 5, 2003
    By A Customer
    Format:Paperback
    I bought this book with high expectations. I'm a true believer in testing early and often. Basically, I think the techniques have merit, but the presentation was lacking.

    I was disappointed with the writing -- all of the little asides that were attempts at humor fell flat and were distracting. The biggest disappointment was that a chapter on how to integrate these techniques into the processes of a project, especially a large project, was ommitted.

    At one point, the book states rather flippantly something to the effect that "You'll have to come up with your own argument to convince your boss to let you spend the time writing all these tests." I think that since he's the one promoting these techniques, he should be able to come up with those arguments. Personally, I think the argument is something like this:
    - helps produce clean, modular code by forcing the designer to think about interfaces of the objects first. Coming up with good interfaces is half the battle.
    - reduces defects tremendously because automated tests are available from the beginning and are used constantly.
    - combines aspects of design and testing into the construction phase. So, the argument is that the "added" time spent writing tests saves time in the design and testing phases.

    I would have also liked to have seen a section on the dangers of stubbed out code. Since the technique causes you to stub out a lot of methods, as you go through the process and people are fallable, it warrants discussion. Sometimes they forget that some of the code is stubbed. I've seen situations where stubbed out code (ie, return true) provided the correct answer for a surprisingly long time.... Read more ›

    Was this review helpful to you?
    Most Recent Customer Reviews
    5.0 out of 5 stars Well written. Clear example.
    The writer have really strong knowledge about what he write and from what I have read. It made me realized that this book write from normal human being to normal human being like... Read more
    Published 3 months ago by Peerawat Poombua
    5.0 out of 5 stars Marvelous techniques...
    My question is, "Why did Microsoft take so long to put the toolset in their product." This is by far the best way to program and it's implecations are far reaching and this... Read more
    Published 3 months ago by Kent G
    5.0 out of 5 stars Great Book
    This is a must read for any professional developer. Even if you don't plan on practicing test-driven development, a thorough understanding of the idea is immensely useful.
    Published 8 months ago by rdawe
    5.0 out of 5 stars A must have for developers
    This book is a must have if you really want to dig into the practice of TDD. Kent Beck describes how you should begin, how to step through tests and production code and comes with... Read more
    Published 8 months ago by Michael Wagner
    4.0 out of 5 stars A great starting point
    With you want to understand what TDD is and how to start quickly this book is perfect. If you want to dive into TDD maybe you'll find other books better than this one. Read more
    Published 11 months ago by Victor Dolirio
    3.0 out of 5 stars To the point
    This is one of those books that I would have rated more highly a few years ago. TDD is not a particularly complicated concept and, these days, it's not particularly new either. Read more
    Published 15 months ago by E. RiceScherpelz
    2.0 out of 5 stars Unexpectedly underwhelmed
    Based on the many glowing reviews of this book as well as the status of the author in regards to TDD, I purchased it expecting an actionable introduction to the style. Read more
    Published 17 months ago by C. Hyde
    4.0 out of 5 stars A good starting point
    A good starting point for TDD. Kent starts with a fairly simple example, that is useful to start learning the red/green/refactor paradigm. Read more
    Published 18 months ago by mascanc
    2.0 out of 5 stars A Book About Arithmetic
    OK, I understand the need for a simple example to demonstrate the concept, but how much to I have to read about adding, multiplying, and checking equality of dollars and francs... Read more
    Published 21 months ago by Red Pill
    2.0 out of 5 stars Over-complicated, far from practical, IMHO!
    After reading Continuous Integration: Improving Software Quality and Reducing Risk, i picked up this book and was expecting a book with TDD advocate material (and/or recipes,... Read more
    Published 21 months ago by Mohammad Nafees Sharif Butt
    Search Customer Reviews
    Only search this product's reviews


    Sell a Digital Version of This Book in the Kindle Store

    If you are a publisher or author and hold the digital rights to a book, you can sell a digital version of it in our Kindle Store. Learn more

    Forums

    Topic From this Discussion
    church on cover
    Yep, have a look here: http://www.gettyimages.com/detail/RL002165/Photodisc

    Title: Chartres Cathedral at Night.
    Apr 27, 2011 by G. Stephenson |  See all 2 posts
    Have something you'd like to share about this product?
    Start a new discussion
    Topic:
    First post:
    Prompts for sign-in
     


    Search Customer Discussions
    Search all Amazon discussions


    So You'd Like to...



    Look for Similar Items by Category