@Test
public void testCreateUser() throws Exception {

  UserMessage msg = new UserMessage();
  msg.setUserName("test user");
  msg.setFunction(Function.CREATE);
  msg.setNewPassword("password");
  String s = controller.process(mapper.writeValueAsString(msg));
  assertNotNull(s);
  Response r = mapper.readValue(s, Response.class);
  Object[] response = r.getPayload();
  assertEquals(ResponseCode.SUCCESS, r.getResponseCode());
  assertNotNull(response);
  assertEquals(1, response.length);
  Map<?, ?> blah = (Map<?, ?>) response[0];
  Object id = blah.get("id");
  assertNotNull(id);
  this.userId = Long.parseLong(id.toString());
}