def test_ssh_branch(): name, url, branch, is_url = P( '[email protected]:leanprover-community/tutorials.git:foo') assert name == 'tutorials' assert url == '[email protected]:leanprover-community/tutorials.git' assert branch == 'foo' assert is_url
def test_https_branch(): name, url, branch, is_url = P( 'https://github.com/leanprover-community/tutorials.git:foo') assert name == 'tutorials' assert url == 'https://github.com/leanprover-community/tutorials.git' assert branch == 'foo' assert is_url
def test_name(): name, url, branch, is_url = P('tutorials') assert name == 'tutorials' assert url == '[email protected]:leanprover-community/tutorials.git' assert branch == '' assert not is_url
def test_org_name_branch(): name, url, branch = P('leanprover-community/tutorials:foo') assert name == 'tutorials' assert url == '[email protected]:leanprover-community/tutorials.git' assert branch == 'foo'
def test_ssh(): name, url, branch = P('[email protected]:leanprover-community/tutorials.git') assert name == 'tutorials' assert url == '[email protected]:leanprover-community/tutorials.git' assert branch == ''
def test_https(): name, url, branch = P('https://github.com/leanprover-community/tutorials.git') assert name == 'tutorials' assert url == 'https://github.com/leanprover-community/tutorials.git' assert branch == ''