Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/services/ci/create_downstream_pipeline_service_spec.rb')
-rw-r--r--spec/services/ci/create_downstream_pipeline_service_spec.rb7
1 files changed, 5 insertions, 2 deletions
diff --git a/spec/services/ci/create_downstream_pipeline_service_spec.rb b/spec/services/ci/create_downstream_pipeline_service_spec.rb
index c990d195e51..e2c42ab04d0 100644
--- a/spec/services/ci/create_downstream_pipeline_service_spec.rb
+++ b/spec/services/ci/create_downstream_pipeline_service_spec.rb
@@ -5,9 +5,12 @@ require 'spec_helper'
RSpec.describe Ci::CreateDownstreamPipelineService, '#execute' do
include Ci::SourcePipelineHelpers
- let_it_be(:user) { create(:user) }
+ # Using let_it_be on user and projects for these specs can cause
+ # spec-ordering failures due to the project-based permissions
+ # associating them. They should be recreated every time.
+ let(:user) { create(:user) }
let(:upstream_project) { create(:project, :repository) }
- let_it_be(:downstream_project, refind: true) { create(:project, :repository) }
+ let(:downstream_project) { create(:project, :repository) }
let!(:upstream_pipeline) do
create(:ci_pipeline, :running, project: upstream_project)