On Thu, 8 Sep 2022 11:49:09 +1000 David Gibson <david(a)gibson.dropbear.id.au> wrote:Sorry for the resend, but I found and fixed a couple of warts in this series. The test scripts need to dispatch commands in various different contexts: on the host, in namespaces, and in guests. Currently this is done by running each context in a tmux pane and simulating typing into that pane using tmux commands. This has a number of problems: * It's slow * Getting the results from programs is tricky and error prone. We can misparse output if: * The window isn't large enough * Commands produce output which looks like a shell prompt * The shell doesn't have the prompt we expect * A accidental keypress while the tests are running can mess up the test run * We have to issue explicit "echo $?" commands to check if things succeeded This series adds a new subsystem to the test scripts for dispatching commands which accurately preserves output (both stdout and stderr), and exit codes. Most of the testsuite is converted to this new system. For now the distro tests still rely on the old approach, since they have some complications that require additional handling. That does, alas, mean we have some ugly transitional code remaining. Oh well, we should be able to clean that up at some point. This series is pased on the previous series cleaning up the performance tests. Changes since v1: * Removed a couple of commented debugging lines in patch 9/11 * Removed a no longer necessary pipe-pane in patch 9/11In general, this looks like a big improvement, and I would try to apply it basically as it is (I haven't run the tests yet). There are a few nits that might need to be addressed. I can fix them up on merge, unless you re-spin this, but I'd need some help with the comment on 11/11. -- Stefano