Commit 23712d20 authored by Kamil Trzcinski's avatar Kamil Trzcinski

Fix failures

parent 8367e91f
...@@ -5,13 +5,9 @@ FactoryGirl.define do ...@@ -5,13 +5,9 @@ FactoryGirl.define do
source.source_pipeline ||= source.source_job.pipeline source.source_pipeline ||= source.source_job.pipeline
source.source_project ||= source.source_pipeline.project source.source_project ||= source.source_pipeline.project
end end
trait :create_source do source_job factory: :ci_build
source_job factory: :ci_build
end pipeline factory: :ci_empty_pipeline
trait :create_target do
pipeline factory: :ci_empty_pipeline
end
end end
end end
...@@ -121,7 +121,7 @@ describe PipelineDetailsEntity do ...@@ -121,7 +121,7 @@ describe PipelineDetailsEntity do
let(:pipeline) { create(:ci_empty_pipeline) } let(:pipeline) { create(:ci_empty_pipeline) }
before do before do
create(:ci_sources_pipeline, :create_source, pipeline: pipeline) create(:ci_sources_pipeline, pipeline: pipeline)
end end
it 'contains an information about depedent pipeline' do it 'contains an information about depedent pipeline' do
...@@ -138,8 +138,8 @@ describe PipelineDetailsEntity do ...@@ -138,8 +138,8 @@ describe PipelineDetailsEntity do
let(:build) { create(:ci_build, pipeline: pipeline) } let(:build) { create(:ci_build, pipeline: pipeline) }
before do before do
create(:ci_sources_pipeline, :create_target, source_job: build) create(:ci_sources_pipeline, source_job: build)
create(:ci_sources_pipeline, :create_target, source_job: build) create(:ci_sources_pipeline, source_job: build)
end end
it 'contains an information about depedent pipeline' do it 'contains an information about depedent pipeline' do
......
...@@ -45,7 +45,7 @@ describe ExpirePipelineCacheWorker do ...@@ -45,7 +45,7 @@ describe ExpirePipelineCacheWorker do
context 'when pipeline is triggered by other pipeline' do context 'when pipeline is triggered by other pipeline' do
let(:pipeline) { create(:ci_empty_pipeline) } let(:pipeline) { create(:ci_empty_pipeline) }
let(:source) { create(:ci_sources_pipeline, :create_source, pipeline: pipeline) } let(:source) { create(:ci_sources_pipeline, pipeline: pipeline) }
it 'updates the cache of dependent pipeline' do it 'updates the cache of dependent pipeline' do
dependent_pipeline_path = "/#{source.source_project.full_path}/pipelines/#{source.source_pipeline.id}.json" dependent_pipeline_path = "/#{source.source_project.full_path}/pipelines/#{source.source_pipeline.id}.json"
...@@ -60,7 +60,7 @@ describe ExpirePipelineCacheWorker do ...@@ -60,7 +60,7 @@ describe ExpirePipelineCacheWorker do
context 'when pipeline triggered other pipeline' do context 'when pipeline triggered other pipeline' do
let(:pipeline) { create(:ci_empty_pipeline) } let(:pipeline) { create(:ci_empty_pipeline) }
let(:build) { create(:ci_build, pipeline: pipeline) } let(:build) { create(:ci_build, pipeline: pipeline) }
let(:source) { create(:ci_sources_pipeline, :create_target, source_job: build) } let(:source) { create(:ci_sources_pipeline, source_job: build) }
it 'updates the cache of dependent pipeline' do it 'updates the cache of dependent pipeline' do
dependent_pipeline_path = "/#{source.project.full_path}/pipelines/#{source.pipeline.id}.json" dependent_pipeline_path = "/#{source.project.full_path}/pipelines/#{source.pipeline.id}.json"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment