File: vsock_others_test.go

package info (click to toggle)
golang-github-mdlayher-vsock 0.0~git20210303.10d5918-2
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 204 kB
  • sloc: makefile: 3
file content (24 lines) | stat: -rw-r--r-- 499 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
//+build !linux

package vsock

import "testing"

func TestUnimplemented(t *testing.T) {
	want := errUnimplemented

	if _, got := ContextID(); want != got {
		t.Fatalf("unexpected error from ContextID:\n- want: %v\n-  got: %v",
			want, got)
	}

	if _, got := listen(0, 0); want != got {
		t.Fatalf("unexpected error from listen:\n- want: %v\n-  got: %v",
			want, got)
	}

	if _, got := dial(0, 0); want != got {
		t.Fatalf("unexpected error from dial:\n- want: %v\n-  got: %v",
			want, got)
	}
}