Got more questions? Find advice on: SQL | XML | Regular Expressions | Windows
in Search
Welcome to AspAdvice Sign in | Join | Help

PressReleases

Press Releases submitted from various .NET companies.

Pragmatic Unit Testing in C# with NUnit, 2nd Ed.

Learning What to Test, and Why

Pragmatic Unit Testing in C# with NUnit

Sebastopol, CA, September 13, 2007—Pragmatic programmers use feedback to drive their development and personal processes. The most valuable feedback you can get while coding comes from unit testing. Now in it's second edition, Pragmatic Unit Testing in C# with NUnit, 2nd Ed. (Pragmatic Bookshelf, $29.95) will show you how to do software unit testing, of course, but more importantly will show you what to test.

New for the Second Edition:

  • Updated 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 will:

  • Write 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 team

Real 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.

For a review copy or more information please email pragprogpr@oreilly.com. Please include your delivery address and contact information.

Andy Hunt and Dave Thomas have more than 50 years combined experience, developing software for clients around the world. For the last 10 years they've been working together as The Pragmatic Programmers, helping clients write software and improve their development processes. They are authors of the best-selling The Pragmatic Programmer, and have written several other books. They speak at conferences globally, and are editors of IEEE Software's "Construction" column.

Additional Resources:
For more information about the book, including table of contents, index, author bios, and cover graphic, see: http://www.oreilly/catalog/0977616673
0977616673 -->

Pragmatic Unit Testing in C# with NUnit

-->Pragmatic Unit Testing in C# with NUnit, Second Edition
Andy Hunt, Dave Thomas
ISBN: 0-9776166-7-3, 239 pages, $29.95 USD, £18.50 GBP
order@oreilly.com
1-800-998-9938
1-707-827-7000



Book Price: "; } elsif ($DATA{'format'} eq "edoc") { print "PDF Price: "; } else { print ""; } **-> print qq~~; print $currency . $price . " " . $code **-> . ""; } elsif (($DATA{'format'} =~ /edoc/) && ($DATA{'series'} !~ /pocketref/)) { -->

-->


-->

About O'Reilly
O'Reilly Media spreads the knowledge of innovators through its books, online services, magazines, and conferences. Since 1978, O'Reilly Media has been a chronicler and catalyst of cutting-edge development, homing in on the technology trends that really matter and spurring their adoption by amplifying "faint signals" from the alpha geeks who are creating the future. An active participant in the technology community, the company has a long history of advocacy, meme-making, and evangelism.

About Pragmatic Bookshelf
Pragmatic Bookshelf Titles are distributed to bookstores internationally by O'Reilly Media.

The Pragmatic Bookshelf features books written by developers for developers. The titles continue the well-known Pragmatic Programmer style, and continue to garner awards and rave reviews. As development gets more and more difficult, the Pragmatic Programmers will be there with more titles and products to help programmers stay on top of their game.

# # #

O'Reilly is a registered trademark of O'Reilly Media, Inc. All other trademarks are the property of their respective owners.

Available online at http://www.oreilly.com/store/O'Reilly.com

O'Reilly Media, Inc. 1005 Gravenstein Highway North, Sebastopol, CA 95472   (707) 827-7000

Sponsor
Published Monday, September 17, 2007 4:11 PM by msmith

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Comments

 

Dave Agans said:

I found that testing right away naturally exercises the first 4 of 9 rules I eventually turned into my book Debugging. Just after coding a small section, I can more easily:

Understand the System (I just wrote it, I don't have to remember)

Make It Fail (running tests right away does this in many cases, though not the nasty ones)

Quit Thinking and Look (Immediate unit tests tend to have instrumentation as the main focus, unlike QA tests later)

Divide and Conquer (Immediate unit tests isolate a small component right away)

Of course, the nasty bugs tend to appear once small pieces start interacting, and once third-party software and/or hardware gets introduced. But immediate testing of all those things would help, to confirm assumptions that they a) work, and b) work as you expect.

Then you get real-world data and user action and network effects, and you'll still end up late at night using all 9 rules to find a particularly insidious bug. But less often than if you didn't unit test right away.

My book is focused on debugging, not software quality, techniques, or testing, so I don't really talk about this much. Maybe that should be the focus for the expanded sequel once sales start to taper off. :-)

September 18, 2007 10:37 AM

Leave a Comment

(required) 
(optional)
(required) 
Enter the code you see below

Submit