I have a lot of scenarios which are working with a docker testcontainer. Each scenario starts up the container and when the world is dropped, the container is also stopping. When a new world is created, a new container is created. This works fine, but it is slow. I'd appreciate if the container could be started like this:
fn main() {
let container = startContainer();
MyWorld::cucumber()
.fail_on_skipped()
.add_state(container) // don't nail me on this. Just here to see what I mean
.run_and_exit("tests/features/user/")
.await;
// Container gets stopped when main is exited.
}
When the world is then created, I'd need some way to access the container (e.g. for getting out the correct ports).
Hi,
I have a lot of scenarios which are working with a docker testcontainer. Each scenario starts up the container and when the world is dropped, the container is also stopping. When a new world is created, a new container is created. This works fine, but it is slow. I'd appreciate if the container could be started like this:
When the world is then created, I'd need some way to access the container (e.g. for getting out the correct ports).
What do you think about this?