Running Junit suite with Junit5 version in eclipse oxygen, throwing, "No Junit5 runner found er [message #1807697] |
Thu, 06 June 2019 11:14 |
Rahul Dave Messages: 4 Registered: June 2019 |
Junior Member |
|
|
Hello,
I am trying to run the Junit suite using Junit5 like mentioned below, but while running it through eclipse, I am getting error like "No Junit5 runner found". I have also mentioned the maven dependencies below -
Test Suite :
import org.junit.platform.runner.JUnitPlatform;
import org.junit.platform.suite.api.SelectClasses;
import org.junit.runner.RunWith;
@RunWith(JUnitPlatform.class)
@SelectClasses({TestDataPathOrder.class,TestDataMappingOrders.class})
public class TestPackage
{
}
Maven Dependencies:
<properties>
<junit.version>5.4.2</junit.version>
<junit.platform.version>1.4.2</junit.platform.version>
</properties>
<dependencies>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-engine</artifactId>
<version>${junit.version}</version>
</dependency>
<dependency>
<groupId>org.junit.vintage</groupId>
<artifactId>junit-vintage-engine</artifactId>
<version>${junit.version}</version>
</dependency>
<dependency>
<groupId>org.junit.platform</groupId>
<artifactId>junit-platform-launcher</artifactId>
<version>${junit.platform.version}</version>
</dependency>
<dependency>
<groupId>org.junit.platform</groupId>
<artifactId>junit-platform-runner</artifactId>
<version>${junit.platform.version}</version>
</dependency>
</dependencies>
On some threads, I found that this is the bug with eclipse(Bug 511183 and Bug 539000) and it will get resolved with eclipse oxygen 4.7.1.a but I have tried with Oxygen 4.7.3a, but still it is not working for me.
I had raised this on newcomer forum and their, I got to know that it would get fix with latest eclipse version (i.e. 2019-3). I tried to run the package on latest eclipse version i.e. 2019-3, but still had no luck. Again I asked this on that forum and got the below response -
"You've shown your maven dependencies but I don't really know how that actual sets up JDT's class path such that the launcher will find the right JUnit on the classpath. Perhaps it's better to ask on the JDT forum where folks are likely to have more expertise in such things."
I really didn't get it what does that mean, could anyone help me on this?
|
|
|
Powered by
FUDForum. Page generated in 0.03841 seconds