@Test public void testExportConsent2XACMLPdfConsentFrom_Object_ConsentGenException() throws ConsentGenException { thrown.expect(ConsentGenException.class); Consent consent = mock(Consent.class); when(consentBuilderMock.buildConsent2XacmlPdfConsentFrom(consent)) .thenThrow( new ConsentGenException( "Error in export consent to cdar2")); sut.exportConsent2XacmlPdfConsentFrom(consent); }
@Override public String exportConsent2XacmlPdfConsentFrom(Consent consent) throws ConsentGenException { return consentBuilder.buildConsent2XacmlPdfConsentFrom(consent); }
ConsentExportServiceImpl implements ConsentExportService { @Override public String exportConsent2XacmlPdfConsentFrom(Consent consent) throws ConsentGenException { return consentBuilder.buildConsent2XacmlPdfConsentFrom(consent); } }
ConsentExportServiceImpl implements ConsentExportService { @Override public String exportConsent2XacmlPdfConsentFrom(Consent consent) throws ConsentGenException { return consentBuilder.buildConsent2XacmlPdfConsentFrom(consent); } ConsentExportServiceImpl(ConsentBuilder consentBuilder); }
ConsentExportServiceImpl implements ConsentExportService { @Override public String exportConsent2XacmlPdfConsentFrom(Consent consent) throws ConsentGenException { return consentBuilder.buildConsent2XacmlPdfConsentFrom(consent); } ConsentExportServiceImpl(ConsentBuilder consentBuilder); @Override String exportConsent2CDAR2(Long consentId); @Override String exportConsent2XACML(Long consentId); @Override String exportConsent2XACML(Consent consent); @Override String exportConsent2XacmlPdfConsentFrom(Consent consent); @Override String exportConsent2XacmlPdfConsentTo(Consent consent); }
ConsentExportServiceImpl implements ConsentExportService { @Override public String exportConsent2XacmlPdfConsentFrom(Consent consent) throws ConsentGenException { return consentBuilder.buildConsent2XacmlPdfConsentFrom(consent); } ConsentExportServiceImpl(ConsentBuilder consentBuilder); @Override String exportConsent2CDAR2(Long consentId); @Override String exportConsent2XACML(Long consentId); @Override String exportConsent2XACML(Consent consent); @Override String exportConsent2XacmlPdfConsentFrom(Consent consent); @Override String exportConsent2XacmlPdfConsentTo(Consent consent);  }