Software testing method left (translation)

Summary:

The sooner you find your code problems, their impact is smaller and spend the lower the cost to repair them. Therefore, it helps to promote the testing activities earlier in the software development life cycle - the process left on the timeline. This article explores methods left, and tell you how to go to the left in your organization.

Agile development and operations teams to the left of the melee is about much earlier in the development life cycle moving critical testing activities.

Many testing activities occur late in the cycle, it takes more time to locate the problem, more of the cost to repair them. When you wait after the implementation of the development cycle testing activities, especially your non-functional business requirements, such as safety and performance testing, so basically ingrained in your code that you actually can do is give them proper patch instead to fix them.

On the left it is faster to do this kind of recognition and prevention of defects.

Find and fix software bugs

The test strategy may be left with a little well-known chart table Kabo Si • Jones do explain below shows when the problems and defects are introduced into each stage of the software, software development, they increase the cost.

 

The graph shows the first part of the code indicates the majority of defects introduced in the coding period, may be expected.

Whether they make mistakes, misunderstanding demand, or not to consider by the special branch code blocks, the code is generated when the introduction of defects developed. When combined with a block of code, application defects has also been introduced, especially if it involves multiple team members (and modern architecture such as micro-services becomes more complex).

Let us now superimposed on the same graph, along the line, demonstrating the defect was discovered. Note that fundamentally it is the reverse of the first line:

 

This is not surprising, because typically when you start testing you find a bug, and at all the possibilities before ready without a proper infrastructure to start the test, the result will be different.

But here we can see the most when the problem was introduced in the encoding process, they are hardly to be found at that stage. It requires what cost to fix these problems?

In a different understanding of each stage of the development cost to repair the defect becomes important. This order represents the third line:

 

Now it starts to get really interesting, sharply increases when we see an unpleasant return costs after the defect was discovered. So that a problem is found 40 times their cost through system tests missed during the encoding, or find the same question 10 times during unit testing. And when you see the number of issues in a real let slip away in the deployment of costly it becomes absurd.

Escalating costs for several reasons:

  • · Spend time and effort found the problem. The more complex test cases, find out the real problem it more difficult troublemakers in which part.
  • · Challenge to reproduce defects in desktop development was introduced as a separate system, such as a database or a third-party application program interface. (In terms of organization, in these cases between the detection of defects and defect repair experience lag several weeks are common.)
  • · Impact of change is the need to fix a defect. If it is a simple problem, and that the relationship will not be great, but if you have it, you use the wrong architecture, or you build pressure on the expected or can not guarantee the security of non-extensible code in many places, it would be a bigger problem.

The reason behind the left

Now looking at the orange line on the chart below, because it explains a delayed defect detection loop in the early test basis. You can see the orange defects grow faster in the low side but also in the expensive side to increase more slowly, which gives us a very important cost reduction situation:

 

The left dependent on more mature development practices, such as one based on software testing pyramid  - created a series of reasonably well covered by the code of unit test development are, and functional testers and application program interface testers do and they can minimize reliance on late cycle test, so you just have enough labor and user interface testing to improve every thing is running. In this way, late cycle testing is to improve the functionality, not to find the problem. "Early testing, test often" is a mantra that left the team.

A number of organizations at this point stopped. But when you advance deeper into the left, into the code itself, you'll get more value. After all, this is the place where the code was introduced, so let's start looking for work when they are still in development.

This is where we benefit from static code analysis. When the cost as low as possible to find the problem, you can start looking for problems in the actual coding phase.

Before the test begins to find the problem is not only the most cost-effective, but also the time on the most effective, because it does not try to reproduce the problem in any one fail to understand or leave things develop. Ability from days or weeks to hours or minutes reduced defect repair cycle is very great help. 

Analysis of left Methods

In this way, how you left it? For the sake of brevity, left the test method into two main activities: providing development and testing best practices, leveraging virtualization services to ensure the continuity test.

Do earlier stage of development practices, such as static code analysis and unit testing to help you identify and prevent defects earlier in the process. It is important to remember to find the problem is not a goal, but to reduce the number of questions, particularly those issued to catch up. Finally, first produced fewer problems than to find more problems there are much more value - and it is much more affordable. Look at the following chart, on the left there is a lovely reducing bubble.

 

   Coding standard is equivalent software engineering standards, and they are reducing the capacity of key issues (in addition to earlier problems found outside), and get more value from your left activities. Coding standards help you avoid bad, dangerous or unsafe code through static code analysis.

For security software it is particularly important to strengthen your software. You want to create safety in your code, rather than testing it. Code standards keep you from start to build a more secure applications (such as through the design to make it safe), which is both a good idea is a demand, if you are subject to the general data protection regulations such as rules .

Next, you have to perform tests in all stages of the development process, including the late, and they continued to perform ahead. It is important for the team in terms of the development process from start to finish to take agile development practices to provide continuous feedback. Unit testing can simply be left but continued to perform advanced testing functions performed often difficult, because the external system independence. This is what you can leverage virtualization to enable local service can continue testing.

Service virtualization may allow you to simulate an independent system of limited capacity, such as host, third-party services, or may not yet be ready system. By simulating them, you can not perform a complete functional test system is available, and you can test execution has been left in desktop development.

In terms of performance testing, the service virtualization allows you to test before everything is ready, and there are not a complete laboratory every thing on your system. You can even run all kinds of "what - if" scenarios, like if wisdom cloud database fast and slow (something difficult happens in the real world) to run what? Or my server begins throw a ridiculous mistake, just 500 Error - How will it affect the performance of the system? You can as you like and push beyond your system strong, and to do this as early as possible.

Similarly, you can start your security testing earlier. Decoupled from the physical system allows you to do something even more interesting: the simulation of the system to act in ways that a demon. Instead of just poke your system and distributed denial of service attacks as pollution data, you can have a full package, sending the defective system data, or many other vulnerabilities commonly used by attackers. So you not only to test earlier, you can test to be more in-depth than a testing laboratory or production systems.

Avoid mistakes and traps

In a dangerous shift to the code phase defect inspection is accidentally put too much burden on software developers to test their body. The important thing when you look at a chart to keep in mind is the cost when you go to the right bug fixes become sharply higher, resources may be left in any of the software life cycle has the highest costs - not to mention you are they take away from the focus on the development of functionalities.

You not only want to find the earlier question, you want to reduce the amount you put into the program in the first defect.

And that there is another pitfall: If you are rewarding people find and fix the problem, and now they will find less - this is what you really want, but only if you really reduce the number of questions you being manufactured. Measure the number of defects that it might be more useful to the field to catch up with much more measured.

Improve your processes and products

By leveraging modern software testing techniques, you can have access to safe, reliable and confidential software. Testing by the left in the software development life cycle, you can find problems sooner and reduce the cost of testing, when it is low, while the number when you first put the issue of reducing the time code. Try this method to save time, money and headaches.

Guess you like

Origin www.cnblogs.com/fengye151/p/11518441.html