@Test public void emtyUafMsg() { Dereg dereg = new Dereg(); String uafMsg = ""; DeregistrationRequest deregRequest = null; try { deregRequest = dereg.getDeregRequest(uafMsg); fail("Should be UafRequestMsgParseException"); } catch (UafRequestMsgParseException e) { assertNull(deregRequest); } }
public DeregistrationRequest getDeregRequest(String uafMsg) throws UafRequestMsgParseException { try { logger.info(" [UAF][2]Reg - getDeregRequest : " + uafMsg); return gson.fromJson(uafMsg, DeregistrationRequest[].class)[0]; } catch (Exception e) { throw new UafRequestMsgParseException(e); } }
Dereg { public DeregistrationRequest getDeregRequest(String uafMsg) throws UafRequestMsgParseException { try { logger.info(" [UAF][2]Reg - getDeregRequest : " + uafMsg); return gson.fromJson(uafMsg, DeregistrationRequest[].class)[0]; } catch (Exception e) { throw new UafRequestMsgParseException(e); } } }
Dereg { public DeregistrationRequest getDeregRequest(String uafMsg) throws UafRequestMsgParseException { try { logger.info(" [UAF][2]Reg - getDeregRequest : " + uafMsg); return gson.fromJson(uafMsg, DeregistrationRequest[].class)[0]; } catch (Exception e) { throw new UafRequestMsgParseException(e); } }  }
Dereg { public DeregistrationRequest getDeregRequest(String uafMsg) throws UafRequestMsgParseException { try { logger.info(" [UAF][2]Reg - getDeregRequest : " + uafMsg); return gson.fromJson(uafMsg, DeregistrationRequest[].class)[0]; } catch (Exception e) { throw new UafRequestMsgParseException(e); } }  String dereg(String uafMsg, String appFacetId); DeregistrationRequest getDeregRequest(String uafMsg); }
Dereg { public DeregistrationRequest getDeregRequest(String uafMsg) throws UafRequestMsgParseException { try { logger.info(" [UAF][2]Reg - getDeregRequest : " + uafMsg); return gson.fromJson(uafMsg, DeregistrationRequest[].class)[0]; } catch (Exception e) { throw new UafRequestMsgParseException(e); } }  String dereg(String uafMsg, String appFacetId); DeregistrationRequest getDeregRequest(String uafMsg);  }