Tuesday, December 17, 2013

Difference between Verification and Validation

Difference between Verification and Validation

In few days back we have seen article about “V-Model”. In the V Model Software Development Life Cycle, based on requirement specification document the development & testing activity is started. The V-model is also called as Verification and Validationmodel. The testing activity is perform in the each phase of Software Testing Life Cycle. In the first half of the model validations testing activity is integrated in each phase like review user requirements, System Design document & in the next half the Verification testing activity is come in picture.
In interviews most of the interviewers are asking questions on  “What is Difference between Verification and Validation?” Lots of people use verification and validation interchangeably but both have different meanings. So in this article I am adding few differences about Verification & Validation.

Difference between software Verification and Validation:

             Verification             Validation
Are we building the system right?Are we building the right system?
Verification is the process of evaluating products of a development phase to find out whether they meet the specified requirements.Validation is the process of evaluating software at the end of the development process to determine whether software meets the customer expectations and requirements.
The objective of Verification is to make sure that the product being develop is as per the requirements and design specifications.The objective of Validation is to make sure that the product actually meet up the user’s requirements, and check whether the specifications were correct in the first place.
Following activities are involved in Verification: Reviews, Meetings and Inspections.Following activities are involved in Validation: Testing like black box testing, white box testing, gray box testing etc.
Verification is carried out by QA team to check whether implementation software is as per specification document or not.Validation is carried out by testing team.
Execution of code is not comes under Verification.Execution of code is not comes under Validation.
Verification process explains whether the outputs are according to inputs or not.Validation process describes whether the software is accepted by the user or not.
Verification is carried out before the Validation.Validation activity is carried out just after the Verification.
Following items are evaluated during Verification: Plans, Requirement Specifications, Design Specifications, Code, Test Cases etc,Following item is evaluated during Validation: Actual product or Software under test.
Cost of errors caught in Verification is less than errors found in Validation.Cost of errors caught in Validation is more than errors found in Verification.
It is basically manually checking the of documents and files like requirement specifications etc.It is basically checking of developed program based on the requirement specifications documents & files.

Conclusion on difference of Verification and Validation in software testing:
  1. Both Verification and Validation are essential and balancing to each other.
  2. Different error filters are provided by each of them.
  3. Both are used to finds a defect in different way, Verification is used to identify the errors in requirement specifications & validation is used to find the defects in the implemented Software application.

Software Development Methodologies(V Model)

V Model

In the basic Waterfall model process seen some disadvantages or limitations in the model which started a new SDLC model. As we seen in the Waterfall model the issues found in the end of the SDLC, this is due to the testing is occurred in the end phases of the you SDLC. To overcome this problem the V-Model is comes into the picture. It is always better to introduce testing in the early phase of SDLC, as in this model the testing activity gets started from the early phase of the SDLC.
Before starting the actual testing, testing team has to work on various activities like preparation of Test Strategy, Test Planning, Creation of Test cases & Test Scripts which is work parallel with the development activity which help to get the test deliverable on time.

V Model – Software Development Life Cycle

V Model - Software Development Life Cycle
V Model - Software Development Life Cycle
In the V Model Software Development Life Cycle, based on same information(requirement specification document) the development & testing activity is started. Based on the requirement document developer team started working on the design & after completion on design start actual implementation and testing team starts working on test planning, test case writing, test scripting. Both activities are working parallel to each other. In Waterfall model & V-model they are quite similar to each other. As it is most popular Software Testing Life Cycle model so most of the organization is following this model.
The V-model is also called as Verification and Validation model. The testing activity is perform in the each phase of Software Testing Life Cycle phase. In the first half of the model validations testing activity is integrated in each phase like review user requirements, System Design document & in the next half the Verification testing activity is come in picture.
Typical V-model shows Software Development activities on the Left hand side of model and the Right hand side of the model actual Testing Phases can be performed.
In this process “Do-Procedure” would be followed by the developer team and the “Check-Procedure” would be followed by the testing team to meets the mentioned requirements.
In the V-Model software development life cycle different steps are followed however here we will taking a most common type of V-model example. The V-model typically consist of the following phases:
1. Unit Testing: Preparation of Unit Test Cases
2. Integration Testing: Preparation of Integration Test Cases
3. System Testing: Preparation of System test cases
4. Acceptance Testing: Preparation of Acceptance Test Cases

