From 6bd4e66b2308b70161641b20af2f5e78c6cb1a1a Mon Sep 17 00:00:00 2001 From: Frans Kaashoek Date: Tue, 3 Sep 2024 19:56:41 -0400 Subject: [PATCH] another xargs test --- grade-lab-util | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/grade-lab-util b/grade-lab-util index 41f0ee4..9ba6e37 100755 --- a/grade-lab-util +++ b/grade-lab-util @@ -84,7 +84,7 @@ def test_find_recursive(): './%s/%s/%s' % (dirs[0], dirs[1], needle), './%s/%s' % (dirs[2], needle)) -@test(19, "xargs") +@test(10, "xargs") def test_xargs(): r.run_qemu(shell_script([ 'sh < xargstest.sh', @@ -93,6 +93,11 @@ def test_xargs(): matches = re.findall("hello", r.qemu.output) assert_equal(len(matches), 3, "Number of appearances of 'hello'") +@test(9, "xargs, multi-line echo") +def test_xargs_multiline(): + r.run_qemu(shell_script(['(echo 1 ; echo 2) | xargs echo'])) + r.match('^1$', '^2$') + @test(1, "time") def test_time(): check_time()