Created
March 18, 2016 12:57
-
-
Save nipafx/08a70cd2b6b94ab8b41d to your computer and use it in GitHub Desktop.
Running JUnit 5 tests with JUnit 4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.codefx.demo.junit5; | |
import org.junit.gen5.api.Test; | |
import org.junit.gen5.junit4.runner.JUnit5; | |
import org.junit.runner.RunWith; | |
/** | |
* Typical "Hello World"; runs as a JUnit 4 test. | |
*/ | |
@RunWith(JUnit5.class) | |
public class HelloWorldSelfContained { | |
@Test | |
void helloJUnit5() { | |
System.out.println("Hello, JUnit 5."); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment