@Test public void testPublishJsonObject() { JsonObject obj = new JsonObject(); obj.put(TestUtils.randomUnicodeString(100), TestUtils.randomUnicodeString(100)) .put(TestUtils.randomUnicodeString(100), TestUtils.randomInt()); testPublish( obj, (received) -> { assertEquals(obj, received); assertFalse(obj == received); // Make sure it's copied }); }
@Test public void testPublishJsonArray() { JsonArray arr = new JsonArray(); arr.add(TestUtils.randomUnicodeString(100)) .add(TestUtils.randomInt()) .add(TestUtils.randomBoolean()); testPublish( arr, (received) -> { assertEquals(arr, received); assertFalse(arr == received); // Make sure it's copied }); }
@Test public void testReplyInteger() { testReply(TestUtils.randomInt()); }
@Test public void testPublishInteger() { testPublish(TestUtils.randomInt()); }
@Test public void testSendInteger() { testSend(TestUtils.randomInt()); }