aboutsummaryrefslogtreecommitdiff
path: root/internal/testutil
diff options
context:
space:
mode:
Diffstat (limited to 'internal/testutil')
-rw-r--r--internal/testutil/golden.go4
-rw-r--r--internal/testutil/noop_logger.go2
2 files changed, 3 insertions, 3 deletions
diff --git a/internal/testutil/golden.go b/internal/testutil/golden.go
index 7f0295a0..57800e17 100644
--- a/internal/testutil/golden.go
+++ b/internal/testutil/golden.go
@@ -29,7 +29,7 @@ func Update(name string) bool {
// AssertGolden compares what's got and what's in the golden file. It updates
// the golden file on-demand. It does nothing when the runtime is "windows".
-func AssertGolden(t testing.TB, path string, update bool, got interface{}) {
+func AssertGolden(t testing.TB, path string, update bool, got any) {
if runtime.GOOS == "windows" {
t.Skip("Skipping testing on Windows")
return
@@ -59,7 +59,7 @@ func AssertGolden(t testing.TB, path string, update bool, got interface{}) {
assert.Equal(t, string(golden), string(data))
}
-func marshal(t testing.TB, v interface{}) []byte {
+func marshal(t testing.TB, v any) []byte {
t.Helper()
switch v2 := v.(type) {
diff --git a/internal/testutil/noop_logger.go b/internal/testutil/noop_logger.go
index c13ebacd..db122390 100644
--- a/internal/testutil/noop_logger.go
+++ b/internal/testutil/noop_logger.go
@@ -26,6 +26,6 @@ func (*noopLogger) Write(log.Messager) error {
}
// InitNoopLogger is a init function to initialize a noop logger.
-var InitNoopLogger = func(name string, vs ...interface{}) (log.Logger, error) {
+var InitNoopLogger = func(name string, vs ...any) (log.Logger, error) {
return &noopLogger{}, nil
}