summaryrefslogtreecommitdiff
path: root/spec/lib/gitlab/ci
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2017-05-03 12:27:30 +0200
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2017-05-03 12:27:30 +0200
commit738bf2c23891467dbc9c74d08223fd3c4e432ae7 (patch)
tree46f3aecaa33309822710a3aac2bb211a4855b37b /spec/lib/gitlab/ci
parenteb45582f55cae42acc41fa228f4797b4067c01dc (diff)
parent40cc917a9c07263db062c03f62c8056ed40197bd (diff)
downloadgitlab-ce-738bf2c23891467dbc9c74d08223fd3c4e432ae7.tar.gz
Merge branch 'master' into feature/gb/manual-actions-protected-branches-permissions
* master: (103 commits) Include missing project attributes to Import/Export Create the rest of the wiki docs Fill in information about creating the wiki Home page Move wiki doc to its own index page Create initial file for Wiki documentation Default to null user when asignee is unselected Re-enable ref operations with gitaly after not-found fix #31560 Add repo parameter to gitaly:install and workhorse:install Remove N+1 queries when checking nodes visible to user Don't validate reserved words if the format doesn't match Revert "Shorten and improve some job names" Remove unused initializer DRY the `<<: *except-docs` a bit in `.gitlab-ci.yml` Make the static-analysis job be run for docs branches too Add download_snippet_path helper Refresh the markdown cache if it was `nil` Add some documentation for the new migration helpers Update comments Display comments for personal snippets Update docs on creating a project ...
Diffstat (limited to 'spec/lib/gitlab/ci')
-rw-r--r--spec/lib/gitlab/ci/build/credentials/factory_spec.rb4
-rw-r--r--spec/lib/gitlab/ci/build/credentials/registry_spec.rb6
2 files changed, 5 insertions, 5 deletions
diff --git a/spec/lib/gitlab/ci/build/credentials/factory_spec.rb b/spec/lib/gitlab/ci/build/credentials/factory_spec.rb
index 10b4b7a8826..d53db05e5e6 100644
--- a/spec/lib/gitlab/ci/build/credentials/factory_spec.rb
+++ b/spec/lib/gitlab/ci/build/credentials/factory_spec.rb
@@ -3,14 +3,14 @@ require 'spec_helper'
describe Gitlab::Ci::Build::Credentials::Factory do
let(:build) { create(:ci_build, name: 'spinach', stage: 'test', stage_idx: 0) }
- subject { Gitlab::Ci::Build::Credentials::Factory.new(build).create! }
+ subject { described_class.new(build).create! }
class TestProvider
def initialize(build); end
end
before do
- allow_any_instance_of(Gitlab::Ci::Build::Credentials::Factory).to receive(:providers).and_return([TestProvider])
+ allow_any_instance_of(described_class).to receive(:providers).and_return([TestProvider])
end
context 'when provider is valid' do
diff --git a/spec/lib/gitlab/ci/build/credentials/registry_spec.rb b/spec/lib/gitlab/ci/build/credentials/registry_spec.rb
index 84e44dd53e2..c6054138cde 100644
--- a/spec/lib/gitlab/ci/build/credentials/registry_spec.rb
+++ b/spec/lib/gitlab/ci/build/credentials/registry_spec.rb
@@ -4,14 +4,14 @@ describe Gitlab::Ci::Build::Credentials::Registry do
let(:build) { create(:ci_build, name: 'spinach', stage: 'test', stage_idx: 0) }
let(:registry_url) { 'registry.example.com:5005' }
- subject { Gitlab::Ci::Build::Credentials::Registry.new(build) }
+ subject { described_class.new(build) }
before do
stub_container_registry_config(host_port: registry_url)
end
it 'contains valid DockerRegistry credentials' do
- expect(subject).to be_kind_of(Gitlab::Ci::Build::Credentials::Registry)
+ expect(subject).to be_kind_of(described_class)
expect(subject.username).to eq 'gitlab-ci-token'
expect(subject.password).to eq build.token
@@ -20,7 +20,7 @@ describe Gitlab::Ci::Build::Credentials::Registry do
end
describe '.valid?' do
- subject { Gitlab::Ci::Build::Credentials::Registry.new(build).valid? }
+ subject { described_class.new(build).valid? }
context 'when registry is enabled' do
before do