aboutsummaryrefslogtreecommitdiff
path: root/pipeln_test.go
diff options
context:
space:
mode:
authorGrégoire Duchêne <gduchene@awhk.org>2022-10-02 14:52:02 +0100
committerGrégoire Duchêne <gduchene@awhk.org>2022-10-02 14:52:02 +0100
commit506fdadaa6fb06aa21d8b0c02aa8a6366337aa51 (patch)
tree3e19f309d424ce061a1fdc4e5d038c3a19c89930 /pipeln_test.go
parentea1798557f3c9b029d3703f4182a3e0a1134f5ce (diff)
Use signal values from syscallv1.0.3
There is no change in API or behavior.
Diffstat (limited to 'pipeln_test.go')
-rw-r--r--pipeln_test.go9
1 files changed, 4 insertions, 5 deletions
diff --git a/pipeln_test.go b/pipeln_test.go
index dcbeb22..3b822b2 100644
--- a/pipeln_test.go
+++ b/pipeln_test.go
@@ -5,10 +5,9 @@ package pipeln
import (
"context"
"net/http"
+ "syscall"
"testing"
- "golang.org/x/sys/unix"
-
"go.awhk.org/core"
)
@@ -33,18 +32,18 @@ func Test(s *testing.T) {
t.Run("Address Mismatch", func(t *core.T) {
_, err := client.Get("http://other-test/endpoint")
- t.AssertErrorIs(unix.EINVAL, err)
+ t.AssertErrorIs(syscall.EINVAL, err)
})
srv.Shutdown(context.Background())
t.Run("Remote Connection Closed", func(t *core.T) {
_, err := client.Get("http://test/endpoint")
- t.AssertErrorIs(unix.ECONNREFUSED, err)
+ t.AssertErrorIs(syscall.ECONNREFUSED, err)
})
t.Run("Already-closed Listener", func(t *core.T) {
srv = http.Server{Handler: mux}
- t.AssertErrorIs(unix.EINVAL, srv.Serve(ln))
+ t.AssertErrorIs(syscall.EINVAL, srv.Serve(ln))
})
}