CoreComponents icon indicating copy to clipboard operation
CoreComponents copied to clipboard

@Ignore is not honored on inner classes

Open theoamonteiro opened this issue 9 years ago • 0 comments

I would like to annotate a whole inner class with @Ignore and dismiss all test cases from there

@RunWith(NestedRunner.class)
public class Tester {

    @Test
    public void test() {
        assertTrue(true);
    }

    public class Nested {

        @Test
        public void test() {
            assertTrue(true);
        }

        @Ignore
        public class Ignored {

            @Test
            public void test() {
                fail("Should be ignored");
            }

            public class InnerIgnored {

                @Test
                public void test() {
                    fail("Should be ignored");
                }

            }

        }

        public class NotIgnored {

            @Test
            public void test() {
                assertTrue(true);
            }

            public class InnerNotIgnored {

                @Test
                public void test() {
                    assertTrue(true);
                }

            }
        }

    }

}

theoamonteiro avatar Aug 31 '16 10:08 theoamonteiro