Fix test setup.

This commit is contained in:
Olga Maciaszek-Sharma
2024-10-04 17:27:30 +02:00
parent 572b10a5bd
commit fb7abbdead
2 changed files with 15 additions and 5 deletions

View File

@@ -92,7 +92,17 @@
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit.platform</groupId>
<artifactId>junit-platform-suite-api</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit.platform</groupId>
<artifactId>junit-platform-suite-engine</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit.vintage</groupId>
<artifactId>junit-vintage-engine</artifactId>

View File

@@ -16,8 +16,8 @@
package org.springframework.cloud.netflix.eureka;
import org.junit.runner.RunWith;
import org.junit.runners.Suite;
import org.junit.platform.suite.api.SelectClasses;
import org.junit.platform.suite.api.Suite;
/**
* We need to use a suite cause we need to first run all the Eureka Servers, then close
@@ -26,8 +26,8 @@ import org.junit.runners.Suite;
* That means that when the new context starts we will fail cause the executor service is
* already shutdown.
*/
@RunWith(Suite.class)
@Suite.SuiteClasses({ EurekaClientTests.class, RestTemplateEurekaClientTests.class })
@SelectClasses({ EurekaClientTests.class, RestTemplateEurekaClientTests.class })
@Suite
public class EurekaClientSuite {
}