读书笔记1

来源:互联网 发布:python命令行是什么 编辑:程序博客网 时间:2024/06/06 14:59

Sams.Software.Testing.2nd.Edition.Jul.2005

 

I-3. Software Testing Terms and Definitions

 

Precision and Accuracy (精确度和正确度)

As a software tester, it's important to know that the difference between precision and accuracy. Suppose that you're testing a calculator. Should you test that the answers it returns are precise or accurate? Both? If the project schedule forced you to make a risk-based decision to focus on only one of these, which one would you choose?

 

Whether the software you test needs to be precise or accurate depends much on what the product is and ultimately what the development team is aiming at (excuse the pun). A software calculator likely demands that both are achieved  a right answer is a right answer. But, it may be decided that calculations will only be accurate and precise to the fifth decimal place. After that,  the precision can vary, As long as the testers are aware of that specification, they can tailor their testing to confirm it.

 

Verification and Validation (验证和确认)

Verification and validation are often used interchangeably but have difference definitions. These differences are important to software testing.

 

Verification is the process confirming that something software meets its specification. Validation is the process confirming that it meets the user's requirements. These may sound very similar, but an expanation of the Hubble space telescope(哈勃空间望远镜) problems will help show the difference.

 

In April 1990, the Hubble space telescope was launched into orbit around the Earth. As a reflective telescope, Hubble uses a large mirror as its primary means to magnify the objects it's aiming at. The construction of the mirror was a huge undertaking requiring extreme precision and accuracy. Testing of the mirror was difficult since the telescope was designed for use in space and couldn't be positioned or even viewed through while it was still on Earth. For this reason, the only means to test it was to carefully measure all its attributes and compare the measurements with what was specified. This testing was performed and Hubble was declared fit for launch.

 

Unfortunately, soon after it was put into operation, the images it returned were found to be out of focus. An investigation discovered that the mirror was improperly manufactured. The mirror was ground according to the specification, but the specification was wrong. The mirror was extremely precise, but it wasn't accurate. Testing had confirmed that the mirror met the spec verification but it didn't confirm that it met the original requirement validation.

 

In 1993, a space shuttle mission repaired the Hubble telescope by installing a "corrective lens" to refocus the image generated by the improperly manufactured mirror.

 

Althouth this is not a software example, verification and validation apply equally well to software testing. Never assume that the specification is correct. If you verify the spec and validate the final product, you help avoid problems such as the one that hit the Hubble telescope.

 

Quality and Reliability (质量和可靠性)

Merriam-Webster's Collegiate Dictionary(韦氏学院词典) defines quality as "a degree of excellence" or "superiority in kind." If a software product is of high quality, it will meet the customer's needs. The customer will feel that the product is excellent and superior to his other choices.

 

Software testers often fall into the trap of believing that quality and reliability are the same thing. They feel that if they can test a program until it's stable, dependable, and reliable, they are assuring a high-quality product. Unfortunately, that isn't necessarily true. Reliability is just one aspect of quality.

 

A software user's idea  of quality may include the breadth of features, the ability of the product to run on his old PC, the software company's phone support availability, and, often, the price of the product. Reliability, or how often the product crashes or trashes his data, may be important, but not always.

 

To ensure that a program is of high quality and is reliable, a software tester must both verify and validate throughout the product development process.

 

Testing and Quality Assurance(QA) (测试和品质保证)

The last pair of definitions is testing and quality assurance (sometimes shortened to QA). These two terms are the ones most often used to describe either the group or the process that's verifying and validating the software. In "Software Quality Assurance," you'll learn more about software quality assurance, but for now, consider these definitions:

  • the goal of a software tester is to find bugs, find them as early as possible, and make sure they get fixed.
  • A software quality assurance persion's main responsibility is to create and enforce standards and methods to improve the development process and to prevent bugs from ever occurring.

of course, there is overlap. Some testers will do a few QA tasks and some QA-ers will perform a bit of testing. The two jobs and their tasks are intertwined. What's important is that you know what your primary job responsibilities are and communicate that information to the rest of the development team. Confusion among the team members about who's testing and who's not has caused lots of process pain in many projects.