Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Artifact: Test Script

The step-by-step instructions that realize a test, enabling its execution. Test Scripts may take the form of either documented textual instructions that are executed manually or computer readable instructions that enable automated test execution.
Role:Tester
Optionality/Occurrence:Define as many Test Scripts as needed to provide the appropriate amount of testing.
Templates and Reports:
Examples:
UML Representation:Not applicable.
More Information:- Guideline: Programming Automated Test Scripts - Checklist: Test Script

Purpose

The purpose of the Test Script is to provide the implementation of a subset of required tests in an efficient and effective manner.

Brief Outline

Each Test Script should consider various aspects including the following:

  • The basic computer hardware requirements; for example, Processors, Memory Storage, Hard-disk Storage, Input/ Output Interface Devices
  • The basic underlying software environment; for example, Operating System and basic productivity tools such as e-mail or a calendar system
  • Additional specialized input/output peripheral hardware; for example, Bar-code scanners, receipt printers, cash draws, and sensor devices
  • The required software for the specialized input/ output peripheral hardware; for example, drivers, interface and gateway software
  • The minimal set of software tools necessary to facilitate test, evaluation and diagnostic activities; for example,  memory diagnostics, automated test execution, and so forth
  • The required configuration settings of both hardware and software options; for example, video-display resolution, resource allocation, environment variables, and so on
  • The required “preexisting” consumables; for example, populated data sets, receipt printer dockets, and the like.

Properties

There are no UML representations for these properties.

Property NameBrief Description
NameAn unique name used to identify this Test Script.
DescriptionA short description of the contents of the Test Script, typically giving some high-level indication of complexity and scope.
PurposeAn explanation of what this test script represents and why it is important.
Dependent Test and Evaluation ItemsSome form of traceability or dependency mapping to specific elements such as individual Requirements that need to be referenced.
PreconditionsThe starting state that must be achieved prior to the Test Script being executed.
InstructionsEither the step-by-step instructions for executing the manual test, or the machine readable instructions that, when executed, stimulate the software in a similar manner to the actions that would be undertaken by the appropriate Actor, human or otherwise.
Observation PointsOne or more locations in the Test Script instructions where some aspect of the system state will be observed, and usually compared with an expected result.
Control PointsOne or more locations in the Test Script instructions where some condition or event in the system may occur and needs to be considered in regard to determining the next instruction to be followed.
Log PointsOne or more locations in the Test Script instructions where some aspect of the executing test script state is recorded for the purpose of future reference.
PostconditionsThe resulting state that the system must be left in after the Test Script has been executed.

Timing

The initial Test Scripts can be created as soon as there are some software components against which to implement the tests. The Test Scripts are modified and extended throughout the remainder of the lifecycle, during the course of each test cycle.

Responsibility

The Tester role is primarily responsible for this artifact. Those responsibilities include:

  • identifying and defining each Test Script, and managing all subsequent changes
  • ensuring the Test Script accurately reflects the required test, identified by one or more a Test Ideas or defined in one or more Test Cases
  • ensuring the Test Script is implemented according to defined standards to be compatible and maintainable with the other Test Scripts
  • ensuring the Test Script makes reasonably efficient use of the available resources
  • developing the Test Script with a focus on economy of effort and identifying opportunities for reuse and simplification
  • developing the Test Script so that it can be used as part of a Test Suite

Tailoring

Manual Test Scripts may be documented using some form of text document, spreadsheet, or table, or using a specialized test documentation support tool.

Automated Test Scripts may be created (recorded) or automatically generated using test automation tools, programmed using a programming language, or any combination of the above. The Test Scripts may be modified to include programming concepts, such as referencing common function libraries, using variables, loops, and branching to increase the efficiency, effectiveness, and resilience of the scripts.

In certain cases, it will be appropriate to use automated Test Scripts as informal, transient resources, avoiding the effort and cost of maintaining them.