From e9f88757ba538518af7d21a09ced588a348a8ba4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20Bombo?= Date: Fri, 14 Mar 2025 17:41:31 +0000 Subject: [PATCH] tests: Remove `replace` directives in go.mod MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Same rationale as for runtime. With tests, the blackfriday replacement was actually meaningful, so I refactored some imports. Signed-off-by: Aurélien Bombo --- tests/cmd/check-markdown/extract.go | 2 +- tests/cmd/check-markdown/hack.go | 2 +- tests/cmd/check-markdown/node.go | 2 +- tests/cmd/check-markdown/parse.go | 2 +- tests/cmd/check-markdown/toc.go | 2 +- tests/cmd/check-markdown/utils.go | 2 +- tests/go.mod | 8 ++++++-- 7 files changed, 12 insertions(+), 8 deletions(-) diff --git a/tests/cmd/check-markdown/extract.go b/tests/cmd/check-markdown/extract.go index 247bbdfbd..7b7df4491 100644 --- a/tests/cmd/check-markdown/extract.go +++ b/tests/cmd/check-markdown/extract.go @@ -9,7 +9,7 @@ package main import ( "fmt" - bf "gopkg.in/russross/blackfriday.v2" + bf "github.com/russross/blackfriday/v2" ) // linkDescription extracts the description from the specified link node. diff --git a/tests/cmd/check-markdown/hack.go b/tests/cmd/check-markdown/hack.go index ee65cc3a9..c2aeeaa03 100644 --- a/tests/cmd/check-markdown/hack.go +++ b/tests/cmd/check-markdown/hack.go @@ -9,7 +9,7 @@ package main import ( "strings" - bf "gopkg.in/russross/blackfriday.v2" + bf "github.com/russross/blackfriday/v2" ) // forceCreateHeadings extracts "missed" headings from the specified node, diff --git a/tests/cmd/check-markdown/node.go b/tests/cmd/check-markdown/node.go index 5d8d104a3..a13ba3ce5 100644 --- a/tests/cmd/check-markdown/node.go +++ b/tests/cmd/check-markdown/node.go @@ -7,7 +7,7 @@ package main import ( - bf "gopkg.in/russross/blackfriday.v2" + bf "github.com/russross/blackfriday/v2" ) // handleNode processes the specified node. diff --git a/tests/cmd/check-markdown/parse.go b/tests/cmd/check-markdown/parse.go index 930a3e892..c7b91f43b 100644 --- a/tests/cmd/check-markdown/parse.go +++ b/tests/cmd/check-markdown/parse.go @@ -11,7 +11,7 @@ import ( "os" "strings" - bf "gopkg.in/russross/blackfriday.v2" + bf "github.com/russross/blackfriday/v2" ) // List of errors found by visitor. Used as the visitor cannot return an error diff --git a/tests/cmd/check-markdown/toc.go b/tests/cmd/check-markdown/toc.go index 40eb5f8e3..eff78a2ad 100644 --- a/tests/cmd/check-markdown/toc.go +++ b/tests/cmd/check-markdown/toc.go @@ -10,7 +10,7 @@ import ( "fmt" "strings" - bf "gopkg.in/russross/blackfriday.v2" + bf "github.com/russross/blackfriday/v2" ) // displayTOC displays a table of contents entry for the specified node. diff --git a/tests/cmd/check-markdown/utils.go b/tests/cmd/check-markdown/utils.go index bd6d41541..efcc3352f 100644 --- a/tests/cmd/check-markdown/utils.go +++ b/tests/cmd/check-markdown/utils.go @@ -13,7 +13,7 @@ import ( "strings" "unicode" - bf "gopkg.in/russross/blackfriday.v2" + bf "github.com/russross/blackfriday/v2" ) // fileExists returns true if the specified file exists, else false. diff --git a/tests/go.mod b/tests/go.mod index ca5976b5f..667536138 100644 --- a/tests/go.mod +++ b/tests/go.mod @@ -2,12 +2,15 @@ module github.com/kata-containers/tests go 1.19 +// WARNING: Do NOT use `replace` directives as those break dependabot: +// https://github.com/kata-containers/kata-containers/issues/11020 + require ( github.com/olekukonko/tablewriter v0.0.6-0.20210304033056-74c60be0ef68 + github.com/russross/blackfriday/v2 v2.1.0 github.com/sirupsen/logrus v1.8.1 github.com/stretchr/testify v1.7.1 github.com/urfave/cli v1.22.0 - gopkg.in/russross/blackfriday.v2 v2.0.0-00010101000000-000000000000 gopkg.in/yaml.v2 v2.4.0 ) @@ -22,4 +25,5 @@ require ( gopkg.in/yaml.v3 v3.0.0 // indirect ) -replace gopkg.in/russross/blackfriday.v2 => github.com/russross/blackfriday/v2 v2.1.0 +// WARNING: Do NOT use `replace` directives as those break dependabot: +// https://github.com/kata-containers/kata-containers/issues/11020