diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-21 15:09:05 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-02-21 15:09:05 +0000 |
commit | cf6a3e7ed4cb10a3e9fcbda810601387afc8b8d6 (patch) | |
tree | bda3707e95a53cb225793fded61d5073950b0b68 /qa/spec | |
parent | 2a040e2655fe0a99df61ad0a7bd0c27e68af0c38 (diff) | |
download | gitlab-ce-cf6a3e7ed4cb10a3e9fcbda810601387afc8b8d6.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'qa/spec')
-rw-r--r-- | qa/spec/git/repository_spec.rb | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/qa/spec/git/repository_spec.rb b/qa/spec/git/repository_spec.rb index 5198eb6f58b..6cca9f55e11 100644 --- a/qa/spec/git/repository_spec.rb +++ b/qa/spec/git/repository_spec.rb @@ -69,18 +69,20 @@ describe QA::Git::Repository do end describe '#fetch_supported_git_protocol' do + Result = Struct.new(:response) + it "reports the detected version" do - expect(repository).to receive(:run).and_return("packet: git< version 2") + expect(repository).to receive(:run).and_return(Result.new("packet: git< version 2")) expect(repository.fetch_supported_git_protocol).to eq('2') end it 'reports unknown if version is unknown' do - expect(repository).to receive(:run).and_return("packet: git< version -1") + expect(repository).to receive(:run).and_return(Result.new("packet: git< version -1")) expect(repository.fetch_supported_git_protocol).to eq('unknown') end it 'reports unknown if content does not identify a version' do - expect(repository).to receive(:run).and_return("foo") + expect(repository).to receive(:run).and_return(Result.new("foo")) expect(repository.fetch_supported_git_protocol).to eq('unknown') end end |