diff options
author | Shinya Maeda <gitlab.shinyamaeda@gmail.com> | 2017-03-21 16:21:13 +0300 |
---|---|---|
committer | Shinya Maeda <gitlab.shinyamaeda@gmail.com> | 2017-03-23 11:11:49 +0300 |
commit | a375d80eb072d62962af9b6f2decf9782cd7ee1f (patch) | |
tree | 4cea31ebfcac1b9dcc42ea51a951588fcecc53ce /spec/serializers/pipeline_serializer_spec.rb | |
parent | 6dcd2d591fa00be027b92e8c0e6b3b129921f4fa (diff) |
Use detailed_status effectively. Remove unnecesarry context(nest). Add new context in merge_requests_controller_spec.rb and fix a bug. Correct description of spec.
Diffstat (limited to 'spec/serializers/pipeline_serializer_spec.rb')
-rw-r--r-- | spec/serializers/pipeline_serializer_spec.rb | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/spec/serializers/pipeline_serializer_spec.rb b/spec/serializers/pipeline_serializer_spec.rb index 261f2152c22..8642b803844 100644 --- a/spec/serializers/pipeline_serializer_spec.rb +++ b/spec/serializers/pipeline_serializer_spec.rb @@ -97,10 +97,8 @@ describe PipelineSerializer do describe '#represent_status' do context 'when represents only status' do - let(:status) do - Gitlab::Ci::Status::Success.new(double('object'), double('user')) - end - let(:resource) { create(:ci_pipeline, status: :success) } + let(:resource) { create(:ci_pipeline) } + let(:status) { resource.detailed_status(double('user')) } subject { serializer.represent_status(resource) } |