testcontainers-node icon indicating copy to clipboard operation
testcontainers-node copied to clipboard

Default to HealthCheckWaitStrategy for containers with health checks defined

Open jalaziz opened this issue 2 years ago • 0 comments

Expected Behaviour

For containers or compose services with health checks defined, the default wait strategy should be the HealthCheckWaitStrategy.

This would be particularly useful for compose projects where many services can be defined and health checks can be defined directly in the compose config.

Actual Behaviour

The default wait strategy is the HostPortWaitStrategy which is not always applicable. While we can override the health check manually, it would be great if testcontainers could automatically use the best strategy.

Testcontainer Logs ...

Environment Information

  • Operating System: Ubuntu 22.04
  • Docker Version: 24.0.7
  • Node version: 18.18.2
  • Testcontainers version: 10.3.2

jalaziz avatar Dec 07 '23 18:12 jalaziz