軟件測試基礎:軟件測試的公理和術語

以下內容大部分來自 ron-patton-software-testing第3章
重點:
• Why software can never be perfect
• Why software testing isn’t just a technical problem

Testing Axioms

It’s Impossible to Test a Program Completely

原因:
• The number of possible inputs is very large.
• The number of possible outputs is very large.
• The number of paths through the software is very large.
• The software specification is subjective. You might say that a bug is in the eye of the beholder

Software Testing Is a Risk-Based Exercise

If you decide not to test every possible test scenario, you’ve chosen to take on risk. 如果你決定不測試每一個可能的測試場景,你已經選擇承擔風險。

The goal is to hit that optimal amount of testing so that you don’t test too much or too little. 目標是達到最佳的測試量,這樣你就不會測試太多或太少。

Testing Can’t Show That Bugs Don’t Exist

The More Bugs You Find, the More Bugs There Are

原因:
Programmers have bad days. Like all of us, programmers can have off days. Code written one day may be perfect; code written another may be sloppy. One bug can be a tell-tale sign that there are more nearby.
Programmers often make the same mistake. Everyone has habits. A programmer who is prone to a certain error will often repeat it.
Some bugs are really just the tip of the iceberg. Very often the software’s design or architecture has a fundamental problem. A tester will find several bugs that at first may seem unrelated but eventually are discovered to have one primary serious cause.

The Pesticide Paradox

the phenomenon that the more you test software, the more immune it becomes to your tests.

To overcome the pesticide paradox, software testers must continually write new and different tests to exercise different parts of the program and find more bugs.

Not All the Bugs You Find Will Be Fixed

You and your team will need to make trade-offs,risk-based decisions for each and every bug, deciding which ones will be fixed and which ones won’t. 您和您的團隊將需要爲每個錯誤做出權衡,基於風險的決策,確定哪些錯誤將得到解決,哪些錯誤將不會得到解決。

不修復bug的可能理由

There’s not enough time. In every project there are always too many software features, too few people to code and test them, and not enough room left in the schedule to finish. If you’re working on a tax preparation program, April 15 isn’t going to move—you must have your software ready in time.

It’s really not a bug. Maybe you’ve heard the phrase, “It’s not a bug, it’s a feature!” It’s not uncommon for misunderstandings, test errors, or spec changes to result in would-be bugs being dismissed as features.

It’s too risky to fix. Unfortunately, this is all too often true. Software is fragile, intertwined, and sometimes like spaghetti. (軟件脆弱,糾纏在一起,有時像意大利麪條一樣。)You might make a bug fix that causes other bugs to appear. Under the pressure to release a product under a tight schedule, it might be too risky to change the software. It may be better to leave in the known bug to avoid the risk of creating new, unknown ones.

It’s just not worth it. Bugs that would occur infrequently or bugs that appear in little-used features may be dismissed. Bugs that have work-arounds, ways that a user can prevent or avoid the bug, are often not fixed. It all comes down to a business decision based on risk

When a Bug’s a Bug Is Difficult to Say

被發現的bug才叫bug
a bug is a bug only if it’s observed

Product Specifications Are Never Final

As a software tester, you must assume that the spec will change.

Software Testers Aren’t the Most Popular Members of a Project Team

The goal of a software tester is to find bugs, find them as early as possible, and make sure they get fixed

和隊友和平相處的建議

Find bugs early. That’s your job, of course, but work hard at doing this. It’s much less of an impact and much more appreciated if you find a serious bug three months before, rather than one day before, a product’s scheduled release.
Temper your enthusiasm. Okay, you really love your job. You get really excited when you find a terrible bug. But, if you bounce into a programmer’s cubicle with a huge grin on your face and tell her that you just found the nastiest bug of your career and it’s in her code, she won’t be happy.
Don’t always report bad news. If you find a piece of code surprisingly bug free, tell the world. Pop into a programmer’s cubicle occasionally just to chat. If all you ever do is report bad news, people will see you coming and will run and hide.

Software Testing Is a Disciplined Technical Profession 軟件測試是一個嚴格的技術專業

Software Testing Terms and Definitions

Precision and Accuracy

Verification and Validation

Quality and Reliability

Testing and Quality Assurance (QA)

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章