What is Defect Clustering and Pesticide Paradox

Last updated on January 31st, 2022 at 05:48 am

Rate this post

Defect clustering and pesticide paradox are two of the most important principles of software testing. Defect clustering, as the name suggests, is when most of the detected bugs and operational failures are found in a small number of modules using issue tracking tools. On the other hand, the pesticide paradox refers to the situation in which if the test cases are repeated over and over again, eventually, the same test cases will stop finding new bugs.

Defect Clustering in Detail

Defect clustering means that the distribution of bugs across the application is not uniform. Instead, it is centralized in limited sections of the application. It is true especially for large systems where developers, change, size, and complexity mistakes can affect the system’s quality and particular modules.

This concept is based on the Pareto principle which states that 80% of the bugs are caused by 20% of the modules.

This phenomenon has been observed by most of the testers which happen due to the complexity and trickiness of an area of the code. This information is often used by the test designers when risk assessments are being made for planning tests as they focus on these areas that may also be called hotspots. 


  • Testers will focus more on areas that carry more defects
  • Helps reduce the cost and time of finding defects

Pesticide Paradox in Detail

After repeating the testing process, again and again, testing improves and the defect count starts to drop. The majority of the bugs will be fixed and the ‘hotspot’ area will be cleaned up. The developers will take extra care of the areas where the defects were clustered and might not look into other areas.

Hence, executing the same test cases on repeat won’t help find more bugs. Revising test cases and writing new and different tests in different areas of the software is crucial to find more defects.

How to Prevent Pesticide Paradox:

  • Create new test cases to exercise different parts of the application
  • Prepare new test cases and add them to the existing set of test cases

These two methods of prevention can help ensure the detection of more potential bugs, by using issue tracking tools, in areas where testing was not focused before or in those areas where developers were not extra cautious to look for potential defects.  

Also, the second method of prevention enables testers to find new potential defects from the new area while also allowing them to focus on the defect cluster which was identified earlier. By following this method, the number of test cases will be so large that it will consume a lot of time and will be very costly. To overcome these challenges, testers must prioritize the test cases and exclude those that are less important. Doing this will ensure that there are no useless test cases and all the test cases covering important areas of the software will be retained.


Identifying defect clusters in the initial iterations of testing is useful but assuming that all the defects are only in the cluster even in later iterations too is ignorance.

Test cases need to be reviewed regularly even if the created test cases a high coverage and rate of finding defects.

Leave a Reply

Your email address will not be published. Required fields are marked *