@@ -10,7 +10,6 @@ import (
1010 "strings"
1111 "testing"
1212
13- "github.com/docker/docker/api/types"
1413 "github.com/docker/docker/api/types/events"
1514 "github.com/docker/docker/api/types/filters"
1615 "github.com/docker/docker/errdefs"
@@ -20,17 +19,17 @@ import (
2019
2120func TestEventsErrorInOptions (t * testing.T ) {
2221 errorCases := []struct {
23- options types. EventsOptions
22+ options events. ListOptions
2423 expectedError string
2524 }{
2625 {
27- options : types. EventsOptions {
26+ options : events. ListOptions {
2827 Since : "2006-01-02TZ" ,
2928 },
3029 expectedError : `parsing time "2006-01-02TZ"` ,
3130 },
3231 {
33- options : types. EventsOptions {
32+ options : events. ListOptions {
3433 Until : "2006-01-02TZ" ,
3534 },
3635 expectedError : `parsing time "2006-01-02TZ"` ,
@@ -52,7 +51,7 @@ func TestEventsErrorFromServer(t *testing.T) {
5251 client := & Client {
5352 client : newMockClient (errorMock (http .StatusInternalServerError , "Server error" )),
5453 }
55- _ , errs := client .Events (context .Background (), types. EventsOptions {})
54+ _ , errs := client .Events (context .Background (), events. ListOptions {})
5655 err := <- errs
5756 assert .Check (t , is .ErrorType (err , errdefs .IsSystem ))
5857}
@@ -64,13 +63,13 @@ func TestEvents(t *testing.T) {
6463 expectedFiltersJSON := fmt .Sprintf (`{"type":{"%s":true}}` , events .ContainerEventType )
6564
6665 eventsCases := []struct {
67- options types. EventsOptions
66+ options events. ListOptions
6867 events []events.Message
6968 expectedEvents map [string ]bool
7069 expectedQueryParams map [string ]string
7170 }{
7271 {
73- options : types. EventsOptions {
72+ options : events. ListOptions {
7473 Filters : fltrs ,
7574 },
7675 expectedQueryParams : map [string ]string {
@@ -80,7 +79,7 @@ func TestEvents(t *testing.T) {
8079 expectedEvents : make (map [string ]bool ),
8180 },
8281 {
83- options : types. EventsOptions {
82+ options : events. ListOptions {
8483 Filters : fltrs ,
8584 },
8685 expectedQueryParams : map [string ]string {
0 commit comments