Loading presentation...

Present Remotely

Send the link below via email or IM

Copy

Present to your audience

Start remote presentation

  • Invited audience members will follow you as you navigate and present
  • People invited to a presentation do not need a Prezi account
  • This link expires 10 minutes after you close the presentation
  • A maximum of 30 users can follow your presentation
  • Learn more about this feature in our knowledge base article

Do you really want to delete this prezi?

Neither you, nor the coeditors you shared it with will be able to recover it again.

DeleteCancel

Make your likes visible on Facebook?

Connect your Facebook account to Prezi and let your likes appear on your timeline.
You can change this under Settings & Account at any time.

No, thanks

Equivalence Partitioning and Boundary Value Analysis

Software Testing
by

Margaux Jousset

on 23 February 2015

Comments (0)

Please log in to add your comment.

Report abuse

Transcript of Equivalence Partitioning and Boundary Value Analysis

ENTER
Test case strategy
Reduce the total number of test cases

Process:
Taking all possible test case and places them into classes.

Equivalence Partitioning
& Boundary Value Analysis

Equivalence Partitioning and Equivalence classes
Boundary Value Analysis
Example with Decision Table Testing & ○State Transition Testing
Plan
Black Box Testing Method
The testers have
no knowledge of how the system or component is structured
inside the box. In black-box testing the tester is concentrating on
what is the result
compare to expected.
Equivalence partitioning
Boundary value analysis
Decision tables
State transition testing
QUIZ
Question:
What is Test Analysis?
Test analysis is the
process of looking at something
that can be used to derive test information. This basis for the tests is called the
test basis
.
The test basis includes whatever the tests are based on. Sometimes tests can be based on experienced user’s knowledge of the system which may not be documented.
How to identify the test conditions?
We have many condition but….
Don’t test anything(Exhaustive test).
Set the priority of test condition.
Answer: Use intelligent throught process to guide our selection called “Test Techniques”
Equivalence Partitioning
Test Design Techniques
Static technique
Dynamic technique
Static testing is the testing of the software work products manually, or with a set of tools, but they are not executed.

ex. reviewing, walk through, inspection, etc.
Static testing
This testing technique needs computer for testing.
It is done during Validation process.
The software is tested by executing it on computer.
Ex: Unit testing, integration testing, system testing.
Dynamic technique
Black Box Techniques
The test that we consider in system and software components
In this technique we inspect in software code, we consider how should it work then test case will create by follow executing method
White box testing
In practical ...
If you are testing for an input box accepting numbers from 1 to 1000
a little more example ...
Boundary value analysis
Why should we do Boundary value analysis ?
It’s widely recognized that input values at the extreme ends of input domain cause more errors in system.
Example 1
List and identify the number of equivalence classes in this case :

an alphabetic name from 3 to 30 length
alphabetic names
non-alphabetic names
names with length under 3
names from 3 to 30 length
names with length over 30
if an input condition specifies a range of values then one valid equivalence class and two invalid equivalence classes are identified
if an input condition specifies a set of values then one valid equivalence class and one invalid equivalence class are identified
if there is an infinite number of values then there is an infinite number of equivalence class
there are two types of equivalence classified : the set of valid inputs to the program and all other inputs included in the invalid equivalence class

Which one of the following statement is wrong?
For a floating variable, if the valid condition is from -1.0 to 1.0 we shall test -1.001 and 1.001
If the sum of the inputs is a number n, then we must test the program where the sum is n-1 and n+1
The method of boundary value analysis does not fit to test a file

Which one of the following statement is wrong?
Sources
http://www.softwaretestinghelp.com/
http://www.ruleworks.co.uk/testguide/BS7925-2.htm
http://stackoverflow.com/questions/1909280/equivalence-class-testing-vs-boundary-value-testing

More Example:
http://users.csc.calpoly.edu/~jdalbey/205/Resources/grocerystore.html

Conclusion
“Just because two items/values are suppose to be in the same class and behave the same, does not mean they DO behave the same.”
Then there is no use in writing in thousand test cases for all 1000 valid input numbers plus other test cases for invalid data.
Important to Use Equivalence Partitioning together with Boundary Value Analysis.
But...

Good tools to reduce the number of test cases and improve them
Imagine it accepts minimum 8 characters and maximum 12 characters
<8
8-12
>12
Test Cases 1
:
Consider password length less than 8.
Test Cases 2
:
Consider password of length exactly 8.
Test Cases 3
:
Consider password of length between 9 and 11.
Test Cases 4
:
Consider password of length exactly 12.
Test Cases 5
:
Consider password of length
more than 12.
Different test cases :
Example 2
Application where you can enter the amount of the monthly repayment or the number of years you want to take to pay it back
If you enter both, the system will make a compromise
Example :
Decision Table
Conditions Rule 1 Rule 2 Rule 3 Rule 4
Repayment amount has T T F F
been entered:
Term of loan has been T F T F
entered:
Actions/Outcomes
Process loan amount: Y Y
Process term: Y Y
Error message: Y
Result: Error Process loan Process Error
message amount term message
Y
At least 8 characters and at most 16 characters
Characters could be in alphabet or number or both
Negative numbers are not allow.
You can either use capital letter or small letter or both for alphabet
Try by yourself :
Input Password
The password contains alphabet characters.
The password contains numbers.
The password contains capital letters.
There are between 8 and 16 characters.
There are wrong characters (other than numbers or alphabet)
...
Equivalence classes
The outcome will be divided into three cases
Low security

the characters are all numbers or all alphabet letters.
Medium security

a mix between alphabet and number or capital letter and small letter, and should have at least 1 capital letter.
High security
at least 12 characters with at least 5 alphabet letters and 5 numbers, and should have at least 3 capital letters.

Why?
- What if a test failed?

- Customer Confident?

Equivalence Class
One input data class with all valid inputs.
Input data class with all values below lower limit.
Input data with value greater than 1000.
Alphabetic
Number
Capital letters
Rule : 1 2 3 4 5 6 7 8
T
T
T
F T T F T F F
T F T T F F F
T T F F F T F
Low security
Medium security
High security
Rule : 1 2 3 4 5 6 7 8
N
Y
Y
Y Y Y Y Y Y
Y N N N N N
N N N N N N
N
N
N
Error Message N N N N N N N Y
Example :
State Transition

Start
Login
Log2
Log3
Access
Blocked
********
Username
Password
LOGIN
mjousset
********
ACCESS
Blocked
Username
Password
LOGIN
mjousset
********
Username
Password
LOGIN
mjousset
********
Username
Password
LOGIN
mjousset
Start State : Start Login Login Log2 Log3 Log2 Log3
Finish State : Login Access Log2 Log3 Blocked Acc. Acc.
Input : Click
Output : L.W.
Pwd ok X Pwd X Pwd X Pwd Pwd ok P. ok
A.W. L.W. L.W. B.W. A.W. A.W.
Test Case Description Steps Expected Result
1 You pass the 1- Click the button Access
authentication 2- Enter good Window
password
Full transcript