From 2e85b267aafa5152c86a63a78d85cf7fd24aec47 Mon Sep 17 00:00:00 2001 From: Arnout Engelen Date: Sun, 11 Dec 2022 16:24:13 +0100 Subject: [PATCH] nushell: do checks pulling in the upstream patch --- pkgs/shells/nushell/default.nix | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/pkgs/shells/nushell/default.nix b/pkgs/shells/nushell/default.nix index 8c33839a83cf..11c9aa67a2e2 100644 --- a/pkgs/shells/nushell/default.nix +++ b/pkgs/shells/nushell/default.nix @@ -1,6 +1,7 @@ { stdenv , lib , fetchFromGitHub +, fetchpatch , runCommand , rustPlatform , openssl @@ -33,6 +34,16 @@ rustPlatform.buildRustPackage rec { sha256 = "sha256-OVJr+usN+47yBHFAy94rIVlU2F+Klo6xdrV2MwUoKUE="; }; + patches = [ + # https://github.com/nushell/nushell/pull/7423: make tests + # more resilient (less dependent on env). + # Already merged upstream, so can be dropped in the next version + (fetchpatch { + url = "https://github.com/nushell/nushell/commit/87631e7068bfc6635d5b31413856f0a791994527.patch"; + hash = "sha256-9vrcmBe5gXLLodynb3jyarwi/a0YiurJ6WsDxXl2vjo="; + }) + ]; + cargoSha256 = "sha256-v6mPr+gOT64rKYuog+hS7/AqUZDailoOBXX3Sfeo+sk="; # enable pkg-config feature of zstd @@ -66,9 +77,7 @@ rustPlatform.buildRustPackage rec { # TODO investigate why tests are broken on darwin # failures show that tests try to write to paths # outside of TMPDIR - # doCheck = ! stdenv.isDarwin; - # TODO tests are not guaranteed while package is in beta - doCheck = false; + doCheck = ! stdenv.isDarwin; checkPhase = '' runHook preCheck