diff options
author | Vincent Ambo <mail@tazj.in> | 2021-09-21T10·03+0300 |
---|---|---|
committer | Vincent Ambo <mail@tazj.in> | 2021-09-21T11·29+0300 |
commit | 43b1791ec601732ac31195df96781a848360a9ac (patch) | |
tree | daae8d638343295d2f1f7da955e556ef4c958864 /third_party/git/t/t6433-merge-toplevel.sh | |
parent | 2d8e7dc9d9c38127ec4ebd13aee8e8f586a43318 (diff) |
chore(3p/git): Unvendor git and track patches instead r/2903
This was vendored a long time ago under the expectation that keeping it in sync with cgit would be easier this way, but it has proven not to be a big issue. On the other hand, a vendored copy of git is an annoying maintenance burden. It is much easier to rebase the single (dottime) patch that we have. This removes the vendored copy of git and instead passes the git source code to cgit via `pkgs.srcOnly`, which includes the applied patch so that cgit can continue rendering dottime. Change-Id: If31f62dea7ce688fd1b9050204e9378019775f2b
Diffstat (limited to 'third_party/git/t/t6433-merge-toplevel.sh')
-rwxr-xr-x | third_party/git/t/t6433-merge-toplevel.sh | 174 |
1 files changed, 0 insertions, 174 deletions
diff --git a/third_party/git/t/t6433-merge-toplevel.sh b/third_party/git/t/t6433-merge-toplevel.sh deleted file mode 100755 index e29c284b9b9b..000000000000 --- a/third_party/git/t/t6433-merge-toplevel.sh +++ /dev/null @@ -1,174 +0,0 @@ -#!/bin/sh - -test_description='"git merge" top-level frontend' - -. ./test-lib.sh - -t3033_reset () { - git checkout -B master two && - git branch -f left three && - git branch -f right four -} - -test_expect_success setup ' - test_commit one && - git branch left && - git branch right && - test_commit two && - git checkout left && - test_commit three && - git checkout right && - test_commit four && - git checkout --orphan newroot && - test_commit five && - git checkout master -' - -# Local branches - -test_expect_success 'merge an octopus into void' ' - t3033_reset && - git checkout --orphan test && - git rm -fr . && - test_must_fail git merge left right && - test_must_fail git rev-parse --verify HEAD && - git diff --quiet && - test_must_fail git rev-parse HEAD -' - -test_expect_success 'merge an octopus, fast-forward (ff)' ' - t3033_reset && - git reset --hard one && - git merge left right && - # one is ancestor of three (left) and four (right) - test_must_fail git rev-parse --verify HEAD^3 && - git rev-parse HEAD^1 HEAD^2 | sort >actual && - git rev-parse three four | sort >expect && - test_cmp expect actual -' - -test_expect_success 'merge octopus, non-fast-forward (ff)' ' - t3033_reset && - git reset --hard one && - git merge --no-ff left right && - # one is ancestor of three (left) and four (right) - test_must_fail git rev-parse --verify HEAD^4 && - git rev-parse HEAD^1 HEAD^2 HEAD^3 | sort >actual && - git rev-parse one three four | sort >expect && - test_cmp expect actual -' - -test_expect_success 'merge octopus, fast-forward (does not ff)' ' - t3033_reset && - git merge left right && - # two (master) is not an ancestor of three (left) and four (right) - test_must_fail git rev-parse --verify HEAD^4 && - git rev-parse HEAD^1 HEAD^2 HEAD^3 | sort >actual && - git rev-parse two three four | sort >expect && - test_cmp expect actual -' - -test_expect_success 'merge octopus, non-fast-forward' ' - t3033_reset && - git merge --no-ff left right && - test_must_fail git rev-parse --verify HEAD^4 && - git rev-parse HEAD^1 HEAD^2 HEAD^3 | sort >actual && - git rev-parse two three four | sort >expect && - test_cmp expect actual -' - -# The same set with FETCH_HEAD - -test_expect_success 'merge FETCH_HEAD octopus into void' ' - t3033_reset && - git checkout --orphan test && - git rm -fr . && - git fetch . left right && - test_must_fail git merge FETCH_HEAD && - test_must_fail git rev-parse --verify HEAD && - git diff --quiet && - test_must_fail git rev-parse HEAD -' - -test_expect_success 'merge FETCH_HEAD octopus fast-forward (ff)' ' - t3033_reset && - git reset --hard one && - git fetch . left right && - git merge FETCH_HEAD && - # one is ancestor of three (left) and four (right) - test_must_fail git rev-parse --verify HEAD^3 && - git rev-parse HEAD^1 HEAD^2 | sort >actual && - git rev-parse three four | sort >expect && - test_cmp expect actual -' - -test_expect_success 'merge FETCH_HEAD octopus non-fast-forward (ff)' ' - t3033_reset && - git reset --hard one && - git fetch . left right && - git merge --no-ff FETCH_HEAD && - # one is ancestor of three (left) and four (right) - test_must_fail git rev-parse --verify HEAD^4 && - git rev-parse HEAD^1 HEAD^2 HEAD^3 | sort >actual && - git rev-parse one three four | sort >expect && - test_cmp expect actual -' - -test_expect_success 'merge FETCH_HEAD octopus fast-forward (does not ff)' ' - t3033_reset && - git fetch . left right && - git merge FETCH_HEAD && - # two (master) is not an ancestor of three (left) and four (right) - test_must_fail git rev-parse --verify HEAD^4 && - git rev-parse HEAD^1 HEAD^2 HEAD^3 | sort >actual && - git rev-parse two three four | sort >expect && - test_cmp expect actual -' - -test_expect_success 'merge FETCH_HEAD octopus non-fast-forward' ' - t3033_reset && - git fetch . left right && - git merge --no-ff FETCH_HEAD && - test_must_fail git rev-parse --verify HEAD^4 && - git rev-parse HEAD^1 HEAD^2 HEAD^3 | sort >actual && - git rev-parse two three four | sort >expect && - test_cmp expect actual -' - -# two-project merge -test_expect_success 'refuse two-project merge by default' ' - t3033_reset && - git reset --hard four && - test_must_fail git merge five -' - -test_expect_success 'refuse two-project merge by default, quit before --autostash happens' ' - t3033_reset && - git reset --hard four && - echo change >>one.t && - git diff >expect && - test_must_fail git merge --autostash five 2>err && - test_i18ngrep ! "stash" err && - git diff >actual && - test_cmp expect actual -' - -test_expect_success 'two-project merge with --allow-unrelated-histories' ' - t3033_reset && - git reset --hard four && - git merge --allow-unrelated-histories five && - git diff --exit-code five -' - -test_expect_success 'two-project merge with --allow-unrelated-histories with --autostash' ' - t3033_reset && - git reset --hard four && - echo change >>one.t && - git diff one.t >expect && - git merge --allow-unrelated-histories --autostash five 2>err && - test_i18ngrep "Applied autostash." err && - git diff one.t >actual && - test_cmp expect actual -' - -test_done |