t9124: clean up chdir usage
Spawn subshells when running things in subdirectories instead of chdir-ing to the path of an undefined variable, which is confusing. Signed-off-by: Eric Wong <normalperson@yhbt.net>
This commit is contained in:
parent
4457d4f767
commit
a786091b4a
@ -29,13 +29,11 @@ test_expect_success 'initialize git-svn' '
|
|||||||
'
|
'
|
||||||
|
|
||||||
test_expect_success 'enable auto-props config' '
|
test_expect_success 'enable auto-props config' '
|
||||||
cd "$gittestrepo" &&
|
|
||||||
mkdir user &&
|
mkdir user &&
|
||||||
generate_auto_props yes >user/config
|
generate_auto_props yes >user/config
|
||||||
'
|
'
|
||||||
|
|
||||||
test_expect_success 'add files matching auto-props' '
|
test_expect_success 'add files matching auto-props' '
|
||||||
cd "$gittestrepo" &&
|
|
||||||
echo "#!$SHELL_PATH" >exec1.sh &&
|
echo "#!$SHELL_PATH" >exec1.sh &&
|
||||||
chmod +x exec1.sh &&
|
chmod +x exec1.sh &&
|
||||||
echo "hello" >hello.txt &&
|
echo "hello" >hello.txt &&
|
||||||
@ -46,12 +44,10 @@ test_expect_success 'add files matching auto-props' '
|
|||||||
'
|
'
|
||||||
|
|
||||||
test_expect_success 'disable auto-props config' '
|
test_expect_success 'disable auto-props config' '
|
||||||
cd "$gittestrepo" &&
|
|
||||||
generate_auto_props no >user/config
|
generate_auto_props no >user/config
|
||||||
'
|
'
|
||||||
|
|
||||||
test_expect_success 'add files matching disabled auto-props' '
|
test_expect_success 'add files matching disabled auto-props' '
|
||||||
cd "$gittestrepo" &&
|
|
||||||
echo "#$SHELL_PATH" >exec2.sh &&
|
echo "#$SHELL_PATH" >exec2.sh &&
|
||||||
chmod +x exec2.sh &&
|
chmod +x exec2.sh &&
|
||||||
echo "world" >world.txt &&
|
echo "world" >world.txt &&
|
||||||
@ -62,6 +58,7 @@ test_expect_success 'add files matching disabled auto-props' '
|
|||||||
'
|
'
|
||||||
|
|
||||||
test_expect_success 'check resulting svn repository' '
|
test_expect_success 'check resulting svn repository' '
|
||||||
|
(
|
||||||
mkdir work &&
|
mkdir work &&
|
||||||
cd work &&
|
cd work &&
|
||||||
svn co "$svnrepo" &&
|
svn co "$svnrepo" &&
|
||||||
@ -81,6 +78,7 @@ test_expect_success 'check resulting svn repository' '
|
|||||||
test "x$(svn propget svn:mime-type world.txt)" = "x" &&
|
test "x$(svn propget svn:mime-type world.txt)" = "x" &&
|
||||||
test "x$(svn propget svn:eol-style world.txt)" = "x" &&
|
test "x$(svn propget svn:eol-style world.txt)" = "x" &&
|
||||||
test "x$(svn propget svn:mime-type zot)" = "x"
|
test "x$(svn propget svn:mime-type zot)" = "x"
|
||||||
|
)
|
||||||
'
|
'
|
||||||
|
|
||||||
test_done
|
test_done
|
||||||
|
Loading…
Reference in New Issue
Block a user