Commit 9c9a7e00 authored by Silvan Mosberger's avatar Silvan Mosberger
Browse files

tests.nixpkgs-check-by-name: Fix with parallel tests

We seem to have enough tests to run into this now:

    error: creating symlink from '/private/tmp/nix-build-nixpkgs-check-by-name.drv-0/source/test-tmp/var/nix/gcroots/profiles' to '/private/tmp/nix-build-nixpkgs-check-by-name.drv-0/source/test-tmp/var/nix/profiles': File exists
parent d518eb94
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -25,6 +25,10 @@ let
        export NIX_LOG_DIR=$TEST_ROOT/var/log/nix
        export NIX_STATE_DIR=$TEST_ROOT/var/nix
        export NIX_STORE_DIR=$TEST_ROOT/store

        # cargo tests run in parallel by default, which would then run into
        # https://github.com/NixOS/nix/issues/2706 unless the store is initialised first
        nix-store --init
      '';
      postCheck = ''
        cargo fmt --check