[PATCH 2/7] contrib/subtree: Add test for missing subtree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Techlive Zheng <techlivezheng@xxxxxxxxx>

Test that a merge from a non-existant subtree fails.

Signed-off-by: Techlive Zheng <techlivezheng@xxxxxxxxx>
Signed-off-by: David A. Greene <greened@xxxxxxxxxxxxx>
---
 contrib/subtree/t/t7900-subtree.sh | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/contrib/subtree/t/t7900-subtree.sh b/contrib/subtree/t/t7900-subtree.sh
index f9dda3d..4471786 100755
--- a/contrib/subtree/t/t7900-subtree.sh
+++ b/contrib/subtree/t/t7900-subtree.sh
@@ -123,6 +123,10 @@ test_expect_success 'no pull from non-existant subtree' '
 	test_must_fail git subtree pull --prefix="sub dir" ./"sub proj" sub1
 '
 
+test_expect_success 'no merge from non-existent subtree' '
+	test_must_fail git subtree merge --prefix="sub dir" FETCH_HEAD
+'
+
 test_expect_success 'check if --message works for add' '
 	git subtree add --prefix="sub dir" --message="Added subproject" sub1 &&
 	check_equal ''"$(last_commit_message)"'' "Added subproject" &&
-- 
2.6.1

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]