summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorJesse Duffield <jessedduffield@gmail.com>2018-08-11 15:22:41 +1000
committerJesse Duffield <jessedduffield@gmail.com>2018-08-11 15:22:41 +1000
commit000a7097832a65c2b8dbdf7a96b93251071dd2c0 (patch)
tree3d7c32b3fd16e803feaa0ce5c855a68ff16842d4 /test
parent5c185572a754b9dc1bb1c918f136b4acefc53976 (diff)
update test repo generators including test for unicode characters
Diffstat (limited to 'test')
-rwxr-xr-xtest/lots_of_commits.sh2
-rwxr-xr-xtest/unicode_characters.sh35
2 files changed, 37 insertions, 0 deletions
diff --git a/test/lots_of_commits.sh b/test/lots_of_commits.sh
index d85034f4e..6a92d32e2 100755
--- a/test/lots_of_commits.sh
+++ b/test/lots_of_commits.sh
@@ -26,3 +26,5 @@ while [ $i -le $end ]; do
i=$(($i+1))
done
+
+echo "unstaged change" > file100
diff --git a/test/unicode_characters.sh b/test/unicode_characters.sh
new file mode 100755
index 000000000..92640d52f
--- /dev/null
+++ b/test/unicode_characters.sh
@@ -0,0 +1,35 @@
+#!/bin/bash
+
+# this script will make a repo with a master and develop branch, where we end up
+# on the master branch and if we try and merge master we get a merge conflict
+
+# call this command from the test directory:
+# ./generate_basic_repo.sh; cd testrepo; gg; cd ..
+
+# -e means exit if something fails
+# -x means print out simple commands before running them
+set -ex
+
+reponame="testrepo"
+
+rm -rf ${reponame}
+mkdir ${reponame}
+cd ${reponame}
+
+git init
+
+# Add some ansi, unicode, zero width joiner caracters
+cat <<EOT >> charstest.txt
+ANSI Π(U+0152 &OElig; Latin capital ligature OE Latin Extended-A)
+ ¥ (0xA5 U+00A5 &yen; yes sign)
+ ƒ (0x83 U+0192 &fnof; Latin small letter f with hook)
+ZWJ https://en.wikipedia.org/wiki/Zero-width_joiner / https://unicode.org/Public/emoji/4.0/emoji-zwj-sequences.txt 👶(👨‍👦)
+UNICODE ☆ 🤓 え 术
+EOT
+git add charstest.txt
+git commit -m "Test chars Œ¥ƒ👶👨‍👦☆ 🤓 え 术 commit"
+echo "我喜歡編碼" >> charstest.txt
+echo "நான் குறியீடு விரும்புகிறேன்" >> charstest.txt
+git add charstest.txt
+git commit -m "Test chars 我喜歡編碼 நான் குறியீடு விரும்புகிறேன் commit"
+