File tree 1 file changed +28
-0
lines changed
src/test/java/org/gitlab4j/api
1 file changed +28
-0
lines changed Original file line number Diff line number Diff line change 55
55
import org .gitlab4j .api .models .ProjectHook ;
56
56
import org .gitlab4j .api .models .ProjectUser ;
57
57
import org .gitlab4j .api .models .ProtectedBranch ;
58
+ import org .gitlab4j .api .models .Runner ;
59
+ import org .gitlab4j .api .models .RunnerDetail ;
58
60
import org .gitlab4j .api .models .Session ;
59
61
import org .gitlab4j .api .models .Snippet ;
60
62
import org .gitlab4j .api .models .SshKey ;
@@ -278,6 +280,32 @@ public void testProtectedBranch() {
278
280
}
279
281
}
280
282
283
+ @ Test
284
+ public void testRunnerDetail () {
285
+
286
+ try {
287
+ RunnerDetail runnerDetail = makeFakeApiCall (RunnerDetail .class , "runner-detail" );
288
+ assertTrue (compareJson (runnerDetail , "runner-detail" ));
289
+ } catch (Exception e ) {
290
+ e .printStackTrace ();
291
+ }
292
+ }
293
+
294
+ @ Test
295
+ public void testAllRunners () {
296
+
297
+ try {
298
+
299
+ InputStreamReader reader = new InputStreamReader (GitLabApi .class .getResourceAsStream ("all-runners.json" ));
300
+ ObjectMapper objectMapper = jacksonJson .getContext (null );
301
+ List <Runner > allRunners = objectMapper .readValue (reader , new TypeReference <List <Runner >>() {});
302
+ assertTrue (compareJson (allRunners , "all-runners" ));
303
+
304
+ } catch (Exception e ) {
305
+ e .printStackTrace ();
306
+ }
307
+ }
308
+
281
309
@ Test
282
310
public void testKey () {
283
311
You can’t perform that action at this time.
0 commit comments