k0sctl: add version test

Signed-off-by: Tom Wieczorek <tom@bibbu.net>
This commit is contained in:
Tom Wieczorek
2024-05-10 12:07:35 +02:00
parent 45cc392ca9
commit edba8f65a2
@@ -2,6 +2,8 @@
, buildGoModule
, fetchFromGitHub
, installShellFiles
, testers
, k0sctl
}:
buildGoModule rec {
@@ -34,6 +36,13 @@ buildGoModule rec {
done
'';
passthru.tests.version = testers.testVersion {
package = k0sctl;
command = "k0sctl version";
# See https://github.com/carlmjohnson/versioninfo/discussions/12
version = "version: (devel)\ncommit: v${version}\n";
};
meta = with lib; {
description = "A bootstrapping and management tool for k0s clusters.";
homepage = "https://k0sproject.io/";