From 54386fe6cc937fb983dd7d27dadc4e84bd519624 Mon Sep 17 00:00:00 2001 From: Rob Browning Date: Sat, 11 Jun 2016 12:15:21 -0500 Subject: [PATCH] test-meta: loosen expected rsync diff pattern Homebrew's rsync produces 12 status characters, not 11. Thanks to ilovezfs for reporting the problem and helping test the fix. Signed-off-by: Rob Browning Tested-by: Rob Browning --- t/test-meta.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/t/test-meta.sh b/t/test-meta.sh index 1170d71..803b61a 100755 --- a/t/test-meta.sh +++ b/t/test-meta.sh @@ -171,8 +171,11 @@ WVSTART 'metadata save/restore (general)' # Check that the only difference is the top dir. WVFAIL $TOP/t/compare-trees -c src/var/ src-restore/ > tmp-compare-trees WVPASSEQ $(cat tmp-compare-trees | wc -l) 1 - # Note: OS X rsync itemize output is currently only 9 chars, not 11. - expected_diff_rx='^\.d\.\.t.\.\.\.\.?\.? \./$' + # The number of rsync status characters varies, so accept any + # number of trailing dots. For example OS X native rsync produces + # 9, but Homebrew's produces 12, while on other platforms, 11 is + # common. + expected_diff_rx='^\.d\.\.t\.\.\.(\.)+ \./$' if ! grep -qE "$expected_diff_rx" tmp-compare-trees; then echo -n 'tmp-compare-trees: ' 1>&2 cat tmp-compare-trees 1>&2 -- 2.39.2