### Question:
AmqpProducer { public static void sendDeploymentRenegotiatedMessage(String applicationName, Deployment deployment) { ApplicationManagerMessage amMessage = MessageCreator.fromDeployment(applicationName, deployment, Dictionary.APPLICATION_STATUS_RENEGOTIATED); AmqpProducer.sendMessage(APPLLICATION_PATH + "." + applicationName + "." + DEPLOYMENT_PATH + "." + deployment.getId() + "." + Dictionary.APPLICATION_STATUS_RENEGOTIATED, amMessage, true); }  static void sendMessage(String topic, ApplicationManagerMessage message, boolean toLog); static void sendNewApplicationMessage(Application application); static void sendDeploymentSubmittedMessage(Application application); static void sendDeploymentNegotiatingMessage(String applicationName, Deployment deployment); static void sendDeploymentNegotiatedMessage(String applicationName, Deployment deployment); static void sendDeploymentContextualizingMessage(String applicationName, Deployment deployment); static void sendDeploymentContextualizedMessage(String applicationName, Deployment deployment); static void sendDeploymentDeployingMessage(String applicationName, Deployment deployment); static void sendDeploymentDeployedMessage(String applicationName, Deployment deployment); static void sendDeploymentDeletedMessage(String applicationName, Deployment deployment); static void sendDeploymentErrorMessage(String applicationName, Deployment deployment); static void sendVMDeployingMessage(String applicationName, Deployment deployment, VM vm); static void sendVMDeployedMessage(String applicationName, Deployment deployment, VM vm); static void sendVMDeletedMessage(String applicationName, Deployment deployment, VM vm); static void sendDeploymentRenegotiatingMessage(String applicationName, Deployment deployment); static void sendDeploymentRenegotiatedMessage(String applicationName, Deployment deployment); static final String APPLLICATION_PATH; static final String DEPLOYMENT_PATH; static final String VM_PATH; static final String DELETED; }### Answer:
@Test public void sendDeploymentRenegotiatedMessageTest() throws Exception { AmqpMessageReceiver receiver = new AmqpMessageReceiver(Configuration.amqpAddress, Configuration.amqpUsername, Configuration.amqpPassword, "APPLICATION.pepito.DEPLOYMENT.23.RENEGOTIATED", true); AmqpBasicListener listener = new AmqpBasicListener(); receiver.setMessageConsumer(listener); Deployment deployment = new Deployment(); deployment.setId(23); deployment.setStatus("DEPLOYING"); AmqpProducer.sendDeploymentRenegotiatedMessage("pepito", deployment); Thread.sleep(700l); assertEquals("APPLICATION.pepito.DEPLOYMENT.23.RENEGOTIATED", listener.getDestination()); ApplicationManagerMessage amMessageReceived = ModelConverter.jsonToApplicationManagerMessage(listener.getMessage()); assertEquals("pepito", amMessageReceived.getApplicationId()); assertEquals("23", amMessageReceived.getDeploymentId()); assertEquals("RENEGOTIATED", amMessageReceived.getStatus()); receiver.close(); }