Add support for ssh protocol
This commit is contained in:
parent
82eddd8828
commit
7b5ff6b642
6 changed files with 56 additions and 28 deletions
9
dist/src/test_common.py
vendored
9
dist/src/test_common.py
vendored
|
|
@ -10,9 +10,16 @@ def test_get_random_string():
|
|||
|
||||
|
||||
def test_parse_github_repository_success():
|
||||
repository = cmn.parse_github_repository(
|
||||
protocol, repository = cmn.parse_github_repository(
|
||||
"https://github.com/peter-evans/create-pull-request"
|
||||
)
|
||||
assert protocol == "HTTPS"
|
||||
assert repository == "peter-evans/create-pull-request"
|
||||
|
||||
protocol, repository = cmn.parse_github_repository(
|
||||
"git@github.com:peter-evans/create-pull-request.git"
|
||||
)
|
||||
assert protocol == "SSH"
|
||||
assert repository == "peter-evans/create-pull-request"
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue