Debian Codegraph @

debian/patches/0004-Skip-TestLinuxBindToDevice-when-failed-to-bind-devic.patch

raw
1 From: Shengjing Zhu <[email protected]>
2 Date: Thu, 22 Feb 2024 18:06:29 +0800
3 Subject: Skip TestLinuxBindToDevice when failed to bind device
4
5 === CONT TestLinuxBindToDevice
6 conn_linux_test.go:201: failed to bind to device: setsockopt: operation not permitted
7 --- FAIL: TestLinuxBindToDevice (0.00s)
8 ---
9 conn_linux_test.go | 2 +-
10 1 file changed, 1 insertion(+), 1 deletion(-)
11
12 diff --git a/conn_linux_test.go b/conn_linux_test.go
13 index aa39d62..7d0575f 100644
14 --- a/conn_linux_test.go
15 +++ b/conn_linux_test.go
16 @@ -198,7 +198,7 @@ func TestLinuxBindToDevice(t *testing.T) {
17 )
18
19 if err := c.SetsockoptString(unix.SOL_SOCKET, unix.SO_BINDTODEVICE, name); err != nil {
20 - t.Fatalf("failed to bind to device: %v", err)
21 + t.Skipf("failed to bind to device: %v", err)
22 }
23
24 gotName, err := c.GetsockoptString(unix.SOL_SOCKET, unix.SO_BINDTODEVICE)