Skip to content

Add gitlab-ci-test-base module for test standardization

Horizon Bot requested to merge add-test-base-module into master

Summary

Adds a new gitlab-ci-test-base flake-parts module that provides common test infrastructure, eliminating duplication across all 15 test flakes.

Changes

  • New module: nix/modules/flake/gitlab-ci-test-base.nix

    • Automatically imports gitlab-ci.flakeModule and treefmt-nix.flakeModule
    • Sets default system to x86_64-linux
    • Enables gitlab.ci only on x86_64-linux (prevents duplicate jobs)
    • Enables flake validation by default (flake-show, flake-lock, strict-inputs)
    • Sets flake.flakes = [ "." ] for validator modules
  • Test standardization: All 15 tests converted to use test-base module

    • Tests now use single nix/ci.nix file
    • Removed 24 redundant files (configuration.nix, default.nix, systems.nix, treefmt.nix)
    • Reduces test configuration duplication by 60%+
    • Net reduction: 285 deletions → 123 insertions
  • Documentation:

    • Updated ChangeLog.md for 0.18.0 release
    • Added "Testing and Development" section to README.md
    • Documented test-base module usage and benefits

Benefits

Consistent test structure across all tests Automatic flake validation for all tests Significantly reduced code duplication Easier to write new tests All tests now validate their own flake structure

Test Plan

  • All 15 tests generate valid CI output with flake validation jobs
  • Main CI pipeline includes all tests in matrix
  • All flake.lock files updated

🤖 Generated with Claude Code

Merge request reports