1
0
mirror of https://github.com/git/git.git synced 2024-10-20 23:58:49 +02:00
git/t/t9010-svn-fe.sh
Jonathan Nieder 24f1136894 t9010 (svn-fe): use Unix-style path in URI
Ever since v1.6.3-rc0~101^2~14 (Tests on Windows: $(pwd) must return
Windows-style paths, 2009-03-13), there is a subtle difference between
$(pwd) and $PWD in tests: the former returns Windows-style paths as
might be output by git and the latter Unix-style paths which msys
programs tend to prefer.

In file:// URIs, Unix-style paths are needed.  Before: “svn export”
declares it cannot find

 file://c:/apps/git/git/t/trash directory/simple-svco

After: “svn export” successfully finds

 file:///c/apps/git/git/...

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-08-14 19:35:38 -07:00

33 lines
635 B
Bash

#!/bin/sh
test_description='check svn dumpfile importer'
. ./lib-git-svn.sh
test_dump() {
label=$1
dump=$2
test_expect_success "$dump" '
svnadmin create "$label-svn" &&
svnadmin load "$label-svn" < "$TEST_DIRECTORY/$dump" &&
svn_cmd export "file://$PWD/$label-svn" "$label-svnco" &&
git init "$label-git" &&
test-svn-fe "$TEST_DIRECTORY/$dump" >"$label.fe" &&
(
cd "$label-git" &&
git fast-import < ../"$label.fe"
) &&
(
cd "$label-svnco" &&
git init &&
git add . &&
git fetch "../$label-git" master &&
git diff --exit-code FETCH_HEAD
)
'
}
test_dump simple t9111/svnsync.dump
test_done