Drop support for old test-driver
This commit is contained in:
parent
a8db3b881b
commit
107ed51c8e
2 changed files with 1 additions and 105 deletions
23
nix/lib.nix
23
nix/lib.nix
|
|
@ -313,28 +313,7 @@ in
|
|||
]};
|
||||
'';
|
||||
|
||||
test-driver =
|
||||
let
|
||||
upstream = hostPkgs.callPackage "${nixpkgs}/nixos/lib/test-driver" { };
|
||||
in
|
||||
upstream.overrideAttrs (_: {
|
||||
# Try to apply the patch for backwards compat.
|
||||
# It is included upstream starting from NixOS 23.05.
|
||||
# github.com/NixOS/nixpkgs#228220
|
||||
postPatch =
|
||||
let
|
||||
patch = "${lib.getBin hostPkgs.patch}/bin/patch";
|
||||
patchFile = ../test/0001-nixos-test-driver-include-a-timeout-for-the-recv-cal.patch;
|
||||
in
|
||||
''
|
||||
echo "Try to apply patch ${patchFile}..."
|
||||
if grep --quiet --fixed-strings "bash" test_driver/machine.py; then
|
||||
echo "Patch already present, ignoring..."
|
||||
else
|
||||
${patch} -p1 < ${patchFile}
|
||||
fi
|
||||
'';
|
||||
});
|
||||
test-driver = hostPkgs.callPackage "${nixpkgs}/nixos/lib/test-driver" { };
|
||||
|
||||
runTest = { nodes, vlans, testScript, extraDriverArgs }: ''
|
||||
${lib.getBin test-driver}/bin/nixos-test-driver \
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue