diff options
author | Lin Jen-Shin <godfat@godfat.org> | 2018-04-24 21:50:57 +0800 |
---|---|---|
committer | Lin Jen-Shin <godfat@godfat.org> | 2018-04-24 21:50:57 +0800 |
commit | a10d8adf315b4945c7e3149ce81b0ea7c35ba376 (patch) | |
tree | 8b712d55c49bf400c89b7aead93f34f3f1823bdb /qa/qa/git | |
parent | 1421469e221a14b9250d162f42e3b418528a501d (diff) | |
download | gitlab-ce-a10d8adf315b4945c7e3149ce81b0ea7c35ba376.tar.gz |
Rename location to uri; Handle uri for HTTP; Fix pushing remote
Diffstat (limited to 'qa/qa/git')
-rw-r--r-- | qa/qa/git/location.rb | 2 | ||||
-rw-r--r-- | qa/qa/git/repository.rb | 3 |
2 files changed, 2 insertions, 3 deletions
diff --git a/qa/qa/git/location.rb b/qa/qa/git/location.rb index 30538388530..b74f38f3ae3 100644 --- a/qa/qa/git/location.rb +++ b/qa/qa/git/location.rb @@ -14,7 +14,7 @@ module QA def initialize(git_uri) @git_uri = git_uri @uri = - if git_uri.start_with?('ssh://') + if git_uri =~ %r{\A(?:ssh|http|https)://} URI.parse(git_uri) else *rest, path = git_uri.split(':') diff --git a/qa/qa/git/repository.rb b/qa/qa/git/repository.rb index 7aef0fd4c7a..1367671e3ca 100644 --- a/qa/qa/git/repository.rb +++ b/qa/qa/git/repository.rb @@ -15,8 +15,7 @@ module QA end end - def location=(address) - @location = address + def uri=(address) @uri = URI(address) end |