### Question:
QueueManager { public void publishMessage(Message message) { messagePriorityMessageQueue.add(message); } QueueManager(int initialCapacity); void publishMessage(Message message); Message receiveMessage();  }### Answer:
@Test public void publishMessage() { var queueManager = new QueueManager(2); var testMessage = new Message("Test Message", 1); queueManager.publishMessage(testMessage); var recivedMessage = queueManager.receiveMessage(); assertEquals(testMessage, recivedMessage); }