Antilint
continuous-integration/drone/push Build is failing
Details
continuous-integration/drone/push Build is failing
Details
This commit is contained in:
parent
d8b2e87d89
commit
e17afe178f
|
@ -3,7 +3,6 @@ import os
|
||||||
import pwd
|
import pwd
|
||||||
import subprocess
|
import subprocess
|
||||||
import sys
|
import sys
|
||||||
from subprocess import PIPE
|
|
||||||
|
|
||||||
|
|
||||||
def cli():
|
def cli():
|
||||||
|
@ -14,10 +13,11 @@ def cli():
|
||||||
database: str — the name of the database to back up.
|
database: str — the name of the database to back up.
|
||||||
|
|
||||||
user: optional str — the name of the Linux user to use to connect to Postgres.
|
user: optional str — the name of the Linux user to use to connect to Postgres.
|
||||||
Sudo or SSH will be used to make this happen, if it's specified.
|
Sudo or SSH will be used to make this happen, if it's specified,
|
||||||
|
unless it's a local user that is already the current user.
|
||||||
|
|
||||||
host: optional str — if specified, the backup will be made using SSH (unless this host is the same as the one
|
host: optional str — if specified, the backup will be made using SSH
|
||||||
named)
|
(unless this host is the same as the one named)
|
||||||
"""
|
"""
|
||||||
request_info = json.load(sys.stdin)
|
request_info = json.load(sys.stdin)
|
||||||
assert isinstance(request_info, dict)
|
assert isinstance(request_info, dict)
|
||||||
|
@ -68,8 +68,8 @@ def cli():
|
||||||
)
|
)
|
||||||
output_of_dump = lz4_process.stdin
|
output_of_dump = lz4_process.stdin
|
||||||
|
|
||||||
# we MUST disable shell here otherwise the local side will do both the compression and decompression which would be
|
# we MUST disable shell here otherwise the local side will do both
|
||||||
# silly!
|
# the compression and decompression which would be silly!
|
||||||
subprocess.check_call(
|
subprocess.check_call(
|
||||||
command,
|
command,
|
||||||
stdin=subprocess.DEVNULL,
|
stdin=subprocess.DEVNULL,
|
||||||
|
|
|
@ -9,7 +9,8 @@ class TestPostgresHelper(TestCase):
|
||||||
if "TEST_POSTGRES" not in os.environ:
|
if "TEST_POSTGRES" not in os.environ:
|
||||||
self.skipTest(
|
self.skipTest(
|
||||||
"TEST_POSTGRES environment variable not set. "
|
"TEST_POSTGRES environment variable not set. "
|
||||||
"Should be set to a Postgres host, database, user combination, comma-separated."
|
"Should be set to a Postgres host, database,"
|
||||||
|
" user combination, comma-separated."
|
||||||
)
|
)
|
||||||
|
|
||||||
def test_helper_fails_on_bad_connection(self):
|
def test_helper_fails_on_bad_connection(self):
|
||||||
|
|
Loading…
Reference in New Issue