Skip to content

@Ignore is not honored on inner classes #9

Description

@theoamonteiro

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);
                }

            }
        }

    }

}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions