Skip to content

Docker testing

Every package is tested twice:

  1. Unit tests against local mock HTTP servers (no network, no Docker), with coverage gates: TypeScript, Python and Java ≥ 90 % lines and branches, Rust ≥ 90 % lines and regions, Go ≥ 90 % statements.
  2. Integration tests against a real signoz/signoz-community:v0.150.0 (+ signoz-otel-collector + ClickHouse) in Docker. The package is packed and installed into a separate consumer project first, so the suite imports it exactly like a user does.

Run the integration suite

make test-docker                      # all five languages
make test-docker LANGS="go python"    # a subset

What happens per language:

  1. docker/compose.yml starts SigNoz (signoz/signoz-community:v0.150.0 (+ signoz-otel-collector + ClickHouse)) and waits for its health check.
  2. A one-shot bootstrap container prepares it (users, tokens, …) and writes the credentials to /bootstrap/env (KEY=value lines) on a shared volume.
  3. The test-<lang> image (built from docker/Dockerfile.<lang> with the repo root as context) builds and packs the package, installs it into <lang>/integration/ and runs the integration tests plus the conformance runner with GROW_SIGNOZ_URL pointing at the service.
  4. The stack is always removed with docker compose down -v, also on failure or Ctrl-C.

Every run uses its own Compose project name and publishes no host ports, so runs can happen in parallel on one machine.

Conformance scenarios

conformance/scenarios/*.json hold language-neutral scenarios. Each language's runner executes the scenarios of this service's categories against the real service and reports skipped scenarios with the reason:

  • core.health — health, ping, server version, close
  • logging.* — round trip, batching, redaction
  • tracing.* — span tree, services

Unit-level conformance (retries, timeouts, redaction, close twice) is covered by unit tests named after the ids in conformance/core-unit.md.

Test fakes for your own tests

Each package ships in-memory fakes so your application tests need neither Docker nor network:

Language Module
TypeScript @grow-codes/signoz/testing
Rust grow_signoz::testing (feature testing)
Go github.com/grow-codes-packages/signoz/go/testkit
Python grow_signoz.testing
Java codes.grow.packages.signoz.testing

CI

The ci workflow runs the unit pipelines (TypeScript on Node 22 and 24, Rust stable and 1.88, Go 1.26 and 1.27, Python 3.10, 3.13 and 3.14, Java 17, 21 and 25) and one Docker integration job per language. Failed Docker jobs upload the Compose logs as the artifact compose-logs-<lang>.