@Test public void testWithNoCertificateProvided() { assertThrows(NullPointerException.class, () -> validationService.validateCertificate(null)); CertificateToValidateDTO emptyDTO= new CertificateToValidateDTO(); assertThrows(NullPointerException.class, () -> validationService.validateCertificate(emptyDTO)); }
public CertificateReportsDTO validateCertificate(CertificateToValidateDTO certificateToValidate) { LOG.info("ValidateCertificate in process..."); CertificateValidator validator = initValidator(certificateToValidate); CertificateReports reports = validator.validate(); CertificateReportsDTO certificateReportsDTO = new CertificateReportsDTO(reports.getDiagnosticDataJaxb(), reports.getSimpleReportJaxb(), reports.getDetailedReportJaxb()); LOG.info("ValidateCertificate is finished"); return certificateReportsDTO; }
RemoteCertificateValidationService { public CertificateReportsDTO validateCertificate(CertificateToValidateDTO certificateToValidate) { LOG.info("ValidateCertificate in process..."); CertificateValidator validator = initValidator(certificateToValidate); CertificateReports reports = validator.validate(); CertificateReportsDTO certificateReportsDTO = new CertificateReportsDTO(reports.getDiagnosticDataJaxb(), reports.getSimpleReportJaxb(), reports.getDetailedReportJaxb()); LOG.info("ValidateCertificate is finished"); return certificateReportsDTO; } }
RemoteCertificateValidationService { public CertificateReportsDTO validateCertificate(CertificateToValidateDTO certificateToValidate) { LOG.info("ValidateCertificate in process..."); CertificateValidator validator = initValidator(certificateToValidate); CertificateReports reports = validator.validate(); CertificateReportsDTO certificateReportsDTO = new CertificateReportsDTO(reports.getDiagnosticDataJaxb(), reports.getSimpleReportJaxb(), reports.getDetailedReportJaxb()); LOG.info("ValidateCertificate is finished"); return certificateReportsDTO; }  }
RemoteCertificateValidationService { public CertificateReportsDTO validateCertificate(CertificateToValidateDTO certificateToValidate) { LOG.info("ValidateCertificate in process..."); CertificateValidator validator = initValidator(certificateToValidate); CertificateReports reports = validator.validate(); CertificateReportsDTO certificateReportsDTO = new CertificateReportsDTO(reports.getDiagnosticDataJaxb(), reports.getSimpleReportJaxb(), reports.getDetailedReportJaxb()); LOG.info("ValidateCertificate is finished"); return certificateReportsDTO; }  void setVerifier(CertificateVerifier verifier); CertificateReportsDTO validateCertificate(CertificateToValidateDTO certificateToValidate); }
RemoteCertificateValidationService { public CertificateReportsDTO validateCertificate(CertificateToValidateDTO certificateToValidate) { LOG.info("ValidateCertificate in process..."); CertificateValidator validator = initValidator(certificateToValidate); CertificateReports reports = validator.validate(); CertificateReportsDTO certificateReportsDTO = new CertificateReportsDTO(reports.getDiagnosticDataJaxb(), reports.getSimpleReportJaxb(), reports.getDetailedReportJaxb()); LOG.info("ValidateCertificate is finished"); return certificateReportsDTO; }  void setVerifier(CertificateVerifier verifier); CertificateReportsDTO validateCertificate(CertificateToValidateDTO certificateToValidate);  }