### Question:
ClusterValidator implements Validator<WorkflowContext> { @Override public boolean validate(WorkflowContext context) throws HyscaleException { if (clusterValidationMap.containsKey(context.getAuthConfig())) { return clusterValidationMap.get(context.getAuthConfig()); } long startTime = System.currentTimeMillis(); boolean isClusterValid = false; logger.debug("Starting K8s cluster validation"); try { isClusterValid = deployer.authenticate(context.getAuthConfig()); clusterValidationMap.put(context.getAuthConfig(), isClusterValid); } catch (HyscaleException ex) { logger.error("Error while validating cluster", ex); clusterValidationMap.put(context.getAuthConfig(), false); throw ex; } finally { if (!isClusterValid) { WorkflowLogger.persist(ValidatorActivity.CLUSTER_AUTHENTICATION_FAILED, LoggerTags.ERROR); if(WorkflowLogger.isDisabled()){ outputHandler.addErrorMessage(CommonErrorCode.FAILED_TO_CONNECT_TO_CLUSTER.getMessage()); } } } logger.debug("Is K8s cluster valid: {}. Time taken: {}", isClusterValid, System.currentTimeMillis() - startTime); return isClusterValid; }  @PostConstruct void init(); @Override boolean validate(WorkflowContext context);  }### Answer:
@Test void testValidate() { try { assertFalse(clusterValidator.validate(new WorkflowContextBuilder(null).get())); } catch (HyscaleException e) { fail(e); } }