~jelmer/brz-git/urls

« back to all changes in this revision

Viewing changes to tests/test_urls.py

  • Committer: Jelmer Vernooij
  • Date: 2018-04-02 13:20:10 UTC
  • Revision ID: jelmer@jelmer.uk-20180402132010-wksdm108u015hlln
Use parse_rsync_url from dulwich.

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
from ....tests import TestCase
22
22
from ..urls import (
23
23
    git_url_to_bzr_url,
24
 
    parse_git_url,
25
24
    )
26
25
 
27
26
 
28
 
class TestParseGitURL(TestCase):
29
 
 
30
 
    def test_simple(self):
31
 
        self.assertEqual(
32
 
                parse_git_url('foo:bar/path'),
33
 
                (None, 'foo', 'bar/path'))
34
 
        self.assertEqual(
35
 
                parse_git_url('user@foo:bar/path'),
36
 
                ('user', 'foo', 'bar/path'))
37
 
        self.assertRaises(ValueError, parse_git_url, '/path')
38
 
 
39
 
 
40
27
class TestConvertURL(TestCase):
41
28
 
42
29
    def test_simple(self):