Jump to ratings and reviews
Rate this book

PRAGMATIC UNIT TESTING IN C# W/NUNIT,2/ED: THE PRAGMATIC STARTER KIT-VOL-II

Rate this book
New for the Second for NUnit 2.4 (C#, .NET 2.0, Visual Studio 2005, and Mono) More NUnit assert methods New String and Collection assertion support Better support for multiple-platform development (Mono and .NET) Higher-level setup and teardown fixtures ...and more!Without good tests in place, coding can become a frustrating game of 'whack-a-mole.' That's the carnival game where the player strikes at a mechanical mole; it retreats and another mole pops up on the opposite side of the field. The moles pop up and down so fast that you end up flailing your mallet helplessly as the moles continue to pop up where you least expect them. You need automated testing and regression testing to keep the moles from popping up. You don't test a bridge by driving a single car over it right down the middle lane on a clear, calm day. Yet many programmers approach testing that same way?one pass right down the middle and they call it 'tested.' Pragmatic programmers can do better than that! With this book, you better code, faster Discover the best hiding places where C# bugs breed Learn how to think of all the things that could go wrong Test pieces of code without using the whole .NET project Use NUnit to simplify your C# test code Test effectively with the whole teamReal software unit testing will make your life easier. It will make your software design and architecture better and drastically reduce the amount of time you spend debugging you .NET code. About the Authors Andy Hunt and Dave Thomas are coauthors of the original Pragmatic Programmer, several books since, and founded the Pragmatic Bookshelf. Prabhakar Chaganti

250 pages, Paperback

First published January 1, 2004

6 people are currently reading
189 people want to read

About the author

Andy Hunt

23 books405 followers
see also Andrew Hunt

Andy Hunt is a programmer turned consultant, author and publisher.
He co-authored the best-selling book "The Pragmatic Programmer",
was one of the 17 founders of the Agile Alliance, and co-founded
the Pragmatic Bookshelf, publishing award-winning and critically
acclaimed books for software developers.

Andy started writing software professionally in early 80's across
diverse industries such as telecommunications, banking, financial
services, utilities, medical imaging, graphic arts, and of course,
the now-ubiquitous web.

Source: Amazon.com

Ratings & Reviews

What do you think?
Rate this book

Friends & Following

Create a free account to discover what your friends think of this book!

Community Reviews

5 stars
26 (16%)
4 stars
67 (43%)
3 stars
53 (34%)
2 stars
7 (4%)
1 star
2 (1%)
Displaying 1 - 6 of 6 reviews
Profile Image for Mohammad Elsheimy.
46 reviews8 followers
Read
December 24, 2021
Started reading the book earlier and could not even pass through a couple of chapters. The information in the book is outdated, configuration and setup is deprecated. I would not give it a rating as it was very helpful at the time of its writing, however, now, no way! For me, I switched to "The Art of Unit Testing, 2nd Edition" and it's super! I highly recommend that you switch too.
Profile Image for Jesper.
20 reviews
December 15, 2011
I didn't even know what unit testing was before I picked up this book.

At not much more than 150 pages, this book is small. It's part of a series called "The Pragmatic Starter Kit". That series is part of a larger series of books that started coming out after "The Pragmatic Programmer" was published.

I LOVE what unit testing promises. To be able to incrementally build code that is known to work AND be instantly alerted when you break it is very, very cool.

The book goes over the NUnit framework, walks you through the initial setup, and shows some unit tests in an example project.

After reading this book, I have no idea how to write a useful unit test.

My guess is that it must take a lot of experience to do it well and might even be a bit of an artform.

The book talks about testing principles, fence post errors, mock objects and edge case scenarios. Things like: testing for null or handing a pre-sorted algorithm to a sort algorithm.

None of that really helps me.

Because of this book, I understand why it's a good idea to write unit tests and what the common reasons are that developers give for not writing them.

Even though I scratch my head a lot when I try to write a unit test, I've started using them. I open the book up, look through the examples, and skim the chapters looking for an appropriate example. Most of the time I feel like I'm missing something.

I'm wondering if I need to read a different book, one that has more concrete examples or find an open source project that uses unit tests.
Profile Image for Andrii.
30 reviews
September 28, 2015
Ожидал большего и пожалел потраченного времени.
Больше напоминает какую-то бакалаврскую работу, когда студент начал работу за неделю до даты сдачи, залез в поисковик и начал копировать все, что попадает в категории юнит-тесты, nunit и C#.
Если Вы еще ни разу не сталкивались с понятием Юнит-тестов и желаете прочитать что-то обзорное, можно начать с этой книги.
Действительно полезными могут быть акронимы, которые описаны в книге - FIRST, Right-BICEP, CORRECT.
6 reviews
August 3, 2009
I was looking for something that would help me more in terms of validation testing rather than unit testing so my fault for expecting more out of the book than the title said.
Profile Image for Eric Olsson.
5 reviews
July 15, 2010
Great introduction to unit testing. This is one that I'll definitely be having to re-read since I'm sure I didn't pick up everything the first time.
Profile Image for William.
Author 1 book42 followers
May 5, 2013
after reading this book, I'm convinced unit testing is essential in all but the most trivial code projects.
Displaying 1 - 6 of 6 reviews

Can't find what you're looking for?

Get help and learn more about the design.