Loading

Error Seeding


What is Error Seeding ?

Error Seeding is the process of deliberately introducing errors within a program to check whether the test cases are able to capture the seeded errors. This technique aims to detect errors in order to find out the ratio between the actual and artificial errors.

Artificial faults are the unknown faults and actual faults are the injected faults, hence test cases are used to check presence of such faults. The reason for error seeding is that both testers and developers get a chance to challenge their respective responsibilities.

It is basically an estimation technique which helps to figure out the presence of real errors on the basis of the number of seeded errors found.

Error Seeding

The pictorial depiction depicts the actual procedure of error seeding wherein a certain portion of code is injected with some mutants or fake errors which when executed by the test cases bring the actual scenario into the limelight.

Issues with error Seeding :

When errors are injected into a program, it is important to make sure that the seeded errors are removed. Now while planning to seed the errors, few questions do arise - what type of errors must be seeded, have the errors been removed that were added, how much extra effort is needed to address the issue?

Facts regarding Error Seeding :

  • The source code is tested itself in error seeding technique
  • Test cases that are used to detect errors are used for testing
  • Error seeding technique requires lesser time and is also an economical method
  • It is considered an efficient approach for bigger issues

Error Seeding vs Mutation Testing :

The reason for comparison of error seeding technique with mutation testing is that, both techniques intend to introduce some defects with the aim to check the presence of defects or whether our program/ test case is sturdy enough to capture that defect.

But difference lies in the fact that in mutation testing, some mutants are introduced in the program, that is, some values are modified. Following image shows mutation testing.

Original Program Mutant Program
If (x>y)
Print "Hello"
Else
Print "Hi"
If(x)
Print "Hello"
Else
Print "Hi"

Basically, mutation testing is in a way a systematic approach to error seeding.

Conclusion :

The general idea behind error seeding technique is that an error that is seeded by the programmer helps to analyse the ability of a tester to find an error. This way a lot of unknown facts come under our notice.

It is an investigative approach which aims to scan the source code of a product in the light of various bugs.