mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-08-01 21:23:51 -09:00
support/testing: test_postgresql.py: use assertRunNotOk()
Use the helper to simplify the test. Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
This commit is contained in:
@@ -180,8 +180,7 @@ class TestPostgreSQL(infra.basetest.BRTest):
|
||||
self.assertRunOk(cmd)
|
||||
|
||||
# Check the server is no longer ready.
|
||||
_, exit_code = self.emulator.run("pg_isready")
|
||||
self.assertNotEqual(exit_code, 0)
|
||||
self.assertRunNotOk("pg_isready")
|
||||
|
||||
# Restart the server.
|
||||
cmd = f"su - {self.db_admin} -c 'pg_ctl start -D {self.pgdata_dir}'"
|
||||
|
||||
Reference in New Issue
Block a user