From 6b1567cca6af6f1d530b4d67d223af16605f9c1e Mon Sep 17 00:00:00 2001 From: Zoran Regvart Date: Wed, 8 Nov 2023 11:18:14 +0100 Subject: [PATCH] Fix the version test Happy New Year! --- internal/version/version_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/internal/version/version_test.go b/internal/version/version_test.go index d4a2925bf..510483996 100644 --- a/internal/version/version_test.go +++ b/internal/version/version_test.go @@ -38,12 +38,12 @@ func TestVersionInfoStringer(t *testing.T) { }, } - assert.Equal(t, `Version v1 + assert.Regexp(t, `^Version v1 Source ID abc -Change date 2009-11-10 23:00:00 +0000 UTC (13 years ago) +Change date 2009-11-10 23:00:00 \+0000 UTC \(\d{2} years ago\) dep1 v1 dep2 v2 -`, fmt.Sprintf("%v", vi)) +$`, fmt.Sprintf("%v", vi)) } func TestComputeInfo(t *testing.T) {