@Test
public void testValidateApprovalStatusForInvalidUser() {

	ResponseEntity<String> responseEntityExpected = ResponseEntity.status(HttpStatus.INTERNAL_SERVER_ERROR)
			.body("{\"errors\":[\"Access denied: No permission to access this certificate\"]}");
	UserDetails userDetail = getMockUser(true);
	userDetail.setUsername("testuser1");
	ReflectionTestUtils.setField(sSLCertificateService, "vaultAuthMethod", "ldap");
	String certType = "external";
	String certName = "certificatename.t-mobile.com";
	ResponseEntity<?> enrollResponse = sSLCertificateService
			.validateApprovalStatusAndGetCertificateDetails(certName, certType, null);
	assertEquals(HttpStatus.INTERNAL_SERVER_ERROR, enrollResponse.getStatusCode());
	assertEquals(responseEntityExpected, enrollResponse);
}