diff options
Diffstat (limited to 't/t7900-maintenance.sh')
| -rwxr-xr-x | t/t7900-maintenance.sh | 31 |
1 files changed, 6 insertions, 25 deletions
diff --git a/t/t7900-maintenance.sh b/t/t7900-maintenance.sh index 74aa638475..2724a44fe3 100755 --- a/t/t7900-maintenance.sh +++ b/t/t7900-maintenance.sh @@ -32,11 +32,13 @@ test_systemd_analyze_verify () { } test_expect_success 'help text' ' - test_expect_code 129 git maintenance -h 2>err && - test_i18ngrep "usage: git maintenance <subcommand>" err && - test_expect_code 128 git maintenance barf 2>err && - test_i18ngrep "invalid subcommand: barf" err && + test_expect_code 129 git maintenance -h >actual && + test_i18ngrep "usage: git maintenance <subcommand>" actual && + test_expect_code 129 git maintenance barf 2>err && + test_i18ngrep "unknown subcommand: \`barf'\''" err && + test_i18ngrep "usage: git maintenance" err && test_expect_code 129 git maintenance 2>err && + test_i18ngrep "error: need a subcommand" err && test_i18ngrep "usage: git maintenance" err ' @@ -162,7 +164,6 @@ test_expect_success 'prefetch multiple remotes' ' test_cmp_rev refs/remotes/remote1/one refs/prefetch/remotes/remote1/one && test_cmp_rev refs/remotes/remote2/two refs/prefetch/remotes/remote2/two && - test_cmp_config refs/prefetch/ log.excludedecoration && git log --oneline --decorate --all >log && ! grep "prefetch" log && @@ -173,26 +174,6 @@ test_expect_success 'prefetch multiple remotes' ' test_subcommand git fetch remote2 $fetchargs <skip-remote1.txt ' -test_expect_success 'prefetch and existing log.excludeDecoration values' ' - git config --unset-all log.excludeDecoration && - git config log.excludeDecoration refs/remotes/remote1/ && - git maintenance run --task=prefetch && - - git config --get-all log.excludeDecoration >out && - grep refs/remotes/remote1/ out && - grep refs/prefetch/ out && - - git log --oneline --decorate --all >log && - ! grep "prefetch" log && - ! grep "remote1" log && - grep "remote2" log && - - # a second run does not change the config - git maintenance run --task=prefetch && - git log --oneline --decorate --all >log2 && - test_cmp log log2 -' - test_expect_success 'loose-objects task' ' # Repack everything so we know the state of the object dir git repack -adk && |
