Writing time: 1 hour.
You probably have seen testing pyramid as blog post or even worse, at paid testing conference. In this post I will explain why every testing pyramid that you have seen is wrong. I will give you real testing pyramid.
Proposed testing pyramids are wrong for three reasons:
- they only depict automatic checking
- they are triangles, not pyramids
- they only depict a few testing techniques
Pyramid is 3D object while triangle is 2D object. Following picture shows pyramid in 2D perspective and a triangle.
This is pyramid with all possible sides:
Wait, what, we have four triangles and a rectangle!? So what you have seen at various blog post and paid conferences was a triangle. Moving on.
Automatic checking pyramid
This was presented as testing pyramid:
You probably got impression that testing is:
- automatic UI checking (aka selenium)
- automatic integration testing (aka rest api testing)
- unit automatic checking (aka this is hard and I will do with item #1 or item #2)
Demystified testing pyramid in 2D
So we have FIVE dimensions of testing. Wait, this rings a bell. Searching through BBST slides, yes, here it is, Heuristic Test Strategy Model has FIVE elements. I propose mapping of Heuristic Test Strategy Model [by James Bach] to pyramid:
And testing triangle just scratched part of test techniques. Note that I put test techniques as pyramid base. When you see a real pyramid, its base is hidden (unknown), just as the skilled testing usually is.
Be noted, if I will see testing triangle as part of any future testing talk at te software testing conference that I will pay for, I will object, (in the most polite manner possible) live at the presentation, and to the conference organizers that allowed this picture to be part of their conference lineup. Please, do the same as me.