(t *testing.T)
| 33 | } |
| 34 | |
| 35 | func TestPickPort(t *testing.T) { |
| 36 | _, err := pickPort("127.0.0.1", 8000, 10000, true) |
| 37 | if err != nil { |
| 38 | t.Errorf("Could not bind to any port: %s", err) |
| 39 | } |
| 40 | _, err = pickPort("127.0.0.1", 8000, 8000, true) |
| 41 | if err == nil { |
| 42 | t.Errorf("Expected not to be able to bind to any port") |
| 43 | } |
| 44 | |
| 45 | } |
| 46 | |
| 47 | func fsEndpoint(s string) *filesystemEndpoint { |
| 48 | e, _ := newFilesystemEndpoint(s, []string{}) |
nothing calls this directly
no test coverage detected