Reliability and performance tests

Smoke test

1 min

Intro

Smoke test is a preliminary test that checks whether the basic and critical functionalities of a software build work correctly. It is used to verify that the software is stable enough for further, more detailed testing.

 
Easy explanation

Checking if a bridge is safe enough for cars.

The term comes from hardware testing, where engineers powered on a device and checked if smoke came out — if it did, testing stopped immediately.

Scheme

Smoke test scheme

 
Info

To better understand the terms in testing and tool k6 see vocabulary.

Key characteristics

  • Shallow and broad: Focuses on covering major features, not detailed behavior.
  • Quick execution: Designed to run quickly to validate build stability.
  • Gatekeeper: Acts as a gate before proceeding to deeper testing.
  • Automated or manual: Can be automated but is often a simple checklist when manual.
  • Frequent execution: Typically run on every new build to catch show-stopper issues early.

Practical examples

  • Is API returning response?
  • Does main page loads?
  • Can user login?

Users and time

  • Number of virtual users:

    Smoke testing is not about concurrency or load — typically performed with 1 user or simulated user session.

  • Execution time:

    Smoke tests should be fast - ideal duration is a few minutes (e.g., 5–15 min max), depending on project complexity, to quickly give feedback on build health.

Examples with tool k6

Simple example

script.js

import http from 'k6/http';
import { check } from 'k6';

export const options = {
  vus: 1,
  iterations: 5,
};

export default function () {
  const response = http.get('https://api.example.com/health');

  check(response, {
    'status is 200': (res) => res.status === 200,
    'body is not empty': (res) => res.body.length > 0,
  });
}
Runnable example

 
Playground

Dive deeper with a live test demonstration.

Resources