@Test
public void testDeletePublicKeyEntry() {

    
    TopLevelDomain dom1 = createTopLevelDomainObject("ServiceDelPubKeyDom1",
            "Test Domain1", "testOrg", adminUser);
    zms.postTopLevelDomain(mockDomRsrcCtx, auditRef, dom1);
    ServiceIdentity service = createServiceObject("ServiceDelPubKeyDom1",
            "Service1", "http://localhost", "/usr/bin/java", "root",
            "users", "host1");
    zms.putServiceIdentity(mockDomRsrcCtx, "ServiceDelPubKeyDom1", "Service1", auditRef, service);
    zms.deletePublicKeyEntry(mockDomRsrcCtx, "ServiceDelPubKeyDom1", "Service1", "1", auditRef);
    ServiceIdentity serviceRes = zms.getServiceIdentity(mockDomRsrcCtx, "ServiceDelPubKeyDom1", "Service1");
    List<PublicKeyEntry> keyList = serviceRes.getPublicKeys();
    boolean found = false;
    for (PublicKeyEntry entry : keyList) {
        if (entry.getId().equals("1")) {
            found = true;
            break;
        }
    }
    assertFalse(found);
    
    zms.deleteTopLevelDomain(mockDomRsrcCtx, "ServiceDelPubKeyDom1", auditRef);
}