Skip to content

Commit

Permalink
Polish
Browse files Browse the repository at this point in the history
  • Loading branch information
eddumelendez committed Oct 30, 2024
1 parent c6923b0 commit c1c1ddc
Showing 1 changed file with 2 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,8 @@ class BookRepositoryBitnamiMongoDbShardedTest {

@DynamicPropertySource
static void mongoProperties(DynamicPropertyRegistry registry) {
registry.add("spring.data.mongodb.host", mongos::getHost);
registry.add("spring.data.mongodb.port", () -> mongos.getMappedPort(27017));
registry.add("spring.data.mongodb.username", () -> "root");
registry.add("spring.data.mongodb.password", () -> "test");
registry.add("spring.data.mongodb.database", () -> "test");
registry.add("spring.data.mongodb.authentication-database", () -> "admin");
registry.add("spring.data.mongodb.uri", () -> "mongodb://root:test@%s:%d/test?authSource=admin"
.formatted(mongos.getHost(), mongos.getMappedPort(27017)));
}

@Autowired
Expand Down

0 comments on commit c1c1ddc

Please sign in to comment.