tailscale/net/netmon/interfaces_default_route_test.go

21 lines
444 B
Go
Raw Permalink Normal View History

// Copyright (c) Tailscale Inc & AUTHORS
// SPDX-License-Identifier: BSD-3-Clause
//go:build linux || (darwin && !ts_macext)
package netmon
import (
"testing"
)
func TestDefaultRouteInterface(t *testing.T) {
// tests /proc/net/route on the local system, cannot make an assertion about
// the correct interface name, but good as a sanity check.
v, err := DefaultRouteInterface()
if err != nil {
t.Fatal(err)
}
t.Logf("got %q", v)
}