This commit is contained in:
JackDoan
2026-05-11 14:04:23 -05:00
parent 6b6dcda486
commit 681f5ef5a6
2 changed files with 3 additions and 6 deletions

View File

@@ -4,15 +4,13 @@
package e2e
import (
"io"
"log/slog"
"net/netip"
"os"
"strings"
"testing"
"time"
"log/slog"
"dario.cat/mergo"
"github.com/google/gopacket"
"github.com/google/gopacket/layers"
@@ -382,7 +380,7 @@ func getAddrs(ns []netip.Prefix) []netip.Addr {
func NewTestLogger() *slog.Logger {
v := os.Getenv("TEST_LOGS")
if v == "" {
return slog.New(slog.NewTextHandler(io.Discard, nil))
return slog.New(slog.DiscardHandler)
}
level := slog.LevelInfo

View File

@@ -1,7 +1,6 @@
package nebula
import (
"io"
"log/slog"
"testing"
)
@@ -50,7 +49,7 @@ func v6WithTC(tc byte) []byte {
}
func TestApplyOuterECN(t *testing.T) {
silent := slog.New(slog.NewTextHandler(io.Discard, nil))
silent := slog.New(slog.DiscardHandler)
hi := &HostInfo{}
// Build a v4 packet helper with a given inner ECN field.