package Ġcom . github . o jac que mart . realtime Ċ Ċ import Ġio . quarkus . test . common . Qu ark us Test Resource Lifecycle Manager Ċ import Ġio . small ry e . reactive . messaging . connectors . InMemory Connector Ċ import Ġorg . test containers . containers . MongoDB Container Ċ Ċ class ĠReal time Db Test Life Cycle Manager Ġ: ĠQu ark us Test Resource Lifecycle Manager Ġ{ ĊĊĠ Ġval Ġmongodb Ġ= ĠMongoDB Container (" mongo : latest ") ĊĠĠĠ Ġ. with Ex posed Ports ( 2 7 _ 0 1 7 ) ĊĊĠ Ġoverride Ġfun Ġstart (): ĠMap < String , ĠString > Ġ{ ĊĠĠĠ Ġmongodb . start () ĊĊĠĠĠ Ġreturn Ġmap Of ( ĊĠĠĠĠĠ Ġ" quarkus . mongodb . connection - string " Ġto Ġ" mongodb ://${ mongodb . container IpAddress }:${ mongodb . first Mapped Port }", ĊĠĠĠ Ġ) Ġ+ ĊĠĠĠĠĠ ĠIn Memory Connector . switch Incoming Channels To InMemory (" r tdb ") Ġ+ ĊĠĠĠĠĠ ĠIn Memory Connector . switch Outgoing Channels To InMemory (" db - data ") ĊĠ Ġ} ĊĊĠ Ġoverride Ġfun Ġstop () Ġ{ ĊĠĠĠ Ġmongodb . stop () ĊĠĠĠ ĠIn Memory Connector . clear (); ĊĠ Ġ} Ċ Ċ } Ċ