test(plausible): psql -q in _register_site — -t does not suppress command tags
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
psql -tAc still prints INSERT/CREATE command tags (e.g. "INSERT 0 1"), so _register_site asserted out == site against "INSERT 0 1\nsite" and both event-tracking roundtrip tests failed on their very first run (build 237 — the custom tier had never executed before; install always failed earlier). -q suppresses the tags; verified against the recipe db container.
This commit is contained in:
@ -59,7 +59,7 @@ def _register_site(domain: str, site: str) -> None:
|
||||
f"SELECT domain FROM sites WHERE domain = '{site}';"
|
||||
)
|
||||
out = lifecycle.exec_in_app(
|
||||
domain, ["psql", "-U", "plausible", "-d", "plausible", "-tAc", sql], service="db"
|
||||
domain, ["psql", "-q", "-U", "plausible", "-d", "plausible", "-tAc", sql], service="db"
|
||||
).strip()
|
||||
assert out == site, f"site {site!r} not registered in postgres (got {out!r})"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user