test

module
v0.0.0-...-d60d8a8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 30, 2026 License: MIT

README

Functional and smoke testing for Anubis

This directory contains all the functional testing infrastructure for Anubis.

Smoke tests

A smoke test is a folder with an executable file named test.sh. This test.sh file is responsible for starting up Anubis, running some logic ideally with backoff-retry, and then returning 0 for success or anything else for failure. CI will backoff-retry smoke tests to ensure they aren't flaky.

Best practices for smoke tests
  • Source lib/lib.sh. It is there to save you time.
  • If you are starting services with docker compose, use build_anubis_ko and load anubis from ko.local/anubis.
  • Make tests as deterministic as possible.
  • Use the default configuration as much as possible.
  • Make tests run as fast as possible.
  • If you need to do anything involving reading response metadata, write your logic in JavaScript and put it in test.mjs.
  • If your smoke test exists because of an event, horrifying discovery, or other tale of woe, record it in README.md as a tale of woe. See the gitweb smoke test for an example.

Make sure to add smoke tests to the smoke testing GitHub Actions workflow.

Directories

Path Synopsis
cmd
cipra command
httpdebug command
relayd command
unixhttpd command

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL