Skip to content

Commit

Permalink
update test for labels/annotations as key-value lists
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewazores committed Feb 29, 2024
1 parent 1eb7756 commit 512a0f3
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions src/test/java/itest/CustomTargetsTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
package itest;

import java.net.UnknownHostException;
import java.util.List;
import java.util.Map;
import java.util.UUID;
import java.util.concurrent.CountDownLatch;
Expand Down Expand Up @@ -224,16 +225,21 @@ void shouldBeAbleToDefineTarget()
MatcherAssert.assertThat(item.getString("jvmId"), Matchers.equalTo(itestJvmId));
MatcherAssert.assertThat(item.getString("alias"), Matchers.equalTo(alias));
MatcherAssert.assertThat(item.getString("connectUrl"), Matchers.equalTo(SELF_JMX_URL));
MatcherAssert.assertThat(item.getJsonObject("labels"), Matchers.equalTo(new JsonObject()));
MatcherAssert.assertThat(item.getJsonArray("labels"), Matchers.equalTo(new JsonArray()));
MatcherAssert.assertThat(
item.getJsonObject("annotations"),
Matchers.equalTo(
new JsonObject(
Map.of(
"platform",
Map.of(),
List.of(),
"cryostat",
Map.of("REALM", "Custom Targets")))));
List.of(
Map.of(
"key",
"REALM",
"value",
"Custom Targets"))))));
}

@Test
Expand Down

0 comments on commit 512a0f3

Please sign in to comment.