Skip to content
  • Stefan Beller's avatar
    submodule test invocation: only pass additional arguments · 17f38cb7
    Stefan Beller authored and Junio C Hamano's avatar Junio C Hamano committed
    
    
    In a later patch we want to introduce a config option to trigger the
    submodule recursing by default. As this option should be available and
    uniform across all commands that deal with submodules we'd want to test
    for this option in the submodule update library.
    
    So instead of calling the whole test set again for
    "git -c submodule.recurse foo" instead of "git foo --recurse-submodules",
    we'd only want to introduce one basic test that tests if the option is
    recognized and respected to not overload the test suite.
    
    Change the test functions by taking only the argument and assemble the
    command inside the test function by embedding the arguments into the
    command that is "git $arguments --recurse-submodules".
    
    It would be nice to do this for all functions in lib-submodule-update,
    but we cannot do that for the non-recursing tests, as there we do not
    just pass in a git command but whole functions. (See t3426 for example)
    
    Signed-off-by: default avatarStefan Beller <sbeller@google.com>
    Signed-off-by: default avatarJunio C Hamano <gitster@pobox.com>
    17f38cb7