test/buildroot: more lenient output test checking

In `test_output`, require that the test string is found in the
output, not equal to the output. Other warnings or log messages
might be printed by the runner.
This commit is contained in:
Christian Kellner 2020-10-20 18:00:23 +02:00 committed by David Rheinsberg
parent 9ef642228f
commit 25662fbfbc

View file

@ -77,7 +77,7 @@ class TestBuildRoot(test.TestBase):
r = root.run(["/usr/bin/echo", data], monitor)
self.assertEqual(r.returncode, 0)
self.assertEqual(data, r.output.strip())
self.assertIn(data, r.output.strip())
@unittest.skipUnless(test.TestBase.have_test_data(), "no test-data access")
def test_bind_mounts(self):