git@vger.kernel.org list mirror (unofficial, one of many)
 help / color / mirror / code / Atom feed
bc46c5a68ea26b4a15cca66c97548615c1599e2c blob 651 bytes (raw)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
 
#!/bin/sh

test_description='tests for git branch --track'

. ./test-lib.sh

test_expect_success 'setup' '
	test_commit one &&
	test_commit two
'

test_expect_success 'checkout --track -b creates a new tracking branch' '
	git checkout --track -b branch1 main &&
	test $(git rev-parse --abbrev-ref HEAD) = branch1 &&
	test $(git config --get branch.branch1.remote) = . &&
	test $(git config --get branch.branch1.merge) = refs/heads/main
'

test_expect_success 'checkout --track -b rejects an extra path argument' '
	test_must_fail git checkout --track -b branch2 main one.t 2>err &&
	test_i18ngrep "cannot be used with updating paths" err
'

test_done
debug log:

solving bc46c5a68e ...
found bc46c5a68e in https://public-inbox.org/git/9b368b1ce1c5462b1a6fda6755837806bf4edfa8.1605221039.git.gitgitgadget@gmail.com/ ||
	https://public-inbox.org/git/0d4f1275f745f90a1ea007dfc82510f0040ab4a0.1605629548.git.gitgitgadget@gmail.com/
found bcba1bf90c in https://80x24.org/mirrors/git.git
preparing index
index prepared:
100755 bcba1bf90c090a00e7e734aac4cb5a2d55ed1f66	t/t2027-checkout-track.sh

applying [1/2] https://public-inbox.org/git/9b368b1ce1c5462b1a6fda6755837806bf4edfa8.1605221039.git.gitgitgadget@gmail.com/
diff --git a/t/t2027-checkout-track.sh b/t/t2027-checkout-track.sh
index bcba1bf90c..bc46c5a68e 100755

Checking patch t/t2027-checkout-track.sh...
Applied patch t/t2027-checkout-track.sh cleanly.

skipping https://public-inbox.org/git/0d4f1275f745f90a1ea007dfc82510f0040ab4a0.1605629548.git.gitgitgadget@gmail.com/ for bc46c5a68e
index at:
100755 bc46c5a68ea26b4a15cca66c97548615c1599e2c	t/t2027-checkout-track.sh

Code repositories for project(s) associated with this inbox:

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).