test-client: increase context in pexecpt failure for debugging

When a pexpect check fails, we want to see the full content of the
buffer, so we can better see where it went wrong. Increase the context
that is printed in the error message.
This commit is contained in:
Thomas Haller
2023-05-11 08:26:37 +02:00
parent 0888ed93f7
commit cb51aee21c

View File

@@ -1009,6 +1009,8 @@ class TestNmClient(unittest.TestCase):
pexp = pexpect.spawn(argv[0], argv[1:], timeout=10, env=env)
pexp.str_last_chars = 100000
typ = collections.namedtuple("CallPexpect", ["pexp", "valgrind_log"])
return typ(pexp, valgrind_log)