]> git.ipfire.org Git - thirdparty/git.git/blobdiff - t/t5510-fetch.sh
Merge branch 'js/update-index-ignore-removal-for-skip-worktree'
[thirdparty/git.git] / t / t5510-fetch.sh
index ecabbe1616d8a5c597fc32a354b053bc38a40334..4b602826895e21154376391333c6517b4ec1ec54 100755 (executable)
@@ -583,6 +583,22 @@ test_expect_success 'fetch.writeCommitGraph' '
        )
 '
 
+test_expect_success 'fetch.writeCommitGraph with submodules' '
+       git clone dups super &&
+       (
+               cd super &&
+               git submodule add "file://$TRASH_DIRECTORY/three" &&
+               git commit -m "add submodule"
+       ) &&
+       git clone "super" super-clone &&
+       (
+               cd super-clone &&
+               rm -rf .git/objects/info &&
+               git -c fetch.writeCommitGraph=true fetch origin &&
+               test_path_is_file .git/objects/info/commit-graphs/commit-graph-chain
+       )
+'
+
 # configured prune tests
 
 set_config_tristate () {