mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-17 01:24:47 +00:00
kubectl-gadget: add version test
This commit is contained in:
parent
a4ffcf5664
commit
7a41a8c71d
@ -1,4 +1,4 @@
|
||||
{ lib, buildGoModule, fetchFromGitHub }:
|
||||
{ lib, buildGoModule, fetchFromGitHub, kubectl-gadget, testers }:
|
||||
|
||||
buildGoModule rec {
|
||||
pname = "kubectl-gadget";
|
||||
@ -28,6 +28,12 @@ buildGoModule rec {
|
||||
|
||||
subPackages = [ "cmd/kubectl-gadget" ];
|
||||
|
||||
passthru.tests.version = testers.testVersion {
|
||||
package = kubectl-gadget;
|
||||
command = "kubectl-gadget version || true"; # mask non-zero return code if no kubeconfig present
|
||||
version = "v${version}";
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
description = "Collection of gadgets for troubleshooting Kubernetes applications using eBPF";
|
||||
mainProgram = "kubectl-gadget";
|
||||
|
Loading…
Reference in New Issue
Block a user