Check that git clone against x/ project succeeds in testing

Previously the test was checking that stderr reported "Cloning into
$PATH" which also happens in failure cases. We add an explicit check for
a successful command return code to ensure that we aren't failing with
that output.

Change-Id: Iec51217f2cc97e6a56ff9d8b7a260650010f229f
This commit is contained in:
Clark Boylan 2021-02-01 08:16:21 -08:00
parent 137d518bf8
commit 523bab52fc

View File

@ -30,6 +30,7 @@ def test_gerrit_x_project_clone(host):
cmd = host.run( cmd = host.run(
'git clone http://localhost:8081/x/test-project /tmp/test-project') 'git clone http://localhost:8081/x/test-project /tmp/test-project')
assert "Cloning into '/tmp/test-project'..." in cmd.stderr assert "Cloning into '/tmp/test-project'..." in cmd.stderr
assert cmd.succeeded
def test_gerrit_screenshot(host): def test_gerrit_screenshot(host):
driver = webdriver.Remote( driver = webdriver.Remote(