# HG changeset patch # User Mads Kiilerich # Date 2010-08-09 19:43:39 # Node ID 423ece53380ee7cb475f9f429766757749f6a070 # Parent ca6cebd8734e625086d41c6eb90aa9714bd5970b test-dispatch: Make test of removed working directory work on AIX (issue2315) AIX sh won't delete its own working directory. Removing it from another process works. Also hide the actual OS error message - operating systems returns different errors when getcwd fails. diff --git a/tests/test-dispatch b/tests/test-dispatch --- a/tests/test-dispatch +++ b/tests/test-dispatch @@ -22,8 +22,8 @@ EOF hg cat a echo '% working directory removed' -rm -rf $dir/a -hg --version +sh -c "cd $dir && rm -rf a" +hg --version 2>&1 | sed -e 's,\(abort:.*:\).*$,\1 ...,g' echo '% no repo' cd $dir diff --git a/tests/test-dispatch.out b/tests/test-dispatch.out --- a/tests/test-dispatch.out +++ b/tests/test-dispatch.out @@ -34,6 +34,6 @@ use "hg -v help cat" to show global opti a a: No such file in rev 000000000000 % working directory removed -abort: error getting current working directory: No such file or directory +abort: error getting current working directory: ... % no repo abort: There is no Mercurial repository here (.hg not found)!