@Test
public void testShouldSkipGroupMember() {

    long currentTime = System.currentTimeMillis();
    GroupMember member = new GroupMember();
    assertFalse(AuthzHelper.shouldSkipGroupMember(member, currentTime));
    member.setSystemDisabled(0);
    assertFalse(AuthzHelper.shouldSkipGroupMember(member, currentTime));
    member.setExpiration(Timestamp.fromMillis(currentTime + 10000));
    assertFalse(AuthzHelper.shouldSkipGroupMember(member, currentTime));
    member.setSystemDisabled(null);
    member.setExpiration(Timestamp.fromMillis(currentTime + 10000));
    assertFalse(AuthzHelper.shouldSkipGroupMember(member, currentTime));
    member.setSystemDisabled(1);
    member.setExpiration(null);
    assertTrue(AuthzHelper.shouldSkipGroupMember(member, currentTime));
    member.setSystemDisabled(1);
    member.setExpiration(Timestamp.fromMillis(currentTime - 10000));
    assertTrue(AuthzHelper.shouldSkipGroupMember(member, currentTime));
    member.setSystemDisabled(0);
    member.setExpiration(Timestamp.fromMillis(currentTime - 10000));
    assertTrue(AuthzHelper.shouldSkipGroupMember(member, currentTime));
    member.setSystemDisabled(null);
    member.setExpiration(Timestamp.fromMillis(currentTime - 10000));
    assertTrue(AuthzHelper.shouldSkipGroupMember(member, currentTime));
}