def test_get_url(self): host = 'github.com' path = '/jelmer/dulwich' c = TCPGitClient(host) url = c.get_url(path) self.assertEqual('git://github.com/jelmer/dulwich', url)
def test_get_url_with_port(self): host = 'github.com' path = '/jelmer/dulwich' port = 9090 c = TCPGitClient(host, port=port) url = c.get_url(path) self.assertEqual('git://github.com:9090/jelmer/dulwich', url)