Knowledge Center

The Fundamentals of Black Box Testing

Black box testing is a technique used to verify the functionality of the software under test. The process of black box testing is based on the requirement specifications. Its main purpose is to validate the system according to the predefined requirements.

Black box testing does not include any internal processing of the software. This means that database testing is not performed, and a verification process is independent of tools, platforms, development models, etc. So a black box technique does not focus on internal code and specifics of its implementation.

Schematically, black box testing can be represented in the following way.

black box approach

Black box testing does not require from a QA engineer to know how the software under test actually works. According to the approach, only inputs and outputs are verified. Also, black box testing is called “behavioral testing” as it focuses on software functionality.

Procedure of black box testing

In general, the procedure of black box testing includes the following steps:

  1. Examination of initial software requirements and project specifications
  2. Selection of valid inputs for positive test scenarios and invalid inputs for negative ones
  3. Expected outputs determination for both positive and negative test scenarios
  4. Test cases preparation with all the determined inputs
  5. Execution of ready test cases
  6. Comparison of actual results with expected ones
  7. Retesting after bug fixing if any.

The black box approach can be applied throughout the whole software development life cycle. It can be used at the stages of unit, integration, system, acceptance and regression testing. In the majority of cases, the system is verified in the production environment in order to evaluate the software from end users’ perspective. But the environment can be simulated if it is too difficult to execute real-life test scenarios in laboratory conditions.

Test data definition

As the number of possible inputs can be too large, testing all of them is not viable. Because of the reason, several techniques are applied to select a proper test data and ensure adequate test coverage. They are:

  • Boundary value analysis based on verification of only extreme boundary values, e.g., maximum, minimum, and typical
  • Equivalence class testing based on checking one value within one input class
  • Error guessing based on the previous experience of a QA engineer
  • Decision table testing based on tabular representation of combinations of inputs and correspondent system behavior
  • Graph based testing where a test case is written for each graph that represents the object.

black box methods

Types of black box testing

As there are functional and non-functional software requirements, black box testing can be of two types. Functional type focuses on the verification of system behavior under certain conditions. That can be the procedures of authentication and authorization, notification feature, business rules, etc.

Non-functional black box testing verifies such software attributes as performance, reliability, security, maintainability, usability, interoperability and others.

Advantages of black box testing

  • To perform black box testing, a QA engineer should not have deep technical and coding skills. Applying the approach, a tester is able to perform software verification without knowing the specifics of system architecture and development process. Black box testing is suitable for non-technical testers.
  • As black box technique is based on available software requirements and specifications, it is a way to prove that the system performs the functions only it is supposed to do and does not conduct any functions that contradict to the requirements.
  • A QA engineer is able to write test cases for black box testing as soon as a functional specification is ready. It accelerates the process of quality verification.