jamesnetherton commented on a change in pull request #2642:
URL: https://github.com/apache/camel-quarkus/pull/2642#discussion_r636763132



##########
File path: 
integration-tests/mongodb/src/test/java/org/apache/camel/quarkus/component/mongodb/it/MongoDbTest.java
##########
@@ -16,22 +16,66 @@
  */
 package org.apache.camel.quarkus.component.mongodb.it;
 
+import java.sql.SQLException;
 import java.util.List;
 import java.util.Map;
+import java.util.concurrent.TimeUnit;
+import java.util.concurrent.atomic.AtomicInteger;
 
+import com.mongodb.client.MongoClient;
+import com.mongodb.client.MongoClients;
+import com.mongodb.client.MongoCollection;
+import com.mongodb.client.MongoDatabase;
 import io.quarkus.test.common.QuarkusTestResource;
 import io.quarkus.test.junit.QuarkusTest;
 import io.restassured.RestAssured;
 import io.restassured.http.ContentType;
 import io.restassured.path.json.JsonPath;
+import org.apache.camel.ServiceStatus;
+import org.apache.camel.util.CollectionHelper;
+import org.bson.Document;
+import org.junit.jupiter.api.AfterAll;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
 import org.junit.jupiter.params.ParameterizedTest;
 import org.junit.jupiter.params.provider.ValueSource;
 
+import static 
org.apache.camel.quarkus.component.mongodb.it.MongoDbRoute.COLLECTION_PERSISTENT_TAILING;
+import static 
org.apache.camel.quarkus.component.mongodb.it.MongoDbRoute.COLLECTION_STREAM_CHANGES;
+import static 
org.apache.camel.quarkus.component.mongodb.it.MongoDbRoute.COLLECTION_TAILING;
+import static org.awaitility.Awaitility.await;
+import static org.hamcrest.Matchers.is;
 import static org.junit.jupiter.api.Assertions.assertEquals;
 
 @QuarkusTest
 @QuarkusTestResource(MongoDbTestResource.class)
 class MongoDbTest {
+    public static final String MSG = "Hello Camel Quarkus Mongo DB";
+    public static final int CAP_NUMBER = 1000;
+
+    private static MongoClient mongoClient;
+
+    private static MongoDatabase db;
+
+    @BeforeAll
+    public static void setUp() throws SQLException {
+        final String mongoUrl = "mongodb://" + 
System.getProperty("quarkus.mongodb.hosts");
+
+        if (mongoUrl != null) {
+            mongoClient = MongoClients.create(mongoUrl);
+        }
+        org.junit.Assume.assumeTrue(mongoClient != null);

Review comment:
       In JUnit 5 it's `Assumptions.assumeTrue()`.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to