This is testing without having an insight into the details of the underlying code.

Here, we based based on a system’s specification, testing actual functionality. Black box testing helps test case generation and test oracles.

Pros and Cons

Pros

  • No need for source code
  • Wide applicability (unit and systems-level testing) Cons
  • Does not test hidden functions

Error Guessing

In this approach, we guess based on experience. Here:

  1. Make list of possible errors or error-prone situations
  2. Yields an error model
  3. Design test cases to cover error model We develop and maintain our own error models. These errors models are the things I would intuitively think to test for. For example, if I’m testing an array sorting function:
  • Empty array
  • Already sorted array
  • Reverse sorted array

Derivation from Functional Requirements

This is the point of black box testing

  • Involves clarification and restatement of requirements such that requirements are testable
  • Enumerate single requirements and group related requirements
  • For each requirement
    • One test case showing the requirement functioning
    • One test case trying to falsify something
    • Test boundaries

Derivation from Use Cases

For each use case:

  1. Develop a scenario graph
  2. Determine all possible scenarios
  3. Analyze and rank scenarios
  4. Generate test cases from scenarios to meet coverage goal
  5. Execute test cases

Other ways to do this: