@Test(expected = org.apache.ambari.server.controller.spi.SystemException.class)
  public void testDeleteResources() throws Exception {
    AmbariManagementController managementController = createMock(AmbariManagementController.class);

    ResourceProvider provider = new HostKerberosIdentityResourceProvider(managementController);

    AbstractResourceProviderTest.TestObserver observer = new AbstractResourceProviderTest.TestObserver();

    ((ObservableResourceProvider) provider).addObserver(observer);

    Predicate predicate = new PredicateBuilder()
        .property(HostKerberosIdentityResourceProvider.KERBEROS_IDENTITY_CLUSTER_NAME_PROPERTY_ID)
        .equals("Cluster100")
        .and()
        .property(HostKerberosIdentityResourceProvider.KERBEROS_IDENTITY_HOST_NAME_PROPERTY_ID)
        .equals("Host100")
        .and()
        .property(HostKerberosIdentityResourceProvider.KERBEROS_IDENTITY_PRINCIPAL_NAME_PROPERTY_ID)
        .equals("principal@REALM").toPredicate();

    provider.deleteResources(new RequestImpl(null, null, null, null), predicate);
  }
Tests for the host Kerberos identity resource provider.
ambari-server/src/test/java/org/apache/ambari/server/controller/internal/HostKerberosIdentityResourceProviderTest.java