Software Test Estimation: An Expert View
As mentioned in Test Management Phases Tutorial, Test estimation is a management activity which approximates how long a Task would take to complete. Estimating effort for the test is one of the major and important tasks in Test Management.
Why test estimation?
Two questions you can expect from your clients when discussing potential test engagements are
For small projects, these questions are relatively easy to answer. But for the big project like testing ABC Bank website, you must think hard to answer those questions.
What to Estimate?
· Resources: Resources are required to carry out any project tasks. They can be people, equipment, facilities, funding, or anything else capable of definition required for the completion of a project activity.
· Times : Time is the most valuable resource in a project. Every project has a deadline to delivery.
· Human Skills : Human skills mean the knowledge and the experience of the Team members. They affect to your estimation. For example, a team, whose members have low testing skills, will take more time to finish the project than the one which has high testing skills.
· Cost: Cost is the project budget. Generally speaking, it means how much money it takes to finish the project.
How to estimate ?
Following are the popular test estimation technique-
Following is the 4 Step process to arrive at an estimate
You will learn how to combine these techniques to find the estimate for ABC Bankcase study.
Step1) Divide the whole project task into subtasks
Task is a piece of work that has been given to someone. To do this, you can use the Work Breakdown Structure technique.
In this technique, a complex project is divided into modules. The modules are divided into sub-modules. Each sub-module is further divided into functionality. It means divide the whole project task into the smallest tasks.
Use the Work Break Down structure to break out the ABC Bank project into 5 smaller tasks-
After that, you can break out each task to the sub-task. The purpose of this activity is create task as detailed as possible.
Task
|
Sub task
|
Analyze software requirement specification
|
Investigate the soft requirement
specs |
Interview with the developer
& other stakeholders to know more about the website | |
Create the Test Specification
|
Design test scenarios
|
Create test cases
| |
Review and revise test cases
| |
Execute the test cases
|
Build up the test environment
|
Execute the test cases
| |
Review test execution results
| |
Report the defects
| |
Create the defect reports
| |
Report the defects
|
Step 2) Allocate each task to team member
In this step, each task is assigned to the appropriate member in the project team.
You can assigned task as follows
You can assigned task as follows
Task
|
Members
|
Analyze software requirement specification
|
All the members
|
Create the test specification
|
Tester/Test Analyst
|
Build up the test environment
|
Test Administrator
|
Execute the test cases
|
Tester, Test Administrator
|
Report defects
|
Tester
|
Step 3) Estimate the effort for tasks
There are 2 techniques which you can apply to estimate the effort for tasks
1. Functional Point Method
2. Three Point Estimation
Method 1) Function Point Method
In this method, the Test Manager estimates Size, Duration and Cost for the tasks
Step A) Estimate size for the task
In Step 1, you already have broken the whole project task into small task by using WBS method. Now you estimate the size of those tasks. Let’s practice with a particular task “Create the test specification”
The size of this task depends on the functional size of the system under test. The functional size reflects the amount of functionality that is relevant to the user. The more number of functionality, the more complex system is.
Prior to start actual estimating tasks effort, functional points are divided into three groups like Complex, Medium Simple as following:
Based on the complex of software functions, the Test Manger has to give weightage to each functional point. For example
Group
|
Weightage
|
Complex
|
5
|
Medium
|
3
|
Simple
|
1
|
Let’s take a simple example exercise to get clearer:
The software engineer have already described the software modules in detail, can you determine the complexity of website’s features by giving the weightage for each modules?
More complex the function point, more is the effort to test it is. The website is divided into 12 function points, you can determine the complexity of each function points as follows-
No.
|
Module Name
|
Applicable
Roles
|
Description
|
Weightage
|
1.
|
Balance Enquiry
|
Manager
Customer
|
Customer:A customer can have multiple
bank accounts. He can view balance of his accounts only
Manager: A manager can view balance
of all the customers who come under his supervision |
3
|
2.
|
Fund Transfer
|
Manager
Customer
|
Customer:A customer can have transfer
funds from his “own” account to any destination account.
Manager: A manager can transfer funds
from any source bank account to destination account |
5
|
3.
|
Mini Statement
|
Manager
Customer
|
A Mini statement will show last 5
transactions of an account
Customer:A customer can see mini-
statement of only his “own” accounts
Manager: A manager can see mini-
statement of any account |
3
|
4.
|
Customized
Statement |
Manager
Customer
|
A customized statement allows you to
filter and display transactions in an account based on date, transaction value
Customer:A customer can see
Customized- statement of only his “own” accounts
Manager: A manager can see
Customized -statement of any account |
5
|
5.
|
Change Password
|
Manager
Customer
|
Customer:A customer can change
password of only his account.
Manager: A manager can change
password of only his account. He cannot change passwords of his customers |
1
|
6.
|
New Customer
|
Manager
|
Manager: A manager can add a new
customer.
Manager: A manager can edit details
like address, email, telephone of a customer. |
3
|
7.
|
New Account
|
Manager
|
Currently system provides 2 types
of accounts
· Saving
· Current
A customer can have multiple saving
accounts (one in his name, other in a joint name etc).
He can have multiple current accounts
for different companies he owns.
Or he can have a multiple current
and saving accounts.
Manager: A manager can add a new
account for an existing customer. |
5
|
8.
|
Edit Account
|
Manager
|
Manager: A manager can add an edit
account details for an existing account |
1
|
9.
|
Delete Account
|
Manager
|
Manager: A manager can add a delete
an account for a customer. |
1
|
10.
|
Delete Customer
|
Manager
|
A customer can be deleted only if
he/she has no active current or saving accounts
Manager: A manager can delete a
customer. |
1
|
11.
|
Deposit
|
Manager
|
Manager: A manager can deposit money
into any account. Usually done when cash is deposited at a bank branch. |
3
|
12.
|
Withdrawal
|
Manager
|
Manager: A manager can withdraw money
from any account. Usually done when cash is withdrawn at a bank branch. |
3
|
STEP B) Estimate duration for the task
After classifying the complexity of the function points, you have to estimate the duration to test them. Duration means how much time needs to finish the task.
· Total Effort: The effort to completely test all the functions of the website
· Total Function Points: Total modules of the website
· Estimate defined per Function Points: The average effort to complete one function points. This value depends on the productivity of the member who will take in charge this task.
Suppose your project team has estimated defined per Function Points of 5 hours/points. You can estimate the total effort to test all the features of website ABC Bank as follows:
Weightage
|
# of Function Points
|
Total
| |
Complex
|
5
|
3
|
15
|
Medium
|
3
|
5
|
15
|
Simple
|
1
|
4
|
4
|
Function Total Points
|
34
| ||
Estimate define per point
|
5
| ||
Total Estimated Effort (Person Hours)
|
170
|
So the total effort to complete the task “Create the test specification” of ABC Bank is around 170 man-hours
Once you understand the effort that is required, you can assign resources to determine how long the task will take (duration), and then you can estimate labor and non-labor costs.
Above example also shows the importance of the member in your team. If you have talented and experienced members, you can finish the assigned task in the small time, and your project will finish at the deadline or sooner.
STEP C) Estimate the cost for the tasks
This step helps you to answer the last question of customer “How much does it cost?”
Suppose, on average your team salary is $5 per hour. The time required for “Create Test Specs” task is 170 hours. Accordingly the cost for the task is 5*170= $850. Now you can calculate budget for other activities in WBS and arrive at overall budget for the project.
As a project manager, you have to decide how to get the most return for your company’s investment. The more accurate your estimate of project cost is, the better able you will be to manage your project’s budget.
METHOD 2) Three Point Estimation
Three-Point estimation is one of the techniques that could be used to estimate a task. The simplicity of the Three-point estimation makes it a very useful tool for a Project Manager that who wants to estimate.
In three-point estimation, three values are produced initially for every task based on prior experience or best-guesses as follows
When estimating a task, the Test Manager needs to provide three values, as specified above. The three values identified, estimate what happens in an optimal state, what is the most likely, or what we think it would be theworst case scenario.
Let’s see how to use the above three values in the following example
For the task “Create the test specification”, can you estimate the test effort? Remember that you have to cover all the modules of the ABC Bank website as done in Function Point Method
You can estimate as following
· The best case to complete this task is 120man-hours (around 15 days). In this case, you have a talented team, they can finish the task in smallest time.
· The most likely case to complete this task is 170man-hours (around 21 days). This is a normal case, you have enough resource and ability to complete the task
· The worst case to complete this task is 200man-hours (around 25 days). You need to perform much more work because your team members are not experienced.
Now, assign the value to each parameter as below
The effort to complete the task can be calculated using double-triangular distribution formula as follows-
In the above formula, parameter E is known as Weighted Average. It is the estimation of the task “Create the test specification”.
But your boss may ask you
In the above estimation, you just determine a possible and not a certain value, we must know about the probability that the estimation is correct. You can use the other formula:
In above formula, the SD mean Standard Deviation, this value could give you the information about the probability that the estimation is correct.
Now you can conclude the estimation for the task “Create the test specification”
To complete the task “Create the test specification” of ABC Bank website, you need 166.6 ± 13.33 Man-hour (153.33 to 179.99 man-hour)
Step 4) Validate the estimation
Once you create an aggregate estimate for all the tasks mentioned in the WBS, you need to forward it to the management board, who will review and approve it.
The member of management board could comprise of the CEO, Project Manager & other stakeholders.
The management board will review and discuss your estimation plan with you. You may explain them your estimation logically and reasonably so that they can approve your estimation plan.
Test estimation best practices
This topic introduces general tips on how to estimate Testing accuracy.
· Add some buffer time: Many unpredictable things may happen to your project, such as a talented team member quits his job suddenly, the testing takes more time than estimated to complete… etc. That why you need include some buffer in your estimation. Having a buffer in the estimation enables to cope for any delays that may occur.
· Account Resource planning in estimation: What should you do if some members in your team take long leaves? It may delay the project.Resource planning in estimation plays a key role. The availability of resources will help to make sure that the estimations are realistic. Here you have to consider the leaves for your team member, generally long leaves.
· Use the past experienceas reference: Experiences from past projects play a vital role while preparing the time estimates. Because some project may be some similarity, you can reuse the past estimation. For example, if you use to do a project like testing a website, you can learn from that experience, try to avoid all the difficulties or issues that were faced in past projects.
· Stick to your estimation: Estimation is just estimate because it may go wrong.In early stages of the project, you should frequently re-check the test estimations and make modification if needed. We should not extend the estimation after we fix it, unless there are major changes in requirement, or you have to negotiate with customer about the re-estimation
How to Create a Test Plan
Let’s start with following scenario
In a meeting, you want to discuss the Test Plan with the team members, but they are not interested - .
In such case, what will you do? Select your answer as following figure
A) I am Manager do everything as i said
B) OK, let's me explain why we need a Test Plan
As a Test Manager, you must explain them the importance of Test Plan rather than force the team to do what you want.
Making Test Plan has multiple benefits
· Test Plan helps us determine the effort needed to validate the quality of the application under test
· Help people outside the test team such as developers, business managers, customers understand the details of testing.
· Test Plan guides our thinking. It is like a rule book, which needs to be followed.
· Important aspects like test estimation, test scope, test strategy are documented in Test Plan, so it can be reviewed by Management Team and re-used for other projects.
How to make a Test Plan
You already know that making a Test Plan is the most important task of Test Management Process. Follow the seven steps below to create a test plan
Step 1) Analyze the product
How can you test a product without any information about it? The answer is Impossible. You must learn a product thoroughly before testing it.
The product under test is ABC banking website. You should research clients and the end users to know their needs and expectations from the application
· Who will use the website?
· What is it used for?
· How will it work?
· What are software/ hardware the product uses?
You can use the following approach to analyze the site
Now let’s apply above knowledge to a real product: Analyze the banking website
You should take a look around this website and also review product documentation. Review of product documentation helps you to understand all the features of the website as well as how to use it. If you are unclear on any items, you might interview customer, developer, designer to get more information.
Step 2) Develop Test Strategy
Test Strategy is a critical step in making a Test Plan. A Test Strategy document, is a high level document, which is usually developed by Test Manager. This document defines:
· The project’s testing objectives and the means to achieve them
· Determines testing effort and costs
Back to your project, you need to develop Test Strategy for testing that banking website. You should follow steps below
Step 2.1) Define Scope of Testing
Before the start of any test activity, scope of the testing should be known. You must think hard about it.
· The components of the system to be tested (hardware, software, middleware, etc.) are defined as "in scope"
· The components of the system that will not be tested also need to be clearly defined as being "out of scope."
Defining the scope of your testing project is very important for all stakeholders. A precise scope helps you
· Give everyone a confidence & accurate information of the testing you are doing
· All project members will have a clear understanding about what is tested and what is not
How do you determine scope your project?
To determine scope, you must –
· Precise customer requirement
· Project Budget
· Product Specification
· Skills & talent of your test team.
Now should clearly define the "in scope" and "out of scope" of the testing.
· As the software requirement specs, the project ABC Bank only focus on testing all the functions and external interface of website ABC Bank (in scope testing)
· Non functional testing such as stress, performance or logical database currently will not be tested. (out of scope)
Problem Scenario
The customer wants you to test his API. But the project budget does not permit to do so. In such a case what will you do?
Well, in such case you need to convince the customer that API testing is extra work and will consume significant resources. Give him data supporting your facts. Tell him if API testing is included in-scope the budget will increase by XYZ amount.
The customer agrees and accordingly the new scopes, out of scope items are
· In-scope items: Functional Testing, API Testing
Step 2.2) Identify Testing Type
A Testing Type is a standard test procedure that gives an expected test outcome.
Each testing type is formulated to identify a specific type of product bugs. But, all Testing Types are aimed at achieving one common goal “Early detection of all the defects before releasing the product to the customer”
The commonly used testing types are described as following figure
There are tons of Testing Types for testing software product. Your team cannot have enough efforts to handle all kind of testing. As Test Manager, you must set priority of the Testing Types
· Which Testing Types should be focused for web application testing?
· Which Testing Types should be ignored for saving cost?
Now let's practice with your project. The product you want to test is a banking website.
Which Testing Types should you focus in this case?
Select All that Apply
Which Testing Types should you focus in this case?
Select All that Apply
A) Unit testing
B) API Testing
C) Integration Testing
D) System Testing
E) Install/Uninstall Testing
F) Agile testing
B) API Testing
C) Integration Testing
D) System Testing
E) Install/Uninstall Testing
F) Agile testing
Step 2.3) Document Risk & Issues
Risk is future’s uncertain event with a probability of occurrence and a potential for loss. When the risk actually happens, it becomes the ‘issue’.
In the article Risk Analysis and Solution, you have already learned about the ‘Risk’ analysis in detail and identified potential risks in the project.
In the Test Plan, you will document those risks
Risk
|
Mitigation
|
Team member lack the required
skills for website testing. |
Plan training course to skill up your
members |
The project schedule is too tight;
it's hard to complete this project on time |
SetTest Priority for each of the test
activity. |
Test Manager has poor management
skill |
Plan leadership training for manager
|
A lack of cooperation negatively
affects your employees' productivity |
Encourage each team member in his
task, and inspire them to greater efforts. |
Wrong budget estimate and cost overruns
|
Establish the scope before beginning
work, pay a lot of attention to project planning and constantly track and measure the progress |
Step 2.4) Create Test Logistics
In Test Logistics, the Test Manager should answer the following questions:
· Who will test?
· When will the test occur?
Who will test?
You may not know exact names of the tester who will test, but the type of tester can be defined.
To select the right member for specified task, you have to consider if his skill is qualified for the task or not, also estimate the project budget. Selecting wrong member for the task may cause the project tofail or delay.
Person having the following skills is most ideal for performing software testing:
· Ability to understand customers point of view
· Strong desire for quality
· Attentionto detail
· Good cooperation
In your project, the member who will take in charge for the test execution is the tester. Base on the project budget, you can choose in-source or out-source member as the tester.
When will the test occur?
Test activities must be matched with associated development activities.
You will start to test when you have all required items shown in following figure
Step 3) Define Test Objective
Test Objective is the overall goal and achievement of the test execution. The objective of the testing is finding as many software defects as possible; ensure that the software under test is bug free before release.
To define the test objectives, you should do 2 following steps
1. List all the software features (functionality, performance, GUI…) which may need to test.
2. Define the target or the goal of the test based on above features
Let’s apply these steps to find the test objective of your ABC Bank testing project
You can choose the ‘TOP-DOWN’ method to find the website’s features which may need to test. In this method, you break down the application under test to component and sub-component.
In the previous topic, you have already analyzed the requirement specs and walk through the website, so you can create a Mind-Map to find the website features as following
This figure shows all the features which the ABC website may have.
Based on above features, you can define the Test Objective of the project ABC as following
· Check that whether website ABC functionality(Account, Deposit…) is working as expected without any error or bugs in real business environment
· Check that the external interface of the website such as UI is working as expected and & meet the customer need
· Verify the usability of the website. Are those functionalities convenient for user or not?
Step 4) Define Test Criteria
Test Criteria is a standard or rule on which a test procedure or test judgment can be based. There’re 2 types of test criteria as following
Suspension Criteria
Specify the critical suspension criteria for a test. If the suspension criteria are met during testing, the active test cycle will be suspended until the criteria are resolved.
Example: If your team members report that there are 40% of test cases failed, you should suspend testing until the development team fixes all the failed cases.
Exit Criteria
It specifies the criteria that denote a successful completion of a test phase. The exit criteria are the targeted results of the test and are necessary before proceeding to the next phase of development. Example: 95% of all critical test cases must pass.
Some methods of defining exit criteria are by specifying a targeted run rate and pass rate.
· Run rate is ratio between number test cases executed/total test cases of test specification. For example, the test specification has total 120TCs, but the tester only executed 100 TCsàthe run rate is 100/120 = 0.83 (83%)
· Pass rate is ratio between numbers test cases passed / test cases executed. For example, in above 100 TCs executed, there’re 80TCs passedàthe pass rate is 80/100 = 0.8 (80%)
This data can be retrieved in Test Metric documents.
· Run rate is mandatory to be 100% unless a clear reason is given.
· Pass rate is dependent on project scope, but achieving high pass rate is a goal.
Example:Your Team has already done the test executions. They report the test result to you, and they want you to confirm the Exit Criteria.
In above case, the Run rate is mandatory is 100%, but the test team only completed 90% of test cases. It means the Run rate is not satisfied, so do NOT confirm the Exit Criteria
Step 5) Resource Planning
Resource plan is a detailed summary of all types of resources required to complete project task. Resource could be human, equipment and materials needed to complete a project
The resource planning is important factor of the test planning because helps in determining the number of resources (employee, equipment…) to be used for the project. Therefore, the Test Manager can make the correct schedule & estimation for the project.
This section represents the recommended resources for your project.
Human Resource
The following table represents various members in your project team
No.
|
Member
|
Tasks
|
1.
|
Test Manager
|
Managethe whole project
Define project directions
Acquire appropriate resources
|
2.
|
Tester
|
Identifying and describing appropriate test
techniques/tools/automation architecture
Verify and assess the Test Approach
Executethe tests, Log results, Report the defects.
Tester could be in-sourced or out-sourced members,
base on the project budget
For the task which required low skill, I recommend
you chooseoutsourced members to save project cost. |
3.
|
Developer in Test
|
Implementthe test cases, test program, test suite etc.
|
4.
|
Test Administrator
|
Builds up and ensures test environment and assets are
managed and maintained
SupportTester to use the test environment for test
execution |
5.
|
SQA members
|
Take in charge of quality assurance
Check to confirm whether the testing process is meeting
specified requirements |
System Resource
For testing, a web application, you should plan the resources as following tables:
No.
|
Resources
|
Descriptions
|
1.
|
Server
|
Install the web application under test
This includes a separate web server, database server, and application
server if applicable |
2.
|
Test tool
|
The testing tool is to automate the testing, simulate the user operation,
generate the test results
There are tons of test tools you can use for this project such as Selenium,
QTP…etc. |
3.
|
Network
|
You need a Network include LAN and Internet to simulate the real
business and user environment |
4.
|
Computer
|
The PC which users often use to connect the web server
|
Step 6) Plan Test Environment
What is the Test Environment
A testing environment is a setup of software and hardware on which the testing team is going to execute test cases. The test environment consists of real business and user environment, as well as physical environments, such as server, front end running environment.
How to setup the Test Environment
Back to your project, how do you set up test environment for this banking website?
To finish this task, you need a strong cooperation between Test Team and Development Team
You should ask the developer some questions to understand the web application under testclearly. Here’re some recommended questions. Of course, you can ask the other questions if you need.
· What is the maximum user connection which this website can handle at the same time?
· What are hardware/software requirements to install this website?
· Does the user's computer need any particular setting to browse the website?
Step 7) Schedule & Estimation
In the article Test estimation, you already used some techniques to estimate the effort to complete the project. Now you should include that estimation as well as the schedule to the Test Planning
In the Test Estimation phase, suppose you break out the whole project into small tasks and add the estimation for each task as below
Task
|
Members
|
Estimate effort
|
Create the test specification
|
Test Designer
|
170 man-hour
|
Perform Test Execution
|
Tester, Test Administrator
|
80 man-hour
|
Test Report
|
Tester
|
10 man-hour
|
Test Delivery
|
20 man-hour
| |
Total
|
280 man-hour
|
Then you create the schedule to complete these tasks.
Making schedule is a common term in project management. By creating a solid schedule in the Test Planning, the Test Manager can use it as tool for monitoring the project progress, control the cost overruns.
To create the project schedule, the Test Manager needs several types of input as below:
· Employee and project deadline: The working days, the project deadline, resource availability are the factors which affected to the schedule
· Project estimation: Base on the estimation, the Test Manager knows how long it takes to complete the project. So he can make the appropriate project schedule
· Project Risk : Understanding the risk helps Test Manager add enough extra time to the project schedule to deal with the risks
Let’s practice with an example:
Suppose the boss wants to complete the project ABC in one month, you already estimated the effort for each tasks in Test Estimation. You can create the schedule as below
Step 8) Test Deliverables
Test Deliverables is a list of all the documents, tools and other components that has to be developed and maintained in support of the testing effort.
There are different test deliverables at every phase of the software development lifecycle.
Test deliverables are provided before testing phase.
· Test plans document.
· Test cases documents
· Test Design specifications.
Test deliverables are provided during the testing
· Test Scripts
· Simulators.
· Test Data
· Test Trace-ability Matrix
· Error logs and execution logs.
Test deliverables are provided after the testing cycles is over.
· Test Results/reports
· Defect Report
· Installation/ Test procedures guidelines
· Release notes
No comments:
Post a Comment