Skip to content

Commit

Permalink
Add missing @Serviceconnection
Browse files Browse the repository at this point in the history
  • Loading branch information
quaff committed May 6, 2023
1 parent a474e54 commit 02f2c14
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,19 @@

package org.springframework.boot.docs.features.testing.testcontainers.atdevelopmenttime.importingcontainerdeclarations;

import org.springframework.boot.testcontainers.service.connection.ServiceConnection;
import org.testcontainers.containers.MongoDBContainer;
import org.testcontainers.containers.Neo4jContainer;
import org.testcontainers.junit.jupiter.Container;

public interface MyContainers {

@Container
@ServiceConnection
MongoDBContainer monogContainer = new MongoDBContainer("mongo:5.0");

@Container
@ServiceConnection
Neo4jContainer<?> neo4jContainer = new Neo4jContainer<>("neo4j:5");

}

0 comments on commit 02f2c14

Please sign in to comment.