From 1076af3b622ccf49615cb50dee153b20f46cf68e Mon Sep 17 00:00:00 2001 From: hakan-demirli Date: Thu, 18 Apr 2024 10:21:18 +0300 Subject: [PATCH] use passthru tests --- pkgs/development/tools/scalafix/default.nix | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/pkgs/development/tools/scalafix/default.nix b/pkgs/development/tools/scalafix/default.nix index baf81acc40f6..4b4f887d4a04 100644 --- a/pkgs/development/tools/scalafix/default.nix +++ b/pkgs/development/tools/scalafix/default.nix @@ -6,6 +6,7 @@ makeWrapper, installShellFiles, setJavaClassPath, + testers, }: stdenv.mkDerivation ( finalAttrs: { @@ -37,9 +38,12 @@ stdenv.mkDerivation ( --zsh <($out/bin/${finalAttrs.pname} --zsh) ''; - installCheckPhase = '' - $out/bin/${finalAttrs.pname} --version | grep -q "${finalAttrs.version}" - ''; + passthru.tests = { + testVersion = testers.testVersion { + program = "${finalAttrs.pname}"; + version = "${finalAttrs.version}"; + }; + }; meta = with lib; { description = "Refactoring and linting tool for Scala";