@Override
  public final NodeState getState() {
    try (LockResource lr = new LockResource(mStateLock)) {
      return mState;
    }
  }
@Test
  public void getState() {
    assertEquals(NodeState.STANDBY, mSelector.getStateUnsafe());
    assertEquals(NodeState.STANDBY, mSelector.getState());
    mSelector.setState(NodeState.PRIMARY);
    assertEquals(NodeState.PRIMARY, mSelector.getStateUnsafe());
    assertEquals(NodeState.PRIMARY, mSelector.getState());
    mSelector.setState(NodeState.STANDBY);
    assertEquals(NodeState.STANDBY, mSelector.getStateUnsafe());
    assertEquals(NodeState.STANDBY, mSelector.getState());
  }