From faa9102e0a10f800d2303239ad4c75a7ced57870 Mon Sep 17 00:00:00 2001 From: Tim Kientzle Date: Sun, 27 Dec 2009 18:54:52 -0500 Subject: [PATCH] Assert contents for stderr; this might help track a bug that's showing up in the CDash nightly tests. SVN-Revision: 1780 --- cpio/test/test_option_L_upper.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/cpio/test/test_option_L_upper.c b/cpio/test/test_option_L_upper.c index abe669fac..1774343f6 100644 --- a/cpio/test/test_option_L_upper.c +++ b/cpio/test/test_option_L_upper.c @@ -58,6 +58,7 @@ DEFINE_TEST(test_option_L_upper) r = systemf(CAT " filelist | %s -pd copy >copy.out 2>copy.err", testprog); assertEqualInt(r, 0); + assertTextFileContents("1 block\n", "copy.err"); failure("Regular -p without -L should preserve symlinks."); assertIsSymlink("copy/symlink", NULL); @@ -72,25 +73,29 @@ DEFINE_TEST(test_option_L_upper) r = systemf(CAT " filelist | %s -o >archive.out 2>archive.err", testprog); failure("Error invoking %s -o ", testprog); assertEqualInt(r, 0); + assertTextFileContents("1 block\n", "archive.err"); assertMakeDir("unpack", 0755); assertChdir("unpack"); r = systemf(CAT " ../archive.out | %s -i >unpack.out 2>unpack.err", testprog); - assertChdir(".."); failure("Error invoking %s -i", testprog); assertEqualInt(r, 0); + assertTextFileContents("1 block\n", "unpack.err"); + assertChdir(".."); assertIsSymlink("unpack/symlink", NULL); r = systemf(CAT " filelist | %s -oL >archive-L.out 2>archive-L.err", testprog); failure("Error invoking %s -oL", testprog); assertEqualInt(r, 0); + assertTextFileContents("1 block\n", "archive-L.err"); assertMakeDir("unpack-L", 0755); assertChdir("unpack-L"); r = systemf(CAT " ../archive-L.out | %s -i >unpack-L.out 2>unpack-L.err", testprog); - assertChdir(".."); failure("Error invoking %s -i < archive-L.out", testprog); assertEqualInt(r, 0); + assertTextFileContents("1 block\n", "unpack-L.err"); + assertChdir(".."); assertIsReg("unpack-L/symlink", -1); } -- 2.47.3