Menu: Links Great Articles Quotations Test Patterns Opinions: Effective Test Methodology Code Castle About SQA Test Cases Bug Reports |
Prolog: Trapped in the Debugging Box While testing system, middleware and business software for several years as a Quality Assurance Engineer (I also spent some time in software development and did implementation projects on customer sites), I frequently wrote down my experience about Quality Assurance in order to understand what I had been doing – and why it sometimes hadn’t worked. This is my recent version. If I again become a QA Engineer in my next life (would this be a blessing or a curse?), I will write a book eventually - provided there will still be software bugs … For QA engineers are masters in the art of negative thinking, I will start this tiny paper with describing the problems, pitfalls and contradictions of day-to-day Quality Assurance - before I will argue in favour of a comprehensive project-based approach to Quality Assurance for small to medium-size software development projects in the next chapter. I will focus on topics related to my experience and leave other cool topics (for example such as XP) to more competent and experienced authors. So let’s start with my conviction that Quality Assurance doesn’t fit well in a departmental and hierarchical organisation. In such an environment it will get harder to take care of the cross-functional and cross-departmental aspects of Quality Assurance (for example to strive for defect prevention instead of pure defect detection). Trapped within organisational and hierarchical boundaries (i.e. trapped within a box), it's tough to practice out-of-the-box thinking. QA comes on board too late and leaves too early to have impact neither on the quality of specifications, design and schedule, nor on the field introduction. Even worse a QA department may have the negative side effect of other departments reducing their quality efforts. Often QA departments are pure debugging departments: the last barrier, the very last defence between the development suspected of producing lousy and buggy software and the annoyed customers. The mission of such a debugging department may be: find as many bugs as possible within the time left till the deadline. That’s a rather narrow, defensive and disheartening approach to Quality Assurance. Lets have a closer look on some problems that a Quality Assurance department may face:
Another aspect may be less obvious, but I think it’s crucial and it's worth some discussion: it's harder for a debugging department to show some output and achievements (i.e. to justify it's existence and the existence of QA managers) than it is for other departments. How can a QA department report results? Reduce the number of bugs is a fuzzy mission – it’s difficult to measure and it doesn’t sound very challenging. Furthermore as long as there are bugs in the field, the debugging department has to defend itself. A debugging department often stands in the shadow of development and may have a lower status than other parts of the organisation. Especially if QA is embedded in a cover-your-back kind of corporate culture it will be in a very defensive position. But wait: there are ways to measure QA output and achievements (and present it to management). You may cut your tests into small pieces (called test cases), count them and measure the test coverage: the number of test cases being performed divided by the number of all test cases to be run. You may count your bugs, normalise them using something like the number of lines of code or modules, calculate the number of bugs found per day or per week, create impressive pie charts, trend charts or whatever charts. You may use sophisticated bug reporting and tracking systems, with huge databases containing thousands, millions or billions of bugs (perhaps in the future there will be some smart data mining technology available to make some sensible use of this huge amount of archaeological data). You may even enter the realm of software development by developing automated tests and test frames (by the way: who will test the code written by QA?). As you may have realised by the irony in my sentences, I don’t recommend doing so. My concern is that there will be too many negative side effects, if there's too much emphasis on methods, processes, charts and spreadsheets introduced to improve the status of the testing department (and it’s managers). For example if test coverage matters, the testers are seduced to prefer the fast and easy test cases and leave the more time-consuming and sophisticated ones for later on. 90 % test coverage may sound impressive, but the remaining 10 % may be the sophisticated and time-consuming ones, perhaps these 10 % are the only ones worth running. If the number of found bugs matters, the testers may be seduced to report as many bugs as possible. This may be great if these bugs are all relevant, but it's more probable that the fraction of less important bugs will increase and that the testers will spend less time on preanalysis. Because every reported bug will create some administrative overhead, more reported bugs will result in more administrative work for development and QA - regardless of the relevance of the reported bugs. Finally, creating and maintaining (!) automated tests may be more expensive than running them manually again and again. To distract QA’s focus from quality and to redirect it to some secondary targets is only one group of negative side effect. There are two other ones: first, there are elements such as intuition and experience in the testing business, which are difficult to organise, to measure and to manage. You may suppress these elements by a perfect organisation of your testing business. One tiny example: if you find a bug when running a test case, it will be sensible to create a link between the bug number and the test case, which caused the bug. So ... to retest bug x, you have to run test case y. That sounds smart. But lets assume you’ll find a bug without running a documented test case or by doing some additional steps when running a test. Maybe because of your intuition. Or maybe you have just found other bugs in this area and you know, that bugs tend to cluster. Now you really get into a mess! How to document this? Writing a new test case? Modify an existing one? Looking for a test who (by chance) matches these test steps, which you’ve just done? If there are already hundreds of tests, that will be time-consuming and interrupted fluid and flexible testing. There is no way to let the results of the previous tests influence the next one. You won’t have this problem, if you exactly follow your test plans. But do we need skilled and qualified testers to do so? That's my second concern: each step towards better processes and formalisms may degrade the role of the testers, they become interchangeable pieces of a debugging machine. If each tiny test step is documented ("Tick the xyz button…"), skilled testers may be replaced by well-trained monkeys. This may sound a little bit extreme, but there are two causes, which may lead you towards such an extreme situation. First - if some of the testers get the feeling, that their work is mechanised and that they are becoming superfluous and interchangeable, they will quit eventually. To reduce the costs of fluctuation and to become less vulnerable to it's consequences, it's obvious to remove more intelligence and skill from the testers and put it into the processes, e.g. by investing more effort in the documentation of test cases. As a consequence, more testers may leave … a death spiral starts to turn. Second - to do testing by unskilled testers, which were controlled by smart processes and management, will deliver some benefits – for example better control, more flexibility (i.e. shifting resources on short notice) and easy career opportunities. Depending on the corporate culture of your company, these benefits may compensate or even outweigh bad software quality. The sad thing is, that there are no basic skills required to do some kind of low-level testing, while for example an unskilled software developer, who isn’t familiar with any programming language, is unthinkable. Well ... some of these problems may not only be typical for QA departments, they may also show up in any other part of an organisation. But because of its weak, defensive and isolated position described above, QA may be more susceptible to it. But Quality Assurance is more than finding bugs during the time left till deadline following exactly some detailed test plans (“Click the “Start” button...”). It's more than defect detection (neglecting defect prevention). It can be a challenging job for highly skilled QA people, the people who do this job really matters! Quality Assurance is more about workmanship, perhaps even about art, than it is about painting-by-numbers. It’s more about communication than about making marks in spreadsheets. And it's more about project teams and collaboration than about departments. How can quality assurance be integrated and making a difference in the whole process of software development, starting at the specification and ending at customer sites? The Core Team Let's assume a new version of your successful product DoSomething should be released. Marketing has ideas about new and improved functionality, there are request from some of your major customers, the field people add ideas from projects on customer sites, support is grumbling about old bugs which after all should be fixed now, development has brilliant ideas about improving the software's infrastructure. Furthermore it's a medium-sized project, i.e. some dozen developers, testers, technical writers and support people will join it. These are the most difficult projects to manage: to apply all methods, tools and processes designed for large-scale projects would be overkill and slow down the project to stasis. Even worse you can't rely on statistics to estimate your efforts: if 30 people were estimated to work on a (sub-) project for six months, the deviation from your estimation would be very much smaller than if there were only 2 people estimated to work for 2 months. For example if somebody from the 30 left or got sick would be less disastrous than if one of the two became unavailable. On the other hand, running a project with more than 2 people requires some organisation. So there's a fine line between organisational overkill and chaos! After this emotive introduction, let's get down to business: the first steps will be
To do so I suggest establishing a core team of four people: one developer, one tester, one technical writer and somebody from support/field. These four people will act as project and team leaders as soon as more people will come on board during the project, their task is to take care of the prerequisites for each team and to coach the team members. For larger projects it may be useful to start with more than four people at the beginning, but there have to be four named team leaders from development, QA, technical writing and field/support. The basic idea of this approach is to start with a "lean" team and to avoid early overstaffing of the project. For example as long as there aren't any specifications available developers can't start coding. The QA team leader will involve more and more testers as soon as functions are implemented. The technical writers can start after the specification will have been finished. And the support and field people will become active as soon as there will be a "prototype" to be shown on fairs or to those customers, whose requests have found their way into the specification. Even more important: the six tasks mentioned above require a lot of intense communication within the core team - with respect to communication, a small team is more efficient than a huge one. Let's have a look on each of these six tasks:
Why do I emphasise that software development should be team-based? What are the benefits of this core team idea? In the first chapter I showed some scepticism about QA departments, but some sympathy about teams and team based organisations. The reason is quite simple: teams need some common goal, some common understanding "who we are". While a sport team wants to win - no matter whether it's a world or a backyard championship - , a team in business life wants to do a good and successful job, i.e. there is a natural sense for quality. The best way to kill a team is telling them: "I know this software is still rubbish, but we have to get it out until next week. We only need to assure that it didn't crash immediately". To force professionals to do unprofessional work will only create cynicism and destroy the basis of team formation. Departments are neutral with respect to quality: it depends on the (corporate) environment whether people act as professionals or as cynics. If the existence of the Quality Assurance is only justified by the buggy and error-prone software delivered by those lousy developers (which weren't granted the time to do a better job, for example to do some testing on their own), and if the Quality Assurance is only supposed to reduce the number of bugs to a less annoying level, development and QA will end up as disillusioned cynics without any team-spirit. The core team idea avoids departmental boundaries and corporate politics, it enforces communication between the main stakeholders and uses synergies. QA may raise the topic how to avoid the typical bugs from previous versions in the new release. If there is an error-prone part of the software, now it's the time to redesign it. If QA needs better traces, logs, test points and test hooks that will be a topic for the specification too. Furthermore being involved in the project from the very beginning enables QA to do one of it's main tasks: to make a statement about the quality of the product as soon as possible. Therefore QA has to create a short preliminary test plan a soon as the specification is finished. If QA starts testing late and leaves important topics untouched until two weeks before the deadline (this may happen if test coverage is the most important goal), you will run into avoidable risks. The domain of the technical writers will be to check the usability and consistency of the product. If it's difficult to describe a new function in a understandable and user-friendly way, this function won't be very usable. If it's hard to summarise the basic ideas, concepts and benefits of a product at the beginning of the manual, your product may be a bunch of functions, but not a consistent product. A good specification is also a good basis for the manual. The support and field people are the representatives of the customers. They will know the best real life war stories. Being involved in the whole development process, they also will get deep and early insight into the product itself. After the core team has finished his final work, the 4 teams will start to grow and to evolve. I will now focus on my domain: the Quality Assurance part. To Continue. Comments:From siji@yahoo.com [216.255.184.210] - 6/25/06 4:41 AM Hola me encanta el trabajo que estan haciendo y me encantaria poder participar.
From Mike (michael@luds.ko.youkay) [84.51.149.242] - 3/28/06 9:25 AM This is a hard-hitting and insightful look at issues facing persons involved with QA. I'm only starting out in the QA scene, with too-much responsibility in a small company. I imagine branding this article about would raise a few eye-brows... QA does not need to be about risk avoidance, it merely requires realistic time scales. The programmers complain of the lack of testers understanding of programming; I believe the missing QA knowledge / appreciation in other departments is more serious. In my brief experience, it's typical to spend just as long fixing the problems when they are in the field, as a realistic schedule would have removed the requirement of. From Scott Eisenreich (seisenreich@hotmail.com) [209.166.128.18] - 7/13/05 3:31 PM I am a QA Secialist with a small company. I am writing this comment on a Wed. We have a release that is going out in 2 weeks and the QA release is scheduled for Friday. I just learned TODAY! that an email has been sent to all of the development staff listing the features of the release, but both QA testers were omitted from the recipients! What is more maddening is that the lead developer was approached several days before the email went out and asked for a feature list! OK, I think I am done ranting. It is maddening because it is S.O.P. here! I am sending some of your article to the development staff in reponse. Thank you so much for puting this out there. Last Modified 1/15/06 2:25 PM | Hide Tools |