summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorShinya Maeda <shinya@gitlab.com>2017-08-22 22:59:08 +0900
committerShinya Maeda <shinya@gitlab.com>2017-09-03 23:49:10 +0900
commit1925bfd2a5b8fab48de8b1f2a4ae7db6a09736e1 (patch)
tree59b80df5134388f857a051babf59c4e35d47e209 /spec
parentbbe967abeba7be1db79e34439e74cd113c240b52 (diff)
downloadgitlab-ce-1925bfd2a5b8fab48de8b1f2a4ae7db6a09736e1.tar.gz
Fix spec
Diffstat (limited to 'spec')
-rw-r--r--spec/lib/gitlab/import_export/safe_model_attributes.yml1
-rw-r--r--spec/models/ci/runner_spec.rb8
-rw-r--r--spec/services/ci/retry_build_service_spec.rb2
3 files changed, 6 insertions, 5 deletions
diff --git a/spec/lib/gitlab/import_export/safe_model_attributes.yml b/spec/lib/gitlab/import_export/safe_model_attributes.yml
index a5e03e149a7..8c4810f292e 100644
--- a/spec/lib/gitlab/import_export/safe_model_attributes.yml
+++ b/spec/lib/gitlab/import_export/safe_model_attributes.yml
@@ -276,6 +276,7 @@ CommitStatus:
- coverage_regex
- auto_canceled_by_id
- retried
+- protected
Ci::Variable:
- id
- project_id
diff --git a/spec/models/ci/runner_spec.rb b/spec/models/ci/runner_spec.rb
index 45a64b6f76f..a04d4615b6b 100644
--- a/spec/models/ci/runner_spec.rb
+++ b/spec/models/ci/runner_spec.rb
@@ -464,8 +464,8 @@ describe Ci::Runner do
end
it 'a protected runner exists' do
- expect(Ci::Runner.count).to eq(1)
- expect(Ci::Runner.last.protected_?).to eq(true)
+ expect(described_class.count).to eq(1)
+ expect(described_class.last.protected_?).to eq(true)
end
end
@@ -475,8 +475,8 @@ describe Ci::Runner do
end
it 'an unprotected runner exists' do
- expect(Ci::Runner.count).to eq(1)
- expect(Ci::Runner.last.unprotected?).to eq(true)
+ expect(described_class.count).to eq(1)
+ expect(described_class.last.unprotected?).to eq(true)
end
end
end
diff --git a/spec/services/ci/retry_build_service_spec.rb b/spec/services/ci/retry_build_service_spec.rb
index cec667071cc..d32ed9c33ee 100644
--- a/spec/services/ci/retry_build_service_spec.rb
+++ b/spec/services/ci/retry_build_service_spec.rb
@@ -22,7 +22,7 @@ describe Ci::RetryBuildService do
%i[type lock_version target_url base_tags
commit_id deployments erased_by_id last_deployment project_id
runner_id tag_taggings taggings tags trigger_request_id
- user_id auto_canceled_by_id retried].freeze
+ user_id auto_canceled_by_id retried protected].freeze
shared_examples 'build duplication' do
let(:stage) do