submodule: Use cat instead of echo to avoid DOS line-endings
[git/dscho.git] / t / t0010-racy-git.sh
blobe45a9e40e432524454e94a041599b201a092879a
1 #!/bin/sh
3 test_description='racy GIT'
5 . ./test-lib.sh
7 # This test can give false success if your machine is sufficiently
8 # slow or your trial happened to happen on second boundary.
10 for trial in 0 1 2 3 4
12 rm -f .git/index
13 echo frotz >infocom
14 git update-index --add infocom
15 echo xyzzy >infocom
17 files=`git diff-files -p`
18 test_expect_success \
19 "Racy GIT trial #$trial part A" \
20 'test "" != "$files"'
22 sleep 1
23 echo xyzzy >cornerstone
24 git update-index --add cornerstone
26 files=`git diff-files -p`
27 test_expect_success \
28 "Racy GIT trial #$trial part B" \
29 'test "" != "$files"'
31 done
33 test_done