Sunday, June 13, 2010

Principles of Testing

Principles of Testing

Reliability:
The probability that software will not cause the failure of a system for a specified time under specified conditions
Software with faults may be reliable, if the faults are in code that is rarely used
Reliability is in the view of the user
Reliability measures must take account of how the software will be used by its users.

Exhaustive Testing:
Exhaustive testing of all program paths is usually impossible
Exhaustive testing of all inputs is also impossible
If we could do exhaustive testing, most tests would be duplicates that tell us nothing
We need to select tests that are effective at finding faults


Effectiveness and Efficiency:
A test that exercises the software in ways that we know will work proves nothing
Effective tests: tests that are designed to catch specific faults
Efficient tests: tests that have the best chance of detecting faults.

How much testing is enough?
Objective coverage measures can be used:
standards may impose a level of testing
test design techniques give an objective target
But all too often, time is the limiting factor so we may have to rely on a consensus view to ensure we do at least the most important tests.

Test Exit Criteria:
Measurable criteria for test completion, for example
all tests run successfully
all faults found are fixed and re-tested
coverage target (set and) met
time (or cost) limit exceeded
Coverage items defined in terms of
requirements, conditions, business transactions
code statements, branches.

Psychology of Testing
A successful test is one that locates a fault
If finding faults is the tester’s aim:
positive motivation - finding faults is good
constructive - perceived as improving quality
testers create 'tough' tests, not easy ones
If we are effective at finding faults, and then can't find any, we can be confident the system works.

Re-testing:
If we run a test that detects a fault we can get the fault corrected
We then repeat the test to ensure the fault has been properly fixed
This is called re-testing

Regression:
When a software fault is fixed, we need to check that when
changing the faulty code, the developer has not introduced new
Faults.
    There is a 50% chance of introducing regression faults
Regression tests tell us whether new faults have been introduced
i.e. whether the system still works after a change to the code or environment has been made.
When environments are changed, we might also regression test.

Regression Testing:
"Testing to ensure a change has not caused faults in unchanged parts of the system“
Not necessarily a separate stage
Regression testing most important during maintenance activities
Regression tests are usually the first to be considered for automation.

Prioritization of Testing:
First principle: to make sure the most important tests are included in test plans
Second principle: to make sure the most important tests are executed
Most important tests are those that:
address most serious risks
cover critical features
have the best chance of detecting faults.
Criteria for prioritizing tests:
Critical
Complex
error-prone.

  Amazon Gift Card Singles Generic Design Reebok Women's EasyTone Reeinspire Walking Shoe


 crocs Beach Clog

No comments:

Post a Comment