Software Development Methodologies(Waterfall Model)

In the field of Software testing we use different types of Software Testing Methodologies.
In the Software Development Process different software development approaches are used. A software development process also known as a Software Development Life Cycle(SDLC).
1) Waterfall Model
The Waterfall Model approach is most basic life cycle model, which is the first Process Model begins and used broadly in Software Development to make sure project success. This model is developed by Winston Royce in the early 1970. Waterfall model is software development process sequential process, as flowing progressively downwards like waterfall via multiple phases & these simple sequence of phases has its own defines activities and goals. The Waterfall model is divided into following separate phases:
  • Requirement Gathering & Analysis phase,
  • Software Design,
  • Implementation and Testing
  • Maintenance
All these phases are the sequential phases & next step is totally depends on the previous step, so that second phase is begins as only if the defined set of objectives and goals are completed first.
The stages of “The Waterfall Model” are:
Requirement Gathering & Analysis:
This is the starting phase of the SDLC in which all possible system requirements are captured & analyzed. Software requirements specification includes the complete information about how actual end users are expecting from the system. This document covers all the necessary requirements for the development of project. Finally after completion of requirement gathering & analysis (validation of requirement against the user needs), a Requirement Specification document is created which give out as a input to the next phase of SDLC. In this model once we moved to the next phase then it won’t possible to add or update the requirements.
System & Software Design: Prior to start actual coding, it is mandatory to be aware of what all features we are going to implement & how it would look like? The requirement specifications document created in the first phase is used as the input to this phase & based on this the system design specifications would be prepared. In which all hardware & system requirements would be specified. The system design specifications document prepared in this phase is used as input for the Implementation & Testing phase model.
Implementation & Unit Testing: Upon getting the system design specifications document the actual coding would be started. Before starting the actual coding requirements are divided into the models/units. In the actual coding the initially develop the small programs called units. After implementing all units the integration would be started in the next phase. The developed unit’s model functionality is tested separately in this phase to check whether the unit models are meets the specified requirements & this individual model testing is called as Unit Testing.
Integration & System Testing: In the previous model the system requirements are divided into models & each model is developed & tested separately. In this phase all units are integrated & done the system testing to check whether the all models/units are integrated properly or not & the system as whole doing as mention as per the system requirement document, so we call this phase as the Integration & System Testing. Upon complete testing of software is done then actual Software is successfully send to customer.
Operations & Maintenance: This phase is the never ending phase of the Waterfall Model. The problems are comes in picture after Implementation & Unit Testing phase. The issues found after the implementation phase i.e. not found in the period of the development life cycle. Some of the issues are not catch after testing cycle done so those are implemented in the maintenance phase, so this phase is called as Operations & Maintenance phase.

Advantages and Disadvantages of Waterfall Model:

Advantages of Waterfall Model:
  • This is linear simple model to implement & easy to maintain.
  • In the SDLC initial phase spent time on reviewing requirements and design which saves the time later.
  • Required resources are minimum in this model as compare to other.
  • After every phase of the model a document in created which help & simpler to understand & design the system.
  • Upon completion of coding, is done to check for implemented code or correctness of system.
  •  For each stage deadlines can be set which will help to develop the system on decided time frame.
Disadvantages of Waterfall Model: 
  • The biggest disadvantages of such system is it won’t allow to go back. If the problems in the design phase which creates complication in the implementation phase.
  • This model is rigid model. Not flexible & make changes is not possible in the development of system.
  • Unable to start the next phase before completing the previous phase so time consuming.
  • In the deployment phase all requirements are not covered or all requirements are not cover so adding such requirements may create unsuitable system.
  • To make it customer happy such new requirement need to be implemented in new version of system which leads to added cost to system development.