### Question:
TokenCertificateService { public void markAuthCertForDeletion(String hash) throws SignCertificateNotSupportedException, ActionNotPossibleException, GlobalConfOutdatedException, InvalidCertificateException, KeyNotFoundException, CertificateNotFoundException { try { unregisterAuthCertAndMarkForDeletion(hash, true); } catch (ManagementRequestSendingFailedException e) { throw new RuntimeException("Management request failed", e); } } @Autowired @SuppressWarnings("checkstyle:ParameterNumber")  TokenCertificateService(SignerProxyFacade signerProxyFacade, ClientService clientService,
            CertificateAuthorityService certificateAuthorityService, KeyService keyService, DnFieldHelper dnFieldHelper,
            GlobalConfService globalConfService, GlobalConfFacade globalConfFacade, ClientRepository clientRepository,
            ManagementRequestSenderService managementRequestSenderService, ServerConfService serverConfService,
            PossibleActionsRuleEngine possibleActionsRuleEngine, TokenService tokenService,
            SecurityHelper securityHelper, AuditDataHelper auditDataHelper,
            AuditEventHelper auditEventHelper); GeneratedCertRequestInfo generateCertRequest(String keyId, ClientId memberId, KeyUsageInfo keyUsage,
            String caName, Map<String, String> subjectFieldValues, CertificateRequestFormat format); GeneratedCertRequestInfo regenerateCertRequest(String keyId, String csrId, CertificateRequestFormat format); CertificateInfo getCertificateInfo(String hash); CertificateInfo importCertificateFromToken(String hash); void activateCertificate(String hash); void deactivateCertificate(String hash); CertificateInfo importCertificate(byte[] certificateBytes); boolean isAuthCertBytes(byte[] certificateBytes); void registerAuthCert(String hash, String securityServerAddress); void unregisterAuthCert(String hash); void markAuthCertForDeletion(String hash); EnumSet<PossibleActionEnum> getPossibleActionsForCertificate(String hash); EnumSet<PossibleActionEnum> getPossibleActionsForCsr(
            String csrId); void deleteCertificates(List<CertificateInfo> certificateInfos); void deleteCertificate(String hash); String getKeyIdForCertificateHash(String hash); void deleteCsr(String csrId);  }### Answer:
@Test public void markAuthCertForDeletion() throws Exception { doAnswer(answer -> authCert).when(signerProxyFacade).getCertForHash(any()); try { tokenCertificateService.markAuthCertForDeletion(MOCK_AUTH_CERTIFICATE_HASH); } catch (Exception e) { fail("Should not fail"); } }