File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
util/src/test/java/io/kubernetes/client Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change 28
28
import io .kubernetes .client .openapi .models .V1APIVersions ;
29
29
import io .kubernetes .client .util .ClientBuilder ;
30
30
import java .io .IOException ;
31
+ import java .util .ArrayList ;
31
32
import java .util .Arrays ;
32
33
import java .util .List ;
33
34
import java .util .Set ;
@@ -129,7 +130,9 @@ public void findAllShouldReturnAllApiResourceWhenApiResponseIsSuccess() {
129
130
new V1APIResource ()
130
131
.name ("second" )))))));
131
132
132
- Set <APIResource > apiResources = discovery .findAll (group , List .of (version ), version );
133
+ List <String > versions = new ArrayList <>();
134
+ versions .add (version );
135
+ Set <APIResource > apiResources = discovery .findAll (group , versions , version );
133
136
wireMockRule .verify (1 , getRequestedFor (urlPathEqualTo (path )));
134
137
assertEquals (2 , apiResources .size ());
135
138
}
@@ -148,7 +151,9 @@ public void findAllShouldReturnEmptyListWhenApiResponseIsNotSuccess() {
148
151
aResponse ()
149
152
.withStatus (503 )));
150
153
151
- Set <APIResource > apiResources = discovery .findAll (group , List .of (version ), version );
154
+ List <String > versions = new ArrayList <>();
155
+ versions .add (version );
156
+ Set <APIResource > apiResources = discovery .findAll (group , versions , version );
152
157
wireMockRule .verify (1 , getRequestedFor (urlPathEqualTo (path )));
153
158
assertEquals (0 , apiResources .size ());
154
159
}
You can’t perform that action at this time.
0 commit comments