Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Junit 5 support for @Nested tests #458

Closed
djwoodward opened this issue Sep 15, 2017 · 1 comment
Closed

Junit 5 support for @Nested tests #458

djwoodward opened this issue Sep 15, 2017 · 1 comment
Assignees
Labels

Comments

@djwoodward
Copy link

@djwoodward djwoodward commented Sep 15, 2017

  • Version of JMockit that was used:
    1.34
  • Description of the problem:
    Running tests with @Nested test classes fail in some cases.
  1. Assertion error is thrown:
java.lang.AssertionError
	at mockit.integration.junit5.JMockitExtension.afterAll(JMockitExtension.java:190)
  1. @Tested with @Injectible fails
@RunWith(JUnitPlatform.class)
public class NestedTestTest {
    @Nested
    public class InnerTests {
        @Test
        public void innerTest1() {
            assertTrue(true);
        }
        @Test
        public void innerTest2() {
            assertTrue(true);
        }
    }

    @Test
    public void outerTest() {
        assertTrue(true);
    }
}
@rliesenfeld rliesenfeld self-assigned this Sep 16, 2017
@djwoodward

This comment has been minimized.

Copy link
Author

@djwoodward djwoodward commented Sep 16, 2017

Fantastic. Thanks for the quick fix.

@jmockit jmockit locked and limited conversation to collaborators Oct 11, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
2 participants
You can’t perform that action at this time.