Commit 96ef1f01 authored by Vitali Tatarintev's avatar Vitali Tatarintev

Replace let with let_it_be

parent f6f3d8b8
...@@ -14,9 +14,9 @@ RSpec.describe Projects::Settings::CiCdController do ...@@ -14,9 +14,9 @@ RSpec.describe Projects::Settings::CiCdController do
end end
describe 'GET show' do describe 'GET show' do
let(:parent_group) { create(:group) } let_it_be(:parent_group) { create(:group) }
let(:group) { create(:group, parent: parent_group) } let_it_be(:group) { create(:group, parent: parent_group) }
let(:other_project) { create(:project, group: group) } let_it_be(:other_project) { create(:project, group: group) }
it 'renders show with 200 status code' do it 'renders show with 200 status code' do
get :show, params: { namespace_id: project.namespace, project_id: project } get :show, params: { namespace_id: project.namespace, project_id: project }
...@@ -26,9 +26,9 @@ RSpec.describe Projects::Settings::CiCdController do ...@@ -26,9 +26,9 @@ RSpec.describe Projects::Settings::CiCdController do
end end
context 'with group runners' do context 'with group runners' do
let(:group_runner) { create(:ci_runner, :group, groups: [group]) } let_it_be(:group_runner) { create(:ci_runner, :group, groups: [group]) }
let!(:project_runner) { create(:ci_runner, :project, projects: [other_project]) } let_it_be(:project_runner) { create(:ci_runner, :project, projects: [other_project]) }
let!(:shared_runner) { create(:ci_runner, :instance) } let_it_be(:shared_runner) { create(:ci_runner, :instance) }
it 'sets assignable project runners only' do it 'sets assignable project runners only' do
group.add_maintainer(user) group.add_maintainer(user)
......
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