From 00f753530d79e66494dd31352349e5c2daeb4893 Mon Sep 17 00:00:00 2001 From: Paramtamtam <7326800+tarampampam@users.noreply.github.com> Date: Thu, 23 Feb 2023 20:44:44 +0400 Subject: [PATCH] =?UTF-8?q?chore:=20=F0=9F=94=A7=20Changes=20that=20do=20n?= =?UTF-8?q?ot=20modify=20src=20or=20test=20files?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/tests.yml | 1 + internal/pkg/http/fileserver/fileserver_test.go | 8 +++----- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d622d34..adae920 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -33,6 +33,7 @@ jobs: with: {go-version: 1.19} - uses: golangci/golangci-lint-action@v3 # Action page: + with: {skip-pkg-cache: true, skip-build-cache: true} goreportcard: name: Update state on goreportcard.com diff --git a/internal/pkg/http/fileserver/fileserver_test.go b/internal/pkg/http/fileserver/fileserver_test.go index 4d2c728..e0976b4 100644 --- a/internal/pkg/http/fileserver/fileserver_test.go +++ b/internal/pkg/http/fileserver/fileserver_test.go @@ -12,18 +12,16 @@ import ( "github.com/stretchr/testify/assert" ) -func init() { //nolint:gochecknoinits - rand.Seed(time.Now().UnixNano()) -} - var letterRunes = []rune("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ") //nolint:gochecknoglobals func RandStringRunes(t *testing.T, n int) string { t.Helper() + rnd := rand.New(rand.NewSource(time.Now().UnixNano())) //nolint:gosec + b := make([]rune, n) for i := range b { - b[i] = letterRunes[rand.Intn(len(letterRunes))] //nolint:gosec + b[i] = letterRunes[rnd.Intn(len(letterRunes))] } return string(b)