Software testing has never been more relevant under DevOps and that brought different approaches. Shift left and shift right are the two major ones, but they take completely different practices to validate the product. Find out which one is for you in our blog post.
As applications are getting more sophisticated, testing becomes more essential. DevOps and agile teams therefore treat testing as a prioritized process along with the actual development of the product.
There are two major methods of testing. The common goal of these is to ensure high quality to maintain customer satisfaction and serve business goals.
Don’t mistreat testing
To understand the relevance of precise testing, you must consider some of the principals of DevOps methodology. DevOps itself focuses on automating as many steps as possible including two major habits:
- Taking small steps to build a product.
- Breaking things as soon as possible.
As your product becomes larger and more complex by integrating new pieces, things break easier. QA staff need to be onboarded at the beginning of development to understand requirements and how the software is supposed to work. This way they can raise quality assurance questions and give immediate feedback on the functionality of the product to save time and money.
Validating your application makes sure your application makes a good first impression. Without testing, your team will be unable to provide quality software and users will interact with a poor application that won’t help them solve their problems.
While this importance remains the same, two major practices have emerged around testing. Shift left and shift right are the approaches quality assurance teams can go with.
What is shift left?
Shift left is the practical level of breaking things as soon as possible. A more conservative approach to testing within DevOps methodology requires testers to be treated as stakeholders of the software development.
Their goal is to validate functions of the software to enable errors as the development goes along because it’s more cost efficient to fix them earlier. This is where the term roots from: if you think about software development as a linear timeline, verifying its functionality becomes more relevant at the beginning, the left side of the timeline.
The key element of shift left is to maintain quality standards throughout development. Shift left is an accelerator of design thinking during the development by walking a mile in the user’s shoes to sort out design flaws and correct them.
Benefits of shift left
- Faster time-to-market: Finding and fixing bugs during an early stage of development decreases the chance of problems occurring as the deployment of the software approaches. This saves time in an industry where time is money.
- Better UI: Besides validating the functionality of the software and eliminating bugs, teams working with a shift left approach find flaws in user interface to provide a better user experience.
- Less downtime: Downtime is one of the key factors that hurt customer satisfaction. While there are deployment practices that eliminate the chance of users experiencing downtime, shift left reduces the chance of bugs that result outages.
What is shift right?
The most substantial difference between shift left and shift right is that the latter tests the application in the real world. The demand for shift right rose because sometimes shift left can’t predict problems that can occur in a production environment.
On the timeline of software development, teams focus a substantial part of QA to the production level, after development, in other words to the right side of the timeline.
Shift right achieves real world validation by deploying the application to a small number of users. Due to the baby steps approach of integration and deployment that we referred to earlier, users experience minor changes.
This practice allows teams to test the performance of the program in a production environment, therefore the results will be as accurate as possible.
Benefits of shift right
-
Accuracy: Shift left approach can be sufficient but unexpected errors can occur in production. Shift right enables teams to gather accurate results based on real user activity.
-
Boosts automated testing: Manual practices are still a vital part of testing but sometimes it’s time consuming to get users to try the application and give a survey on their experience. Shift right relies on gathering data about user behavior to detect problems caused by confusing UI.
-
Flexibility: Setting a time restriction to testing can turn QA into a bottleneck if workload falls out of balance on staff devoted to that. Since shift right happens post-production, other stakeholders work independent of testing.
Which approach is the best for you?
The short answer is it depends but ideally you should try to go with both approaches. If you want to save time and earn profits earlier, shift left might be the one for you. On a rare occasion this leaves room for production errors that your team must fix later. But if you want to tailor your application based on real user feedback, it might be useful to pick shift right, which is a little less time efficient way to identify bugs.
This blogpost was written by the team of dyrector.io. dyrector.io is an open-source continuous delivery & deployment platform with version management.
Find the project on GitHub.