diff --git a/online-tests/conftest.py b/online-tests/conftest.py index 550f722e..9f5aba0d 100644 --- a/online-tests/conftest.py +++ b/online-tests/conftest.py @@ -182,15 +182,15 @@ def cmfactory(request, gencreds, tmpdir, data, maildomain): @pytest.fixture -def remotelog(sshdomain): - return RemoteLog(sshdomain) +def remote(sshdomain): + return Remote(sshdomain) -class RemoteLog: +class Remote: def __init__(self, sshdomain): self.sshdomain = sshdomain - def iter(self, logcmd=""): + def iter_output(self, logcmd=""): getjournal = f"journalctl -f" if not logcmd else logcmd self.popen = subprocess.Popen( ["ssh", f"root@{self.sshdomain}", getjournal], diff --git a/online-tests/test_0_basic.py b/online-tests/test_0_basic.py index d3354d5c..a585d5e2 100644 --- a/online-tests/test_0_basic.py +++ b/online-tests/test_0_basic.py @@ -1,5 +1,5 @@ -def test_remotelog(remotelog, imap_or_smtp): - lineproducer = remotelog.iter(imap_or_smtp.logcmd) +def test_remote(remote, imap_or_smtp): + lineproducer = remote.iter_output(imap_or_smtp.logcmd) imap_or_smtp.connect() assert imap_or_smtp.name in next(lineproducer) diff --git a/online-tests/test_1_deltachat.py b/online-tests/test_1_deltachat.py index 8d1e7854..74dc2213 100644 --- a/online-tests/test_1_deltachat.py +++ b/online-tests/test_1_deltachat.py @@ -19,7 +19,7 @@ class TestEndToEndDeltaChat: assert msg2.text == "message0" @pytest.mark.slow - def test_exceed_quota(self, cmfactory, lp, tmpdir, remotelog): + def test_exceed_quota(self, cmfactory, lp, tmpdir, remote): """This is a very slow test as it needs to upload >100MB of mail data before quota is exceeded, and thus depends on the speed of the upload. """ @@ -48,7 +48,7 @@ class TestEndToEndDeltaChat: addr = ac2.get_config("addr").lower() saved_ok = 0 - for line in remotelog.iter("journalctl -f -u dovecot"): + for line in remote.iter_output("journalctl -f -u dovecot"): if addr not in line: # print(line) continue