@Test
public void testPolicyHeadingValidation() throws IOException {

    PolicyValidation validation = new PolicyValidation();
    PolicyRestAdapter policyData = new PolicyRestAdapter();
    String responseString = validation.validatePolicy(policyData).toString();
    assertThat(responseString).contains("PolicyName Should not be empty");
    policyData.setPolicyName("%%%~~~%%%");
    responseString = validation.validatePolicy(policyData).toString();
    assertThat(responseString).contains("The Value in Required Field will allow only '{0-9}, {a-z}, {A-Z}");
    policyData.setPolicyName("ALegalPolicyName");
    policyData.setPolicyDescription("@CreatedBy:");
    responseString = validation.validatePolicy(policyData).toString();
    assertThat(responseString)
                    .contains("The value in the description shouldn't contain @CreatedBy: or @ModifiedBy:");
    policyData.setPolicyDescription("@CreatedBy:");
    policyData.setPolicyDescription("A Legal Description");
    responseString = validation.validatePolicy(policyData).toString();
    assertThat(responseString)
                    .doesNotContain("The value in the description shouldn't contain @CreatedBy: or @ModifiedBy:");
}