Host unit tests in CI

Which configurations of the host unit-test suite (ninja check / gn_tests.sh / build_examples.py --target *-tests*) run in CI, when, and why.

Keep this file in sync: scripts/tools/list_unit_test_steps.py lists every CI step that runs unit tests into host_unit_tests.generated.txt. When a workflow change alters that list, run it with --update and update the tables below in the same PR. The code-lints job in lint.yml runs it with --check.

Release branches (v*-branch) run their own copy of each workflow. On push they behave like a master push; scheduled (nightly) workflows do not run on them.

Linux and macOS host

ConfigurationJob (workflow)PRMaster pushNightlyWhy
gcc, OpenSSL, enable_rttiBuild on Linux (python_lib) (build.yaml)yesyes–Builds the Python controller; also runs the suite
gcc, OpenSSL, use_coverageBuild on Linux (coverage) (build.yaml)yesyes–Codecov report
gcc, OpenSSL, memory debug checks, platform testsBuild on Linux (gcc_debug) (build.yaml)–yesCodeQLOnly run of chip_config_memory_debug_checks
gcc, OpenSSL, chip_logging=false, platform testsBuild on Linux (gcc_debug) (build.yaml)yes––Logging-off build
gcc, detail / progress / error logging off (compile)Build on Linux (gcc_debug) (build.yaml)–yes–Logging-level builds
gcc release (is_debug=false)Build on Linux (fake, gcc_release, clang, simulated)–yes–Release-mode build
clang ASan, OpenSSLBuild on Linux (fake, gcc_release, clang, simulated)yes––Sanitizer run on every PR
clang ASan, TSan, UBSan, OpenSSLBuild on Linux (fake, gcc_release, clang, simulated)–yes–Full sanitizer set after merge
fake platform (linux-fake-tests)Build on Linux (fake, gcc_release, clang, simulated)yesyes–Platform-independent tests
clang ASan, PSACrypto Backend Unit Tests (unit_integration_test.yaml)crypto pathscrypto paths–Crypto backend
clang ASan, mbedTLSCrypto Backend Unit Tests (unit_integration_test.yaml)crypto pathscrypto paths–Crypto backend
clang ASan, BoringSSL, ICD + ARL + rotating idNightly Unit Tests - Linux (various features) (nightly.yaml)––yesFeature flags; ~66m, TestRead waits on ICD timers
clang ASan, BoringSSL / mbedTLS / PSANightly ASAN Testing across Crypto Backends (nightly.yaml)––yesCrypto backends with ASan
clang MSanNightly MSAN Tests - Linux (nightly.yaml)––yesUninitialized-memory checks
macOS ASan, BoringSSL, target_os="all"Build on Darwin (clang, simulated) (build.yaml)yesyes–macOS host

“Crypto paths”: src/credentials, src/crypto, src/pw_backends, third_party/pigweed, third_party/mbedtls, unit_integration_test.yaml. “Platform tests”: chip_build_all_platform_tests=true (Silabs host tests).

Embedded targets

ConfigurationJob (workflow)PRMaster pushWhy
ESP32 QEMU, mbedTLSESP32_QEMU (qemu.yaml)yesyesESP32 target
Tizen QEMUTizen (qemu.yaml)yesyesTizen target
Zephyr native_sim, PSAnRF Connect SDK (examples-nrfconnect.yaml)some pathsyesnRF target

Open questions

  • gcc runs the full suite three times on every PR (python_lib, coverage, gcc_debug chip_logging=false). Is more than one needed?
  • Release branches get no nightly coverage (#74387).