diff --git a/test/io/test_io.py b/test/io/test_io.py index 977ab7acb..798a331b0 100644 --- a/test/io/test_io.py +++ b/test/io/test_io.py @@ -2169,12 +2169,10 @@ def test_vary_default_header_set(defaultenv): def test_positive_pool_metric(defaultenv): "When a network failure is caused on the pg connection, pgrst_db_pool_available stays positive" - with run_pgproxy(defaultenv, proxy_timeout="10ms") as pgproxyhost: + with run_pgproxy(defaultenv, proxy_timeout="1ms") as pgproxyhost: env = {**defaultenv, "PGHOST": pgproxyhost} - with run(env=env, wait_for=None) as postgrest: - time.sleep(3) - + with run(env=env, wait_for=Admin.live) as postgrest: response = postgrest.admin.get("/metrics", timeout=1) assert response.status_code == 200