mirror of
https://github.com/golang/go
synced 2024-11-18 00:04:43 -07:00
net: tolerate permission errors in interface tests
On our linux-arm64 builders, we're getting permission errors despite running as root. Detect those errors and skip the test. For #61414. Change-Id: I5d7c45789337bee3860b19335bbb9eb884c48986 Reviewed-on: https://go-review.googlesource.com/c/go/+/510737 Auto-Submit: Heschi Kreinick <heschi@google.com> Run-TryBot: Heschi Kreinick <heschi@google.com> Reviewed-by: Ian Lance Taylor <iant@google.com> TryBot-Result: Gopher Robot <gobot@golang.org>
This commit is contained in:
parent
cd6c4e0557
commit
8e1ec1cb93
@ -193,6 +193,9 @@ func TestInterfaceArrivalAndDepartureZoneCache(t *testing.T) {
|
||||
t.Skipf("test requires external command: %v", err)
|
||||
}
|
||||
if err := ti.setup(); err != nil {
|
||||
if e := err.Error(); strings.Contains(e, "Permission denied") {
|
||||
t.Skipf("permission denied, skipping test: %v", e)
|
||||
}
|
||||
t.Fatal(err)
|
||||
}
|
||||
defer ti.teardown()
|
||||
|
Loading…
Reference in New Issue
Block a user