remove forgotten legacy part, adjust doc

This commit is contained in:
Sergei Shitikov
2025-02-16 18:17:09 +01:00
parent cb4dc2aff0
commit 26e9a672fd
2 changed files with 5 additions and 11 deletions
+5 -1
View File
@@ -43,6 +43,7 @@ use Testcontainers\Wait\WaitForExec;
use Testcontainers\Wait\WaitForLog;
use Testcontainers\Wait\WaitForHttp;
use Testcontainers\Wait\WaitForHealthCheck;
use Testcontainers\Wait\WaitForHostPort;
$container = new GenericContainer('nginx:alpine');
@@ -58,7 +59,10 @@ $container->withWait(new WaitForLog('Ready to accept connections'));
// Wait for an http request to succeed
$container->withWait(WaitForHttp::make($port, $method = 'GET', $path = '/'));
$container->withWait(new WaitForHttp($port, $method = 'GET', $path = '/'));
// Wait for all bound ports to be open
$container->withWait(new WaitForHostPort());
// Wait until the docker heartcheck is green
$container->withWait(new WaitForHealthCheck());