private void testCluster2(HelixManager helixManager, DataNodeConfigSource dataNodeConfigSource){
    MockHelixAdmin admin =  (MockHelixAdmin)helixManager.getClusterManagmentTool();
    // Add 3 instances to cluster
    addInstancesToCluster(helixManager, ClusterMapUtils.getInstanceName("localhost_1", PORT),
        ClusterMapUtils.getInstanceName("localhost_2", PORT), ClusterMapUtils.getInstanceName("localhost_3", PORT));

    // Bring down instance2
    admin.bringInstanceDown(ClusterMapUtils.getInstanceName("localhost_2", PORT));

    // Add a resourceName to cluster with partition on localhost_1 and localhost_2 and localhost_3
    IdealState idealState = new IdealState("resource1");
    idealState.setPreferenceList("partition1", Arrays.asList(ClusterMapUtils
        .getInstanceName("localhost_1", PORT), ClusterMapUtils.getInstanceName("localhost_2", PORT),
        ClusterMapUtils.getInstanceName("localhost_3", PORT)));
    admin.addResource(CLUSTER_NAME, "resource1", idealState);

    // Add replicas to property store
    addReplicasToDisk(dataNodeConfigSource, "localhost_1", "disk1", "partition1");
    addReplicasToDisk(dataNodeConfigSource, "localhost_1", "disk2", "partition2");

    addReplicasToDisk(dataNodeConfigSource, "localhost_2", "disk1", "partition1");
    addReplicasToDisk(dataNodeConfigSource, "localhost_2", "disk2", "partition2");

    addReplicasToDisk(dataNodeConfigSource, "localhost_3", "disk1", "partition1");
    addReplicasToDisk(dataNodeConfigSource, "localhost_3", "disk2", "partition2");
  }
Case when instance is down but present in ideal state or external view
@param helixManager
@param dataNodeConfigSource
@return
ambry-clustermap/src/test/java/com/github/ambry/clustermap/PropertyStoreCleanUpTaskTest.java