diff --git a/adapters/logrus/logrus.go b/adapters/logrus/logrus.go index 01c3035..034ea76 100644 --- a/adapters/logrus/logrus.go +++ b/adapters/logrus/logrus.go @@ -8,8 +8,10 @@ import ( "go.arsenm.dev/logger" ) -var _ logger.Logger = &LogrusLogger{} -var _ logger.LogBuilder = &LogrusLogBuilder{} +var ( + _ logger.Logger = &LogrusLogger{} + _ logger.LogBuilder = &LogrusLogBuilder{} +) type LogrusLogger struct { logger *logrus.Logger diff --git a/adapters/zap/zap.go b/adapters/zap/zap.go index 17c20d4..f9b3664 100644 --- a/adapters/zap/zap.go +++ b/adapters/zap/zap.go @@ -9,8 +9,10 @@ import ( "go.uber.org/zap/zapcore" ) -var _ logger.Logger = &ZapLogger{} -var _ logger.LogBuilder = &ZapLogBuilder{} +var ( + _ logger.Logger = &ZapLogger{} + _ logger.LogBuilder = &ZapLogBuilder{} +) type ZapLogger struct { Logger *zap.Logger diff --git a/adapters/zerolog/zerolog.go b/adapters/zerolog/zerolog.go index 401b60d..4d6f50e 100644 --- a/adapters/zerolog/zerolog.go +++ b/adapters/zerolog/zerolog.go @@ -8,8 +8,10 @@ import ( "go.arsenm.dev/logger" ) -var _ logger.Logger = &ZerologLogger{} -var _ logger.LogBuilder = &ZerologLogBuilder{} +var ( + _ logger.Logger = &ZerologLogger{} + _ logger.LogBuilder = &ZerologLogBuilder{} +) type ZerologLogger struct { logger zerolog.Logger diff --git a/logger_test.go b/logger_test.go index 504a24e..6213dbe 100644 --- a/logger_test.go +++ b/logger_test.go @@ -12,9 +12,11 @@ import ( "go.arsenm.dev/logger" ) -var buf = &bytes.Buffer{} -var jsonlog = logger.NewJSON(buf) -var prettylog = logger.NewPretty(buf) +var ( + buf = &bytes.Buffer{} + jsonlog = logger.NewJSON(buf) + prettylog = logger.NewPretty(buf) +) func TestJSON(t *testing.T) { t.Run("empty", func(t *testing.T) {