This tutorial takes the "extreme" out of eXtreme Programming and brings the expertise acquired by the agile software development community to mainstream software developers working on all kinds of projects. The Extreme Programming community has shown the value of writing automated software unit and acceptance tests for increasing quality, reducing development cost and improving agility. Now that we know this is possible, how can we apply these learnings to more traditional software projects? And if you are an XP developer, how can you improve the way you write tests?
The XUnit family of testing frameworks (including JUnit, SUnit, NUnit, VbUnit, etc.) provide an important first step in software test automation. But test automation is much more than just knowing how to program a test in XUnit. The neophyte test-writer is faced with a deluge of questions and issues. What should I be testing? How many tests are enough? What should I focus on while writing my tests? How do I test my tests? How can I make my tests more understandable? How do my tests relate to use cases? How can I make my software easier to test? This tutorial addresses these and many other questions.
Participants will learn important strategies for developing automated unit and acceptance tests for their software and gain valuable experience in applying those strategies. Amongst the topic areas to be presented are: what tests are required, Test First vs. Test Last, key characteristics of automated test software, strategies for achieving those characteristics, test automation patterns, outside-in component specification, back-to-front test coding, the psychological stance required of a test-writer, strategies for making tests repeatable and self-checking, and how automated testing fits with UML.
The intended audience is a professional software developer who would like to learn how to test their software more effectively. Participants should be familiar with the object-oriented software development paradigm, and be fluent in one or more object-oriented languages. Familiarity with Java or C# will be useful, but not required. Familiarity with a unit testing framework such as JUnit will be very helpful as the basics of using a testing framework will not be dealt with in detail.
The tutorial will be a 40/60 mix of presentation and paper-based exercises. Each topic will be introduced in short presentations by the instructors. The participants will then have the opportunity to apply those concepts in hands-on exercises thus gaining valuable experience in a safe learning environment. Finally, the participants will have an opportunity to discuss what they learned and the advantages of various solutions.
Gerard Meszaros built his first unit testing framework in 1996 and has been doing automated unit testing ever since. Along the way, he has become an expert in refactoring of software, refactoring of tests, and design for testability. Gerard has applied automated unit and acceptance testing on projects ranging from full-on eXtreme Programming to traditional waterfall development. He has presented successful tutorials at the past three OOPSLAs, has organized workshops at four previous OOPSLAs, and has presented papers on developing and testing object-oriented software frameworks at two previous OOPSLAs, XP2001 and XP2002.
Shaun Smith has been developing object-oriented software systems since 1987. In the last few years, his focus has been on the specification and construction of systems following a "test first" approach as well as the development of frameworks to simplify testing. Shaun has participated in past OOPSLA workshops and has presented papers on framework development and testing at OOPSLA, Smalltalk Solutions, and XP2001.