Chapter 2
Chapter 2
Types of Reviews
There are three general classes of reviews: Informal / peer reviews/technical Semiformal / walk-through Formal /inspections.
Peer Review
Simply giving a document to a colleague and asking them to look at it closely which will identify defects we might never find on our own.
Walkthrough
A review of requirements, designs or code
characterized by the author of the material under review guiding the progression of the review.
A 'walkthrough' is an informal meeting for evaluation
or informational purposes. Little or no preparation is usually required. These are led by the author of the document.
Inspection
An inspection is more formalized than a
'walkthrough', typically with 3-8 people including a moderator, reader, and a recorder to take notes.
The subject of the inspection is typically a document
such as a requirements specification or a test plan, and the purpose is to find problems and see what's missing, not to fix anything.
reading thru the document; most problems will be found during this preparation. The result of the inspection meeting should be a written report.
Thorough preparation for inspections is difficult,
painstaking work, but is one of the most cost effective methods of ensuring quality.
Moderator:
The moderator makes sure that the review follows its
Recorder:
The recorder is an often overlooked, but essential part
Presenter: The presenter is often the author of the artifact under review. The presenter explains the artifact and any background information needed to understand it . Reviewer: Reviewers raise issues. Its important to keep focused on this. Its important to keep focused on this, and not get drawn into side discussions of how to address the issue.
knows the set of inputs & expected outputs & is unaware of how those inputs are transformed into outputs by the software.
It attempts to find: Incorrect or missing functions Interface errors Errors in data structures or external database access Performance errors Initialization and termination errors
the program by testing transaction flows, input validation and functional completeness. Which is known as Black box Testing. There are three important techniques, which are significantly important to derive minimum test cases and input data for the same.
Equivalence Partitioning
An equivalence class data is a subset of a larger class. This data is used for technically equivalence
partitioning rather than undertaking exhaustive testing of each value in the larger set of data.
For example, a program which edits credit limits within a given range ($10,000-$15,000) would have three equivalence classes:
Less than $10,000 (invalid) Between $10,000 and $15,000 (valid) Greater than $15,000 (invalid)
equivalence sets
If input is a 5-digit integer between 10,000 and
then one valid and two invalid equivalence classes are defined.
If an input condition is Boolean, then one valid
Boris Beizer
A technique that consists of developing test cases and data that focus on the input and output boundaries of a given function. In same credit limit example, boundary analysis would test:
Low boundary plus or minus one ($9,999 and
$10,001)
On the boundary ($10,000 and $15,000)
Upper boundary plus or minus one ($14,999
and $15,001)
input domain BVA leads to selection of test cases that exercise boundary values BVA complements equivalence partitioning. Rather than select any element in an equivalence class, select those at the ''edge' of the class Examples: For a range of values bounded by a and b, test (a-1), a, (a+1), (b-1), b, (b+1) If input conditions specify a number of values n, test with (n1), n and (n+1) input values Apply 1 and 2 to output conditions (e.g., generate table of minimum and maximum size)
1 to 30 years
Minimum 10
Term:
Repayment:
Interest rate: Total paid back:
Account number
First character: valid: non-zero invalid: zero Number of digits: invalid
Valid Partitions 6 digits 1st non-zero Invalid Partitions < 6 digits > 6 digits 1st digit = 0 non-digit
6
valid
7
invalid
Invalid Boundaries 5 digits 7 digits 0 digits
Error Guessing
Based on the theory that test cases can be
developed based upon the intuition and experience of the Test Engineer
tested, to test every possible input stream would take nearly forever . Without clear and concise specifications, test cases are hard to design . There may be unnecessary repetition of test inputs if the tester is not informed of test cases the programmer has already tried . May leave many program paths untested .
Testing based on an analysis of internal workings and structure of a piece of software. Synonyms for White Box Testing: Glass Box testing Structural testing Clear Box testing Open Box Testing
functionality of the code by examining and testing the program code that realizes the external functionality.
It is a methodology to design the test cases that uses
Statement Coverage:
A test case design technique for a component in which test cases are designed to execute statements. Design test cases so that every statement in a program is executed at least once.
By choosing the test set {(x=3, y=3), (x=4, y=3), (x=3, y=4)} all statements are executed at least once.
Branch Coverage:
A test case design technique for a component in which test cases are designed to execute branch outcomes.
Condition Coverage:
Condition: A Boolean expression containing no
Boolean operators. For instance, A<B is a condition but A and B is not. Test cases are designed such that: Each component of a composite conditional expression given both true and false values.
Example
Consider the conditional expression ((c1.and.c2).or.c3): Each of c1, c2 and c3 are exercised at least once i.e.
given true and false values. Condition testing stronger than branch testing. Branch testing stronger than statement coverage testing.
Cyclomatic complexity
It simply measures the amount of decision logic in the
program module. McCabe's complexity used to define minimum number of test cases required for a module. Cyclomatic complexity is defined as
CC = E - N + P
Where
E = the number of edges of the graph N = the number of nodes of the graph P = the number of connected component
Example
IF A=354 Then IF B>C Then A=B Else A=C EndIF
Endif Print A
Cyclomatic Complexity
1-10 without much risk 11-20 moderate risk 21-50 program Greater than 50 (very high risk)
the different architectural usage of the system. This is just a combination of both Black box & White box testing. Tester should have the knowledge of both the internals and externals of the function.
Assignment Compare black box Testing and White box Testing?????? Write a note about Scrum model, Extreme programming, W model What is mutation Testing and Random Testing?