mirror of
https://github.com/moby/moby.git
synced 2026-01-11 18:51:37 +00:00
integration-cli: fix some unhandled errors
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
@@ -91,8 +91,8 @@ func (s *DockerAPISuite) TestPostContainersAttachContainerNotFound(c *testing.T)
|
||||
func (s *DockerAPISuite) TestGetContainersWsAttachContainerNotFound(c *testing.T) {
|
||||
ctx := testutil.GetContext(c)
|
||||
res, body, err := request.Get(ctx, "/containers/doesnotexist/attach/ws")
|
||||
assert.Equal(c, res.StatusCode, http.StatusNotFound)
|
||||
assert.NilError(c, err)
|
||||
assert.Equal(c, res.StatusCode, http.StatusNotFound)
|
||||
b, err := request.ReadBody(body)
|
||||
assert.NilError(c, err)
|
||||
expected := "No such container: doesnotexist"
|
||||
@@ -207,7 +207,7 @@ func (s *DockerAPISuite) TestPostContainersAttach(c *testing.T) {
|
||||
assert.NilError(c, err)
|
||||
|
||||
defer resp.Conn.Close()
|
||||
resp.Conn.SetReadDeadline(time.Now().Add(time.Second))
|
||||
assert.NilError(c, resp.Conn.SetReadDeadline(time.Now().Add(time.Second)))
|
||||
|
||||
_, err = resp.Conn.Write([]byte("success"))
|
||||
assert.NilError(c, err)
|
||||
|
||||
Reference in New Issue
Block a user