@Test
public void testOnRegisterCandidateLocal() {

    testLog.info("testOnRegisterCandidateLocal starting");
    ShardTestKit kit = new ShardTestKit(getSystem());
    TestActorRef<EntityOwnershipShard> shard = actorFactory.createTestActor(newLocalShardProps());
    ShardTestKit.waitUntilLeader(shard);
    YangInstanceIdentifier entityId = ENTITY_ID1;
    DOMEntity entity = new DOMEntity(ENTITY_TYPE, entityId);
    shard.tell(new RegisterCandidateLocal(entity), kit.getRef());
    kit.expectMsgClass(SuccessReply.class);
    verifyCommittedEntityCandidate(shard, ENTITY_TYPE, entityId, LOCAL_MEMBER_NAME);
    verifyOwner(shard, ENTITY_TYPE, entityId, LOCAL_MEMBER_NAME);
    testLog.info("testOnRegisterCandidateLocal ending");
}