How do QA's benefit from Test Pyramid
I would like to talk about my experience with Test Pyramid.
A quick overview of test pyramid. Test Pyramid talks about categorizing the automated tests based on the layer of application they are written in and the volume of the tests in each layers.
Example:
Unit tests: Written for each of the class in the application
Integration tests: Written for areas of application which talk to an external system like Databases
E2E tests: Typically UI tests written when the entire system is up and running.
Based on above example Test Pyramid asks teams to have more tests at Unit level lesser at Integration and minimal at E2E level.
You can read more about Test Pyramid here: https://martinfowler.com/articles/practical-test-pyramid.html.
When you first hear about test pyramid for the first time the question you might have is how does it really help?
I had a similar question. I’ll share my experience in one of my project.
The project was about building a website which would consume data from CRM and display it along with other things like login etc.
Since we were already doing TDD for most of the things we thought why not try to follow the Test Pyramid.
“Quality as a team responsibility”
When we decided to try and follow Test Pyramid the developers started adding more tests to ensure that the functionality the developed is tested ASAP rather than waiting for the UI tests.
These increased number of tests really helped improve the code quality as well as the product quality. Now even developers were talking about various scenarios that we need to cover and how can it be tested in either Unit or integration tests.
This helped us push the “Quality as a team responsibility”.
“Saves time for more exploratory testing”
With more tests at Unit and Integration level most of the builds that were deployed for QA’s to test did not have any obvious bugs resulting in time saved for doing sanity on each build and finding obvious defects late.
Any basic functionality not working was mostly detected early on and developers would fix it quickly rather than waiting for a QA or UI test to point it out.
This helped QA’s focus more on exploratory testing and finding more defects for hard to automate scenarios. It also helped us push for “Shift Left” the testing.
“Improves QA + Dev collaboration”
With developers writing more tests we(QA’s) would collaborate with developers to come-up with scenarios for a particular feature. This helped both us and the developers understand the functionality better and think of more scenarios. Our tests were more focused and improved the automation coverage.
The conversations with developers also helped us understand different ways to simulate a particular scenario while testing.
Apart from the above mentioned takeaways by following Test Pyramid we were really able to deploy quality builds early to different environments with good confidence.
I recommend teams to try to get closer to Test Pyramid as it helps in imbibing Quality Mindset for the entire team.
Comments
Post a Comment