Class UseExistingMongoDbClassExtension
- java.lang.Object
-
- org.sdase.commons.server.mongo.testing.UseExistingMongoDb
-
- org.sdase.commons.server.mongo.testing.UseExistingMongoDbClassExtension
-
- All Implemented Interfaces:
org.junit.jupiter.api.extension.AfterAllCallback
,org.junit.jupiter.api.extension.BeforeAllCallback
,org.junit.jupiter.api.extension.Extension
,MongoDb
,MongoDbClassExtension
public class UseExistingMongoDbClassExtension extends UseExistingMongoDb implements MongoDbClassExtension
JUnit Test extension for connecting to an existing MongoDB instance alongside the (integration) tests..- See Also:
UseExistingMongoDb
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.sdase.commons.server.mongo.testing.MongoDbClassExtension
MongoDbClassExtension.Builder
-
-
Field Summary
-
Fields inherited from interface org.sdase.commons.server.mongo.testing.MongoDb
OVERRIDE_MONGODB_CONNECTION_STRING_SYSTEM_PROPERTY_NAME
-
-
Constructor Summary
Constructors Constructor Description UseExistingMongoDbClassExtension(java.lang.String mongoDbConnectionString)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
afterAll(org.junit.jupiter.api.extension.ExtensionContext context)
void
beforeAll(org.junit.jupiter.api.extension.ExtensionContext context)
-
Methods inherited from class org.sdase.commons.server.mongo.testing.UseExistingMongoDb
createClient, getConnectionString, getDatabase, getHosts, getOptions, getPassword, getServerVersion, getUsername, logConnection
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.sdase.commons.server.mongo.testing.MongoDb
clearCollections, clearDatabase, createClient, getConnectionString, getDatabase, getHosts, getOptions, getPassword, getServerVersion, getUsername
-
-
-
-
Method Detail
-
beforeAll
public void beforeAll(org.junit.jupiter.api.extension.ExtensionContext context)
- Specified by:
beforeAll
in interfaceorg.junit.jupiter.api.extension.BeforeAllCallback
-
afterAll
public void afterAll(org.junit.jupiter.api.extension.ExtensionContext context)
- Specified by:
afterAll
in interfaceorg.junit.jupiter.api.extension.AfterAllCallback
-
-