Merge pull request #238722 from raboof/hugo-test-version

hugo: add version test
This commit is contained in:
Arnout Engelen 2023-06-20 14:53:44 +02:00 committed by GitHub
commit 6b866a5e5f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,4 +1,12 @@
{ stdenv, lib, buildGoModule, fetchFromGitHub, installShellFiles, buildPackages }:
{ stdenv
, lib
, buildGoModule
, fetchFromGitHub
, installShellFiles
, buildPackages
, testers
, hugo
}:
buildGoModule rec {
pname = "hugo";
@ -34,6 +42,12 @@ buildGoModule rec {
--zsh <(${emulator} $out/bin/hugo completion zsh)
'';
passthru.tests.version = testers.testVersion {
package = hugo;
command = "hugo version";
version = "v${version}";
};
meta = with lib; {
description = "A fast and modern static website engine";
homepage = "https://gohugo.io";