The Simplest Automated Unit Test Framework That Could Possibly Work

[article]
Summary:

The title of this article is a variation on a theme from Extreme Programming (XP). XP is a code-centric discipline for getting software done right, on time, within budget, while having fun along the way. Quit laughing. The XP approach is to take the best software practices to the extreme.

The title of this article is a variation on a theme from Extreme Programming (XP). XP is a code-centric discipline for getting software done right, on time, within budget, while having fun along the way. Quit laughing. The XP approach is to take the best software practices to the extreme.

For example, if code reviews are good, then code should be reviewed constantly, even as it's written, hence the XP practice of Pair Programming, where all code is written by two developers sharing a single workstation. One programmer pilots the keyboard while the other watches to catch mistakes and gives strategic guidance - then they switch roles as needed. The next day they may pair up with other folks. Likewise, if testing is good, then all tests should be automated and run many times per day.

An ever-growing suite of unit tests should be executed whenever you create or modify any function, to ensure that the system is still stable. 

About the author

Chuck Allison's picture Chuck Allison

Chuck Allison developed software for more than twenty years before becoming a professor of computer science at Utah Valley University. He is a technical editor for Better Software magazine and founding and current editor of the online journal, The C++ Source. He spent most of the 1990s as an active member of the C++ Standards Committee and is author of two C++ books, including Thinking In C++, Volume 2, with Bruce Eckel. His company, Fresh Sources, Inc., gives onsite training in C++, Python, and design patterns. His current top technical interest is the resurgence of functional programming. Whenever he finds a little down time he plays classical guitar or bikes the country roads of central Utah. Contact Chuck at chuck@freshsources.com.

AgileConnection is one of the growing communities of the TechWell network.

Featuring fresh, insightful stories, TechWell.com is the place to go for what is happening in software development and delivery.  Join the conversation now!

Upcoming Events

Sep 24
Oct 12
Oct 15
Nov 09