@@ -11,7 +11,6 @@ import (
1111 "strings"
1212 "testing"
1313
14- "github.com/docker/docker/api/types"
1514 "github.com/docker/docker/api/types/swarm"
1615 "github.com/docker/docker/errdefs"
1716 "gotest.tools/v3/assert"
@@ -23,7 +22,7 @@ func TestServiceInspectError(t *testing.T) {
2322 client : newMockClient (errorMock (http .StatusInternalServerError , "Server error" )),
2423 }
2524
26- _ , _ , err := client .ServiceInspectWithRaw (context .Background (), "nothing" , types .ServiceInspectOptions {})
25+ _ , _ , err := client .ServiceInspectWithRaw (context .Background (), "nothing" , swarm .ServiceInspectOptions {})
2726 assert .Check (t , is .ErrorType (err , errdefs .IsSystem ))
2827}
2928
@@ -32,7 +31,7 @@ func TestServiceInspectServiceNotFound(t *testing.T) {
3231 client : newMockClient (errorMock (http .StatusNotFound , "Server error" )),
3332 }
3433
35- _ , _ , err := client .ServiceInspectWithRaw (context .Background (), "unknown" , types .ServiceInspectOptions {})
34+ _ , _ , err := client .ServiceInspectWithRaw (context .Background (), "unknown" , swarm .ServiceInspectOptions {})
3635 assert .Check (t , is .ErrorType (err , errdefs .IsNotFound ))
3736}
3837
@@ -42,11 +41,11 @@ func TestServiceInspectWithEmptyID(t *testing.T) {
4241 return nil , errors .New ("should not make request" )
4342 }),
4443 }
45- _ , _ , err := client .ServiceInspectWithRaw (context .Background (), "" , types .ServiceInspectOptions {})
44+ _ , _ , err := client .ServiceInspectWithRaw (context .Background (), "" , swarm .ServiceInspectOptions {})
4645 assert .Check (t , is .ErrorType (err , errdefs .IsInvalidParameter ))
4746 assert .Check (t , is .ErrorContains (err , "value is empty" ))
4847
49- _ , _ , err = client .ServiceInspectWithRaw (context .Background (), " " , types .ServiceInspectOptions {})
48+ _ , _ , err = client .ServiceInspectWithRaw (context .Background (), " " , swarm .ServiceInspectOptions {})
5049 assert .Check (t , is .ErrorType (err , errdefs .IsInvalidParameter ))
5150 assert .Check (t , is .ErrorContains (err , "value is empty" ))
5251}
@@ -71,7 +70,7 @@ func TestServiceInspect(t *testing.T) {
7170 }),
7271 }
7372
74- serviceInspect , _ , err := client .ServiceInspectWithRaw (context .Background (), "service_id" , types .ServiceInspectOptions {})
73+ serviceInspect , _ , err := client .ServiceInspectWithRaw (context .Background (), "service_id" , swarm .ServiceInspectOptions {})
7574 assert .NilError (t , err )
7675 assert .Check (t , is .Equal (serviceInspect .ID , "service_id" ))
7776}
0 commit comments