tests/generated: use runCommandNoCCLocal and structuedAttrs

The former makes the test derivation _slightly_ smaller, the latter
makes the `$errors` stdenv variable slightly more robust.
This commit is contained in:
Matt Sturgeon 2024-09-09 15:58:27 +01:00
parent 9f4c9ea7e4
commit 0f83298f2c
No known key found for this signature in database
GPG key ID: 4F91844CED1A8299

View file

@ -1,6 +1,6 @@
{ {
lib, lib,
runCommand, runCommandNoCCLocal,
pkgs, pkgs,
}: }:
let let
@ -81,7 +81,12 @@ let
) )
); );
in in
runCommand "generated-sources-test" { inherit errors; } '' runCommandNoCCLocal "generated-sources-test"
{
__structuredAttrs = true;
inherit errors;
}
''
if [ -n "$errors" ]; then if [ -n "$errors" ]; then
echo -n "$errors" echo -n "$errors"
exit 1 exit 1