So we have covered the two common elements (CI and TDD). Unfortunately we have not addressed the two major issues
and the core of this article:
1) System Level Functionality Testing (with Regression Testing)
2) System Level Scalability Testing (with Regression Testing)
Both of these must occur if we are to proclaim that we have ‘Production Quality’ in our iteration. Therefore the
role of QA is dramatically changed. In our process we dedicate one QA expert to our project using a tool like
WinRunner © from Mercury Interactive or QuickTest Professional
© also from Mercury. A ‘Functional Testing’ tool with ‘recordable scripts’ to record our interactions with the
system, and a library of regression tests are added to (almost daily) is required to provide effective Iteration
validation at the system level, with evolving Regression tests as we grow the system through our iterations.
The way System Level Functional testing is added to our life cycle is as follows:
1) A pair of developers (or a single developer if your group is not using paired programming) successfully completes a testable until of work (be it a User Story or Use Case, whichever your organization calls it).
2) The developer(s) alert the QA team (which can be one person) immediately so they can get the latest build with the new changes and test (often with the business experts) that indeed the work that was performed meets the requirements.
3) Once success is validated the QA tester can turn on the ‘scripting’ mode and record their interaction for this particular part of the system. This new ‘script’ is then added to the growing list of previous scripts (much like the developer does in ‘Test Driven Development’).
In this way the QA group is always one step behind the developers. As developers complete their work, QA is there to
verify it at the system level and build the regression script. We then on a nightly basis run our regression scripts.
Imagine the case described above was to occur, and a new regression test was created. At the end of the day, the QA
group will start running all the automated regression tests. The computer quickly simulates the keystrokes of a real
user and tests all of the functionality we have defined. It can take hours to run so imagine everyone goes home.
The next morning the first thing many people will focus on is the computer (or computers in some cases to test
concurrency) for any failures. Sometimes there will be a functional that worked just 24 hours ago, yet is now broken.
In spite of the Continuous Integration and TDD, a feature that was build in say, Iteration 5, is now not working.
Usually because the defect was caught so early, and we know that it was, it is easily fixed. This defect is cause
for a ‘red alert’ that I liken to an assembly line worker stopping the assembly line. Typically this defect is
fixed, the specific test that failed is re-run to verify and we continue the day (however we will not know perhaps
until tomorrow if THAT fix ended up breaking something else).
The key here (and one of the most important aspects to Agile) is the ‘catching of defects as early as possible’.
When we do this, it makes fixing them usually an order of magnitude faster and easier as we ‘just wrote the code’.
The problem is usually obviously and quickly solved. Compare that with defects you don’t learn about for weeks or
even months after you wrote the code.
Recently I discussed the QA issues of this article with Mr. Hans Buwalda, a well-known automated testing specialist
and his Action Based Testing (ABT) approach.
This approach, while not agile in nature, seems to be quite applicable to agile when applied to the iteration. It takes
the involvement of the QA team a step further actually. Instead of having QA one step behind development, QA is now
one or more steps ahead of the development team in a quite interesting way.
Under ABT, the QA team develops groups of high-level tests well in advance of development (but only for the features
in the iteration, not looking beyond the iteration) through discussions with and approval by business stakeholders
and subject matter experts. These groups of test cases, known as “test modules”, can be at the unit level, functional
level or even business level.
ABT tests are described as a sequence of "actions". Since ABT focuses on the automation of individual actions,
rather than test cases, full automation of these tests is usually achieved at about the same time as the software
under test in the iteration. Compared to the recording strategy described above, Action Based Testing, with its
emphasis on automating actions instead of test cases, is much less dependant on specific UI details or behaviors
of the application under test.
I am experimenting now with ABT and other firms have been successful with it. I plan on integrating it into my agile
framework if it fits well and improvements on my current techniques as described.
|