@Override
    public boolean isInStates(Set<String> statesFilter, long committedOffset) {
        return statesFilter.contains(state.toLowerCaseString());
    }
@Test
    public void testIsInStates() {
        ClassicGroup group = new ClassicGroup(new LogContext(), "groupId", EMPTY, Time.SYSTEM, mock(GroupCoordinatorMetricsShard.class));
        assertTrue(group.isInStates(Collections.singleton("empty"), 0));

        group.transitionTo(PREPARING_REBALANCE);
        assertTrue(group.isInStates(Collections.singleton("preparingrebalance"), 0));
        assertFalse(group.isInStates(Collections.singleton("PreparingRebalance"), 0));


        group.transitionTo(COMPLETING_REBALANCE);
        assertTrue(group.isInStates(new HashSet<>(Collections.singletonList("completingrebalance")), 0));

        group.transitionTo(STABLE);
        assertTrue(group.isInStates(Collections.singleton("stable"), 0));
        assertFalse(group.isInStates(Collections.singleton("empty"), 0));

        group.transitionTo(DEAD);
        assertTrue(group.isInStates(new HashSet<>(Arrays.asList("dead", " ")), 0));
    }