Professional Documents
Culture Documents
Unit-II Testing Methodologies
Unit-II Testing Methodologies
Unit-II Testing Methodologies
- input-output relationships
This method attempts to find errors in the following categories:
EXAMPLE :
A tester, without knowledge of the internal structures of a
website, tests the web pages by using a browser; providing inputs
(clicks, keystrokes) and verifying the outputs against the expected
outcome.
Black Box Testing Advantages
• Tests are done from a user’s point of view and will help in
exposing discrepancies in the specifications.
• The tester needs to have a look inside the source code and
find out which unit/chunk of the code is behaving
inappropriately.
Advantages of White Box testing
• Testing can commence even before the GUI is ready.
oKicking the tires, checking the paint, and looking under the
hood are static testing techniques.
• Yes!
• Subjective process
- not a step by step process
• 2. Such an approach might work for a little while. If the software is still
under development, it’s very easy to get lucky and find a few bugs right
away.
2.Equivalence Partitioning
3.Data Testing
4.State Testing
• 2.don’t see what you can do to break it. Test the software by
applying the simplest and most straight forward test cases.
• 3. During test to fail, the software should be tested for the boundary
conditions on its various limits.
• It is the process of taking all possible test cases and placing them
into classes. One test value is picked from each class while testing.
Let us consider a program that separates integers into positive
or negative. And accepts any number between -5 and + 5.
The range of input integers can be split into the following partitions :
•Negative Integers: Values between -5 and -1
•Zero (neither positive nor negative)
•Positive Integers: Values between 1 and 5
•Values > 5 (Invalid)
•Values < -5 (Invalid)
-5 -1 0 1 5 >5 < -5
•Ticket values 1 to 10 are considered valid & ticket is booked. While value 11 to
99 are considered invalid for reservation and error message will appear, "Only
ten tickets may be ordered at one time."
1.Any Number greater than 10 entered in the reservation column (let say 11) is
considered invalid.
2.Any Number less than 1 that is 0 or below, then it is considered invalid.
3.Numbers 1 to 10 are considered valid
4.Any 3 Digit Number say 100 is invalid.
Data Testing
• 1. The simplest view of software is to divide its world into two parts:
the data and the program.
• 2. The data is the keyboard input, mouse clicks, disk files, printouts,
and so on.
• 3. The program is the executable flow, transitions, logic, and
computations.
• 4. The user information is checked and the data is tabulated with
the expected results.
• 2. The boundary conditions are defined as the initial and the final
data ranges of the variables declared.
• 4. The edges are the minimum and the maximum values for that
identifier.
Sub-Boundary Conditions
• 1. They’re the ones defined in the specification or evident when
using the software.
1. #include<stdio.h>
2. void main()
3. {
4. int i , fact=1, n;
5. printf(“enter the number “);
6. scanf(“%d”,&n);
7. for(i =1 ;i <=n;i++)
8. fact = fact * i;
9. printf (“the factorial of a number is ”%d”, fact);
10. }
Default, Empty, Blank, NULL, Zero and None, Invalid, Wrong,
Incorrect and Garbage Data
• 1. The final type of data testing is garbage data. This is where you test-to-
fail.
• 5. In the real word, however, there’s nothing wrong with seeing if the
software will handle whatever a user can do to it.
State Testing
• 1. The data gets tested on the numbers, words, inputs, and outputs
of the software.