Skip to content

Commit

Permalink
test: test host IP and port is logged
Browse files Browse the repository at this point in the history
  • Loading branch information
develop7 committed Jul 30, 2024
1 parent 3d18a98 commit 367e826
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions test/io/test_io.py
Original file line number Diff line number Diff line change
Expand Up @@ -1244,6 +1244,15 @@ def test_log_postgrest_version(defaultenv):

assert "Starting PostgREST %s..." % version in output[0]

def test_log_postgrest_host_and_port(defaultenv):
"PostgREST should output the host and port it is bound to."

env = {**defaultenv}

with run(env=env, host="127.0.0.2", port=3000, no_startup_stdout=False) as postgrest:
output = postgrest.read_stdout(nlines=10)

assert "Listening on 127.0.0.2:3000" in output[3]

def test_succeed_w_role_having_superuser_settings(defaultenv):
"Should succeed when having superuser settings on the impersonated role"
Expand Down

0 comments on commit 367e826

Please # to comment.