From 3000bf458c5361182e3869cbc1c193dea1a9e222 Mon Sep 17 00:00:00 2001 From: Miguel Pires Date: Fri, 6 Jan 2023 12:27:29 +0000 Subject: [PATCH] bootloader: fix test w/ auto-generated copyright year Signed-off-by: Miguel Pires --- bootloader/assets/genasset/main_test.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/bootloader/assets/genasset/main_test.go b/bootloader/assets/genasset/main_test.go index fb8427ecd5f..8438839263d 100644 --- a/bootloader/assets/genasset/main_test.go +++ b/bootloader/assets/genasset/main_test.go @@ -27,7 +27,6 @@ import ( "os/exec" "path/filepath" "testing" - "time" . "gopkg.in/check.v1" @@ -91,7 +90,7 @@ func (s *generateAssetsTestSuite) TestSimpleAsset(c *C) { const exp = `// -*- Mode: Go; indent-tabs-mode: t -*- /* - * Copyright (C) %d Canonical Ltd + * Copyright (C) 2022 Canonical Ltd * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License version 3 as @@ -119,7 +118,7 @@ func init() { }) } ` - c.Check(string(data), Equals, fmt.Sprintf(exp, time.Now().Year(), filepath.Join(d, "in"))) + c.Check(string(data), Equals, fmt.Sprintf(exp, filepath.Join(d, "in"))) } func (s *generateAssetsTestSuite) TestGoFmtClean(c *C) {