### Question:
KafkaConnectContentValidator implements ContentValidator { @Override public void validate(ValidityLevel level, ContentHandle artifactContent) throws InvalidContentException { if (level == ValidityLevel.SYNTAX_ONLY || level == ValidityLevel.FULL) { try { JsonNode jsonNode = mapper.readTree(artifactContent.content()); jsonConverter.asConnectSchema(jsonNode); } catch (Exception e) { throw new InvalidContentException("Syntax violation for Kafka Connect Schema artifact.", e); } } } KafkaConnectContentValidator(); @Override void validate(ValidityLevel level, ContentHandle artifactContent);  }### Answer:
@Test public void testValidSyntax() throws Exception { ContentHandle content = resourceToContentHandle("kconnect-valid.json"); KafkaConnectContentValidator validator = new KafkaConnectContentValidator(); validator.validate(ValidityLevel.SYNTAX_ONLY, content); }
@Test public void testInvalidSyntax() throws Exception { ContentHandle content = resourceToContentHandle("kconnect-invalid.json"); KafkaConnectContentValidator validator = new KafkaConnectContentValidator(); Assertions.assertThrows(InvalidContentException.class, () -> { validator.validate(ValidityLevel.SYNTAX_ONLY, content); }); }