]> git.ipfire.org Git - thirdparty/git.git/blobdiff - t/t5510-fetch.sh
Merge branch 'rs/preserve-merges-unused-code-removal'
[thirdparty/git.git] / t / t5510-fetch.sh
index 7456c567cd1857a05703801b8f14fa78938b3f7a..25695dfe2232ef3d1ce54ef0eedec2b9fe51b3da 100755 (executable)
@@ -213,7 +213,7 @@ test_expect_success 'fetch tags when there is no tags' '
 test_expect_success 'fetch following tags' '
 
        cd "$D" &&
-       git tag -a -m 'annotated' anno HEAD &&
+       git tag -a -m "annotated" anno HEAD &&
        git tag light HEAD &&
 
        mkdir four &&
@@ -281,15 +281,19 @@ test_expect_success 'create bundle 1' '
        cd "$D" &&
        echo >file updated again by origin &&
        git commit -a -m "tip" &&
-       git bundle create bundle1 master^..master
+       git bundle create --version=3 bundle1 master^..master
 '
 
 test_expect_success 'header of bundle looks right' '
-       head -n 4 "$D"/bundle1 &&
-       head -n 1 "$D"/bundle1 | grep "^#" &&
-       head -n 2 "$D"/bundle1 | grep "^-$OID_REGEX " &&
-       head -n 3 "$D"/bundle1 | grep "^$OID_REGEX " &&
-       head -n 4 "$D"/bundle1 | grep "^$"
+       cat >expect <<-EOF &&
+       # v3 git bundle
+       @object-format=$(test_oid algo)
+       -OID updated by origin
+       OID refs/heads/master
+
+       EOF
+       sed -e "s/$OID_REGEX/OID/g" -e "5q" "$D"/bundle1 >actual &&
+       test_cmp expect actual
 '
 
 test_expect_success 'create bundle 2' '
@@ -331,7 +335,7 @@ test_expect_success 'bundle does not prerequisite objects' '
 test_expect_success 'bundle should be able to create a full history' '
 
        cd "$D" &&
-       git tag -a -m '1.0' v1.0 master &&
+       git tag -a -m "1.0" v1.0 master &&
        git bundle create bundle4 v1.0
 
 '