]> git.scottworley.com Git - pinch/blame - tests/reject-nonancestor2.sh
Fix a bash-ism in test.sh, which is #!/bin/sh
[pinch] / tests / reject-nonancestor2.sh
CommitLineData
0e515222
SW
1#!/bin/sh
2
3. ./tests/lib/test-setup.sh
4
5foo_setup
6
7(
8 cd "$repo"
9 git checkout -b historical
10 git checkout master
11 echo Other contents > other-file
12 git add other-file
13 git commit -m 'Second commit message'
14)
15
16python3 ./pinch.py pin "$conf"
17
18sed -i 's/master/historical/' "$conf"
19
20if python3 ./pinch.py pin "$conf";then
21 echo "FAIL: non-ancestor commit should be rejected"
22 exit 1
23else
24 echo PASS
25fi