unix: test AF_VSOCK sockets on linux

Follow the implementation of the tests added in CL 354269 for darwin.

Change-Id: I00701227dfb26169a356d875ddb3737849d0bba0
Reviewed-on: https://go-review.googlesource.com/c/sys/+/356289
Trust: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Matt Layher <mdlayher@gmail.com>
This commit is contained in:
Tobias Klauser
2021-10-15 20:08:01 +00:00
committed by Tobias Klauser
parent 97ac67df71
commit 69063c4bb7
2 changed files with 80 additions and 2 deletions
+2 -2
View File
@@ -138,7 +138,7 @@ func TestSockaddrCtl_sockaddr(t *testing.T) {
}
}
func TestSockaddVM_sockaddr(t *testing.T) {
func TestSockaddrVM_sockaddr(t *testing.T) {
tests := []struct {
name string
sa *SockaddrVM
@@ -154,7 +154,7 @@ func TestSockaddVM_sockaddr(t *testing.T) {
},
},
{
name: "with CID and Port",
name: "with CID and port",
sa: &SockaddrVM{
CID: VMADDR_CID_HOST,
Port: VMADDR_PORT_ANY,