From 32c9e3193cb0b4e263707fc7bba0ef6d1541b952 Mon Sep 17 00:00:00 2001 From: Robert Hensing Date: Fri, 5 Jul 2024 15:47:28 +0200 Subject: [PATCH] tests.devShellTools: Fix release.nix / ofborg eval --- .../dev-shell-tools/tests/default.nix | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/pkgs/build-support/dev-shell-tools/tests/default.nix b/pkgs/build-support/dev-shell-tools/tests/default.nix index d78372b11ae0..fa52a20e8b89 100644 --- a/pkgs/build-support/dev-shell-tools/tests/default.nix +++ b/pkgs/build-support/dev-shell-tools/tests/default.nix @@ -13,14 +13,23 @@ let concatLines escapeShellArg isString + mapAttrs mapAttrsToList ; in lib.recurseIntoAttrs { - nixos = lib.recurseIntoAttrs { - inherit (nixosTests) docker-tools-nix-shell; - }; + nixos = lib.recurseIntoAttrs ( + # This should have been a simple optioanlAttrs, but release.nix is very picky. + # > cannot find attribute `tests.devShellTools.nixos.docker-tools-nix-shell' + let + tests = { + inherit (nixosTests) docker-tools-nix-shell; + }; + in + if stdenv.hostPlatform.system == "x86_64-linux" then tests else + mapAttrs (k: v: emptyFile) tests + ); # nix-build -A tests.devShellTools.valueToString valueToString =