Contact Me

Test Patterns

 Test patterns refer to specific arrangements of test inputs and expected outputs used to evaluate the performance and functionality of a system or device under test. They provide a structured approach to testing, which helps ensure that the system is thoroughly tested and that all relevant scenarios are covered.

 The most common test patterns for software development are:

Mocks

 Everything that we use as a copy of a real element that behaves exactly like the original object from the point of view of the unit under test.

Stubs

 It is a small piece of code that mimics the behavior of an external component or system. A stub is used as a replacement for a component that is not available or not yet implemented.

Spies

 It mimics the behavior of a component, records information about the calls that are made to it. A spy is used to monitor the interactions between the component or system under test and the external components or systems that it depends on.