Skip to content

Commit f55e749

Browse files
committed
t5580: test cloning without file://, test fetching via UNC paths
On Windows, it is quite common to work with network drives. The format of the paths to network drives (or "network shares", or UNC paths) is: \\<server>\<share>\... We already have a couple regression tests revolving around those types of paths, but we missed cloning and fetching from UNC paths without leading `file://` (and with backslashes instead of forward slashes). This lil' patch closes that gap. It gets a bit silly to add the commands to the name of the test script, so let's just rename it while we're testing more UNC stuff. Signed-off-by: Johannes Schindelin <[email protected]>
1 parent d8437c5 commit f55e749

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

t/t5580-clone-push-unc.sh renamed to t/t5580-unc-paths.sh

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,23 @@ test_expect_success clone '
4040
git clone "file://$UNCPATH" clone
4141
'
4242

43+
test_expect_success 'clone without file://' '
44+
git clone "$UNCPATH" clone-without-file
45+
'
46+
4347
test_expect_success 'clone with backslashed path' '
4448
BACKSLASHED="$(echo "$UNCPATH" | tr / \\\\)" &&
4549
git clone "$BACKSLASHED" backslashed
4650
'
4751

52+
test_expect_success fetch '
53+
git init to-fetch &&
54+
(
55+
cd to-fetch &&
56+
git fetch "$UNCPATH" master
57+
)
58+
'
59+
4860
test_expect_success push '
4961
(
5062
cd clone &&

0 commit comments

Comments
 (0)