Commit Diff


commit - 2b72f32d6817b003f88452592f304c2e114617be
commit + e0d77865e2e51f2e3d61d5c36458739101d65005
blob - 5cec87c8d26920d2df174053c6479b3b60232857
blob + eabde9c24df6b9d72582040315ce0f913a98716c
--- regress/cmdline/add.sh
+++ regress/cmdline/add.sh
@@ -61,6 +61,24 @@ test_double_add() {
 	fi
 
 	echo -n > $testroot/stdout.expected
+	cmp -s $testroot/stdout.expected $testroot/stdout
+	ret=$?
+	if [ $ret -ne 0 ]; then
+		diff -u $testroot/stdout.expected $testroot/stdout
+		test_done "$testroot" "$ret"
+		return 1
+	fi
+
+	echo "new file" > $testroot/wt/epsilon/zeta2
+	(cd $testroot/wt && got add epsilon/zeta* > $testroot/stdout)
+	ret=$?
+	if [ $ret -ne 0 ]; then
+		echo "got add failed unexpectedly" >&2
+		test_done "$testroot" 1
+		return 1
+	fi
+
+	echo 'A  epsilon/zeta2' > $testroot/stdout.expected
 	cmp -s $testroot/stdout.expected $testroot/stdout
 	ret=$?
 	if [ $ret -ne 0 ]; then