aboutsummaryrefslogtreecommitdiffstats
path: root/plumbing/transport/server/server_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'plumbing/transport/server/server_test.go')
-rw-r--r--plumbing/transport/server/server_test.go8
1 files changed, 7 insertions, 1 deletions
diff --git a/plumbing/transport/server/server_test.go b/plumbing/transport/server/server_test.go
index 0f7201c..7912768 100644
--- a/plumbing/transport/server/server_test.go
+++ b/plumbing/transport/server/server_test.go
@@ -20,12 +20,18 @@ type BaseSuite struct {
loader server.MapLoader
client transport.Transport
clientBackup transport.Transport
+ asClient bool
}
func (s *BaseSuite) SetUpSuite(c *C) {
s.Suite.SetUpSuite(c)
s.loader = server.MapLoader{}
- s.client = server.NewServer(s.loader)
+ if s.asClient {
+ s.client = server.NewClient(s.loader)
+ } else {
+ s.client = server.NewServer(s.loader)
+ }
+
s.clientBackup = client.Protocols["file"]
client.Protocols["file"] = s.client
}