remote-testgit: remove non-local functionality
This only makes sense for the python remote helpers framework. The tests don't exercise any feature of transport helper. Remove them. Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Felipe Contreras committed
Nov 28, 2012 at 23:11 UTC
984f37681c937be0c7c1135e86141a83920edcc1
2 files changed
+21
-32
git-remote-testgit
-3
@@ -4,9 +4,6 @@
4
alias=$1
5
url=$2
6
7
-# huh?
8
-url="${url#file://}"
9
-
7
dir="$GIT_DIR/testgit/$alias"
8
prefix="refs/testgit/$alias"
9
refspec="refs/heads/*:${prefix}/heads/*"
t/t5801-remote-helpers.sh
+21
-29
@@ -33,11 +33,6 @@ test_expect_success 'cloning from local repo' '
33
test_cmp public/file localclone/file
34
'
35
36
-test_expect_success 'cloning from remote repo' '
37
- git clone "testgit::file://${PWD}/server" clone &&
38
- test_cmp public/file clone/file
39
-'
40
-
36
test_expect_success 'create new commit on remote' '
37
(cd public &&
38
echo content >>file &&
@@ -50,11 +45,6 @@ test_expect_success 'pulling from local repo' '
45
test_cmp public/file localclone/file
46
'
47
53
-test_expect_success 'pulling from remote remote' '
54
- (cd clone && git pull) &&
55
- test_cmp public/file clone/file
56
-'
57
-
48
test_expect_success 'pushing to local repo' '
49
(cd localclone &&
50
echo content >>file &&
@@ -76,19 +66,6 @@ test_expect_success 'pushing to local repo' '
66
compare_refs localclone2 HEAD server2 HEAD
67
'
68
79
-test_expect_success 'synch with changes from localclone' '
80
- (cd clone &&
81
- git pull)
82
-'
83
-
84
-test_expect_success 'pushing remote local repo' '
85
- (cd clone &&
86
- echo content >>file &&
87
- git commit -a -m four &&
88
- git push) &&
89
- compare_refs clone HEAD server HEAD
90
-'
91
-
69
test_expect_success 'fetch new branch' '
70
(cd public &&
71
git checkout -b new &&
@@ -102,6 +79,20 @@ test_expect_success 'fetch new branch' '
79
compare_refs public HEAD localclone FETCH_HEAD
80
'
81
82
+#
83
+# This is only needed because of a bug not detected by this script. It will be
84
+# fixed shortly, but for now lets not cause regressions.
85
+#
86
+test_expect_success 'bump commit in public' '
87
+ (cd public &&
88
+ git checkout master &&
89
+ git pull &&
90
+ echo content >>file &&
91
+ git commit -a -m four &&
92
+ git push) &&
93
+ compare_refs public HEAD server HEAD
94
+'
95
+
96
test_expect_success 'fetch multiple branches' '
97
(cd localclone &&
98
git fetch
@@ -111,29 +102,30 @@ test_expect_success 'fetch multiple branches' '
102
'
103
104
test_expect_success 'push when remote has extra refs' '
114
- (cd clone &&
105
+ (cd localclone &&
106
+ git reset --hard origin/master &&
107
echo content >>file &&
108
git commit -a -m six &&
109
git push
110
) &&
119
- compare_refs clone master server master
111
+ compare_refs localclone master server master
112
'
113
114
test_expect_success 'push new branch by name' '
123
- (cd clone &&
115
+ (cd localclone &&
116
git checkout -b new-name &&
117
echo content >>file &&
118
git commit -a -m seven &&
119
git push origin new-name
120
) &&
129
- compare_refs clone HEAD server refs/heads/new-name
121
+ compare_refs localclone HEAD server refs/heads/new-name
122
'
123
124
test_expect_failure 'push new branch with old:new refspec' '
133
- (cd clone &&
125
+ (cd localclone &&
126
git push origin new-name:new-refspec
127
) &&
136
- compare_refs clone HEAD server refs/heads/new-refspec
128
+ compare_refs localclone HEAD server refs/heads/new-refspec
129
'
130
131
test_done