summaryrefslogtreecommitdiff
path: root/client/network_inspect_test.go
diff options
context:
space:
mode:
authorKirill Kolyshkin <kolyshkin@users.noreply.github.com>2019-10-17 11:38:00 -0700
committerGitHub <noreply@github.com>2019-10-17 11:38:00 -0700
commit0a96ee7ff8474c5d62eeded9d54adff7741a32e0 (patch)
tree58ca38bfe6c11389e634e4fae9f63e130da0a360 /client/network_inspect_test.go
parentf681590a2533829b88850b7e605a000cb538f102 (diff)
parentde10c7d0136dc054abdb40ca624211c04334bdc0 (diff)
downloaddocker-0a96ee7ff8474c5d62eeded9d54adff7741a32e0.tar.gz
Merge pull request #40080 from thaJeztah/client_string_matching
client: reduce string-matching in tests
Diffstat (limited to 'client/network_inspect_test.go')
-rw-r--r--client/network_inspect_test.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/client/network_inspect_test.go b/client/network_inspect_test.go
index e804d8dc22..24e732de86 100644
--- a/client/network_inspect_test.go
+++ b/client/network_inspect_test.go
@@ -12,6 +12,7 @@ import (
"github.com/docker/docker/api/types"
"github.com/docker/docker/api/types/network"
+ "github.com/docker/docker/errdefs"
"github.com/pkg/errors"
"gotest.tools/assert"
is "gotest.tools/assert/cmp"
@@ -23,7 +24,9 @@ func TestNetworkInspectError(t *testing.T) {
}
_, err := client.NetworkInspect(context.Background(), "nothing", types.NetworkInspectOptions{})
- assert.Check(t, is.Error(err, "Error response from daemon: Server error"))
+ if !errdefs.IsSystem(err) {
+ t.Fatalf("expected a Server Error, got %[1]T: %[1]v", err)
+ }
}
func TestNetworkInspectNotFoundError(t *testing.T) {