Class HelloMongoDBContainerIT
java.lang.Object
info.ejava.examples.svc.docker.hello.HelloMongoDBContainerIT
@SpringBootTest(classes={info.ejava.examples.svc.docker.hello.DockerComposeHelloApp.class,ClientTestConfiguration.class},
webEnvironment=RANDOM_PORT)
@ActiveProfiles({"test","containerdb"})
class HelloMongoDBContainerIT
extends Object
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate org.springframework.web.client.RestTemplateprivate Stringprivate org.springframework.web.util.UriComponentsBuilderprivate com.mongodb.client.MongoClient(package private) org.springframework.boot.autoconfigure.mongo.PropertiesMongoConnectionDetails -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) void(package private) voidinit(int port) (package private) void
-
Field Details
-
expectedMongoUrl
-
mongoClient
@Autowired private com.mongodb.client.MongoClient mongoClient -
mongoProperties
@Autowired org.springframework.boot.autoconfigure.mongo.PropertiesMongoConnectionDetails mongoProperties -
anonymousUser
@Autowired private org.springframework.web.client.RestTemplate anonymousUser -
helloDBUrl
private org.springframework.web.util.UriComponentsBuilder helloDBUrl
-
-
Constructor Details
-
HelloMongoDBContainerIT
HelloMongoDBContainerIT()
-
-
Method Details
-
init
@BeforeEach void init(@LocalServerPort int port) -
can_get_connection
@Test void can_get_connection() -
server_can_get_mongo_connection
@Test void server_can_get_mongo_connection()
-