1
Software Quality Engineering
                        Assignment
    1|P age
2
                        University of
                     Kotli Azad Kashmir
                                 Assignment
    Subject        : Software Quality Engineering
    Topic          : Model Base Testing & Testing Documentations
    Submitted To   : Mam Umma-e-Habiba
    Submitted By   : Noman Ishrat , Imtiaz & Arslan
    Roll No         : 24 ,25 &26
    Class           : BS (SE) 6th
    Date           :13-09-2019
    Session        :2016/2020
    2|P age
3
                            Topic: Model Based Testing
    What is Model Based Testing?
    Model based testing is a software testing technique where run time behavior of
    software under test is checked against predictions made by a model. A model is a
    description of a system's behavior. Behavior can be described in terms of input
    sequences, actions, conditions, output and flow of data from input to output. It
    should be practically understandable and can be reusable; shareable must have a
    precise description of the system under test.
    There are numerous models available and it describes different aspects of the system
    behavior. Examples of the model are:
       •   Data Flow
       •   Control Flow
       •   Dependency Graphs
       •   Decision Tables
       •   State transition machines
    Model-Based Testing describes how a system behaves in response to an action
    (determined by a model). Supply action, and see, if the system responds as per the
    expectation.
    It is a lightweight formal method to validate a system. This testing can be applied to
    both hardware and software testing.
    Different Models in Testing:
    In order to understand the MBT, it is necessary to understand some of the models
    explained below. Let's go through one by one:
    ➢ Finite State Machines
    This model helps testers to assess the result depending on the input selected. There
    can be various combinations of the inputs which result in a corresponding state of
    the system.
    The system will have a specific state and current state which is governed by a set of
    inputs given from the testers.
    Consider the example:
    3|P age
4
    There is a system which allows employees to log- into the application. Now, a
    current state of the employee is ''Out'' and it became ''In'' once he signs- into the
    system. Under the ''in'' state, an employee can view, print, scan documents in the
    system.
    ➢ Unified Modeling Language (UML)
    Unified Modeling Language (UML) is a standardized general-purpose modeling
    language. UML includes a set of graphic notation techniques to create visual
    models of that can describe very complicated behavior of the system.
    UML has notations such as:
       •   Activities
       •   Actors
       •   Business Process
       •   Components
       •   Programming language
    4|P age
5
    State Charts
    It is an extension of Finite state machine and can be used for complex and real time
    systems. State charts are used to describe various behaviors of the system. It has a
    definite number of states. The behavior of the system is analyzed and represented in
    the form of events for each state.
    For example :
    Defects are raised in defect management tool with the status as New. Once it is fixed
    by developers, it has to be changed to status Fixed. If a defect is not fixed change
    status to Re-open. State chart should be designed in such a way that it should call for
    an event for each state.
    5|P age
6
    Advantages and disadvantages of model-based testing are :
    Advantages to MBT:
    ➢ Once the model is created, model-based tests can cover an incredibly large
      variety of scenarios with relatively little effort.
    ➢ Random execution of the model can uncover problems that would not be
      revealed up front.
    ➢ The MBT process can find design and specification errors quickly.
    ➢ Changes to the model will increase coverage and some MBT tools can
      automatically update test suites.
    Disadvantages to MBT:
    ➢ MBT has a steep learning curve -- for developers integrating testing knowledge,
      and for testers learning how modeling relates to testing.
    ➢ If there is a large random test, MBT requires a great deal of infrastructure
      (many machines), a great deal of time (measured in hours to days for high
      coverage) or both.
    ➢ MBT tools can be time-consuming and difficult to implement, but actual test
      creation and execution can be faster, which leads to faster test processes.
    Conclusion
    Testers construct mental models anyway during their testing. Those mental models
    can be transformed into models on paper. This helps testers to achieve readability
    and re-usability.
    Model based testing is a new approach to software testing. The evolution of
    Software Testing is shown below -
    6|P age
7
                     Topic: Test Documentation in Software Testing
    Introduction
    Test documentation is documentation of artifacts created before or during the testing
    of software. It helps the testing team to estimate testing effort needed, test coverage,
    resource tracking, execution progress, etc. It is a complete suite of documents that
    allows you to describe and document test planning, test design, test execution, test
    results that are drawn from the testing activity.
    Why Test Formality?
    For a newbie, it's easy to assume that Testing is executing the various section of
    code on an ad-hoc basis and verifying the results. But in the real world, Testing is a
    very formal activity and is documented in detail. Test Documentation makes
    planning, review, and execution of testing easy as well as verifiable.
    The degree of test formality depends on
    ➢   The type of application under test
    ➢   Standards followed by your organization
    ➢   The maturity of the development process.
    7|P age
8
    Testing activities generally consume 30% to 50% of software development project
    effort. Documentations help to identify Test process improvement that can be
    applied to future projects.
    Best practice to Achieve Test Documentation
        ➢   QA team needs to be involved in the initial phase of the project so that Test
            Documentation is created in parallel
        ➢   Don’t just create and leave the document, but update whenever required
        ➢   Use version control to manage and track your documents
        ➢   Try to document what is needed for you to understand your work and what
            you will need to produce to your stakeholders
        ➢   You should use a standard template for documentation like excel sheet or
            doc file
        ➢   Store all your project related documents at a single location. It should be
            accessible to every team member for reference as well as to update when
            needed
        ➢   Not providing enough detail is also a common mistake while creating a test
            document
    Advantages of Test Documentation
    ➢   The main reason behind creating test documentation is to either reduce or
        remove any uncertainties about the testing activities. Helps you to remove
        ambiguity which often arises when it comes to the allocation of tasks
    ➢   Documentation not only offers a systematic approach to software testing, but it
        also acts as training material to freshers in the software testing process
    ➢   It is also a good marketing & sales strategy to showcase Test Documentation to
        exhibit a mature testing process
    ➢   Test documentation helps you to offer a quality product to the client within
        specific time limits
    ➢   In Software Engineering, Test Documentation also helps to configure or set-up
        the program through the configuration document and operator manuals
    ➢   Test documentation helps you to improve transparency with the client
    Disadvantages of Test Documentation
    ➢   The cost of the documentation may surpass its value as it is very time-
        consuming
    8|P age
9
    ➢   Many times, it is written by people who can't write well or who don't know the
        material
    ➢   Keeping track of changes requested by the client and updating corresponding
        documents is tiring.
    ➢   Poor documentation directly reflects the quality of the product as a
        misunderstanding between the client and the organization can occur
    9|P age