Skip to content

Commit 8822b91

Browse files
authored
Move Qdrant tests to JUnit Jupiter (#10760)
1 parent 9e7aa3c commit 8822b91

File tree

2 files changed

+12
-5
lines changed

2 files changed

+12
-5
lines changed

modules/qdrant/build.gradle

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,17 @@ description = "Testcontainers :: Qdrant"
33
dependencies {
44
api project(':testcontainers')
55

6+
testRuntimeOnly 'org.junit.platform:junit-platform-launcher:1.11.0'
7+
8+
testImplementation 'org.junit.jupiter:junit-jupiter:5.13.4'
69
testImplementation 'org.assertj:assertj-core:3.27.4'
710
testImplementation 'io.qdrant:client:1.15.0'
811
testImplementation platform('io.grpc:grpc-bom:1.73.0')
912
testImplementation 'io.grpc:grpc-stub'
1013
testImplementation 'io.grpc:grpc-protobuf'
1114
testImplementation 'io.grpc:grpc-netty-shaded'
1215
}
16+
17+
test {
18+
useJUnitPlatform()
19+
}

modules/qdrant/src/test/java/org/testcontainers/qdrant/QdrantContainerTest.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import io.qdrant.client.QdrantClient;
44
import io.qdrant.client.QdrantGrpcClient;
55
import io.qdrant.client.grpc.QdrantOuterClass;
6-
import org.junit.Test;
6+
import org.junit.jupiter.api.Test;
77
import org.testcontainers.images.builder.Transferable;
88

99
import java.util.UUID;
@@ -12,10 +12,10 @@
1212
import static org.assertj.core.api.Assertions.assertThat;
1313
import static org.assertj.core.api.Assertions.assertThatThrownBy;
1414

15-
public class QdrantContainerTest {
15+
class QdrantContainerTest {
1616

1717
@Test
18-
public void shouldReturnVersion() throws ExecutionException, InterruptedException {
18+
void shouldReturnVersion() throws ExecutionException, InterruptedException {
1919
try (
2020
// qdrantContainer {
2121
QdrantContainer qdrant = new QdrantContainer("qdrant/qdrant:v1.7.4")
@@ -34,7 +34,7 @@ public void shouldReturnVersion() throws ExecutionException, InterruptedExceptio
3434
}
3535

3636
@Test
37-
public void shouldSetApiKey() throws ExecutionException, InterruptedException {
37+
void shouldSetApiKey() throws ExecutionException, InterruptedException {
3838
String apiKey = UUID.randomUUID().toString();
3939
try (QdrantContainer qdrant = new QdrantContainer("qdrant/qdrant:v1.7.4").withApiKey(apiKey)) {
4040
qdrant.start();
@@ -59,7 +59,7 @@ public void shouldSetApiKey() throws ExecutionException, InterruptedException {
5959
}
6060

6161
@Test
62-
public void shouldSetApiKeyUsingConfigFile() throws ExecutionException, InterruptedException {
62+
void shouldSetApiKeyUsingConfigFile() throws ExecutionException, InterruptedException {
6363
String apiKey = UUID.randomUUID().toString();
6464
String configFile = "service:\n api_key: " + apiKey;
6565
try (

0 commit comments

Comments
 (0)