From 236b645ffbe276f473d5dbb6578aa6bd42c50338 Mon Sep 17 00:00:00 2001 From: Piotr Piotrowski Date: Mon, 22 Apr 2024 09:06:21 +0200 Subject: [PATCH] Fix test Signed-off-by: Piotr Piotrowski --- nats_test.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/nats_test.go b/nats_test.go index 7f7e71bce..028b326c3 100644 --- a/nats_test.go +++ b/nats_test.go @@ -94,10 +94,11 @@ func checkErrChannel(t *testing.T, errCh chan error) { } func TestVersionMatchesTag(t *testing.T) { - tag := os.Getenv("GITHUB_ACTIONS") - if tag == "" { + refType := os.Getenv("GITHUB_REF_TYPE") + if refType != "tag" { t.SkipNow() } + tagName := os.Getenv("GITHUB_REF_NAME") // We expect a tag of the form vX.Y.Z. If that's not the case, // we need someone to have a look. So fail if first letter is not // a `v`