cod: fix tests

Co-authored-by: @jnetod @thiagokokada
main
superherointj 2 years ago
parent 4da89993ed
commit 64f3350532
  1. 13
      pkgs/tools/misc/cod/default.nix

@ -1,4 +1,4 @@
{ lib, fetchFromGitHub, buildGoModule }:
{ lib, fetchFromGitHub, buildGoModule, python3 }:
buildGoModule rec {
pname = "cod";
@ -15,7 +15,16 @@ buildGoModule rec {
ldflags = [ "-s" "-w" "-X main.GitSha=${src.rev}" ];
doCheck = false;
checkInputs = [ python3 ];
preCheck = ''
pushd test/binaries/
for f in *.py; do
patchShebangs ''$f
done
popd
export COD_TEST_BINARY="''${NIX_BUILD_TOP}/go/bin/cod"
'';
meta = with lib; {
description = "Tool for generating Bash/Fish/Zsh autocompletions based on `--help` output";

Loading…
Cancel
Save