CustomerCustomerEntityToCreate customer = (CustomerCustomerEntityToCreate) testObjects.get("customerRef");
MessageProcessor flow = lookupFlowConstruct("get-customer");
MuleEvent response = flow.process(getTestEvent(testObjects));
CustomerCustomerEntity createdCustomer = (CustomerCustomerEntity) response.getMessage().getPayload();
assertTrue(createdCustomer.getCustomer_id() == customerId);
assertTrue(createdCustomer.getEmail().equals(customer.getEmail()));
assertTrue(createdCustomer.getFirstname().equals(customer.getFirstname()));
assertTrue(createdCustomer.getLastname().equals(customer.getLastname()));
}
catch (Exception e) {
e.printStackTrace();
fail();
}