X-Git-Url: https://ruderich.org/simon/gitweb/?a=blobdiff_plain;f=t%2Ftest.sh;h=6f1084b263486c2e1082e10e10bab56e97764ed5;hb=f7001b4c41c16f44a06e5666c6d8b3c6ac269009;hp=a76726643727970867e517364c27fb42c3098ce4;hpb=33cb2dd3546e3dd86fe914453f5ee354bce42678;p=config%2Fdotfiles.git
diff --git a/t/test.sh b/t/test.sh
index a767266..6f1084b 100755
--- a/t/test.sh
+++ b/t/test.sh
@@ -2,7 +2,7 @@
# Small test file to check different --word-diff-regex settings in Git.
-# Copyright (C) 2012 Simon Ruderich
+# Copyright (C) 2012-2014 Simon Ruderich
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -18,7 +18,7 @@
# along with this program. If not, see .
-set -e
+set -eu
git_diff() {
git diff --color=never --word-diff=plain --word-diff-regex="$1" \
@@ -31,8 +31,8 @@ git_diff() {
mkdir test
cd test
-git init > /dev/null
-cat > test.txt </dev/null
+cat >test.txt < /dev/null
+git commit -m 'Initial commit.' >/dev/null
-cat > test.txt <test.txt <