diff --git a/src/ServerManager.php b/src/ServerManager.php index 4e406fd9..4e1a4aab 100644 --- a/src/ServerManager.php +++ b/src/ServerManager.php @@ -91,4 +91,14 @@ public function http(): HttpServer default => new NullableHttpServer(), }; } + + /** + * Registers the HTTP server to use for browser tests. Call once from your + * test bootstrap (e.g. setUpBeforeClass) before the first visit(). When + * unset, the manager falls back to Laravel detection / NullableHttpServer. + */ + public function setHttp(HttpServer $http): void + { + $this->http = $http; + } }