mirror of
https://github.com/slackhq/nebula.git
synced 2026-05-16 04:47:38 +02:00
lint
This commit is contained in:
@@ -4,15 +4,13 @@
|
|||||||
package e2e
|
package e2e
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"io"
|
"log/slog"
|
||||||
"net/netip"
|
"net/netip"
|
||||||
"os"
|
"os"
|
||||||
"strings"
|
"strings"
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"log/slog"
|
|
||||||
|
|
||||||
"dario.cat/mergo"
|
"dario.cat/mergo"
|
||||||
"github.com/google/gopacket"
|
"github.com/google/gopacket"
|
||||||
"github.com/google/gopacket/layers"
|
"github.com/google/gopacket/layers"
|
||||||
@@ -382,7 +380,7 @@ func getAddrs(ns []netip.Prefix) []netip.Addr {
|
|||||||
func NewTestLogger() *slog.Logger {
|
func NewTestLogger() *slog.Logger {
|
||||||
v := os.Getenv("TEST_LOGS")
|
v := os.Getenv("TEST_LOGS")
|
||||||
if v == "" {
|
if v == "" {
|
||||||
return slog.New(slog.NewTextHandler(io.Discard, nil))
|
return slog.New(slog.DiscardHandler)
|
||||||
}
|
}
|
||||||
|
|
||||||
level := slog.LevelInfo
|
level := slog.LevelInfo
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
package nebula
|
package nebula
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"io"
|
|
||||||
"log/slog"
|
"log/slog"
|
||||||
"testing"
|
"testing"
|
||||||
)
|
)
|
||||||
@@ -50,7 +49,7 @@ func v6WithTC(tc byte) []byte {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func TestApplyOuterECN(t *testing.T) {
|
func TestApplyOuterECN(t *testing.T) {
|
||||||
silent := slog.New(slog.NewTextHandler(io.Discard, nil))
|
silent := slog.New(slog.DiscardHandler)
|
||||||
hi := &HostInfo{}
|
hi := &HostInfo{}
|
||||||
|
|
||||||
// Build a v4 packet helper with a given inner ECN field.
|
// Build a v4 packet helper with a given inner ECN field.
|
||||||
|
|||||||
Reference in New Issue
Block a user