Commit bde0a2c1 authored by Vitali Tatarintev's avatar Vitali Tatarintev

Change set to let_it_be in ee/spec/helpers

Contributes to https://gitlab.com/gitlab-org/gitlab/issues/27922
parent 4ebe48cd
......@@ -6,9 +6,9 @@ describe EE::GitlabRoutingHelper do
include ProjectsHelper
include ApplicationSettingsHelper
set(:primary) { create(:geo_node, :primary, url: 'http://localhost:123/relative', clone_url_prefix: 'git@localhost:') }
set(:group) { create(:group, path: 'foo') }
set(:project) { create(:project, namespace: group, path: 'bar') }
let_it_be(:primary, reload: true) { create(:geo_node, :primary, url: 'http://localhost:123/relative', clone_url_prefix: 'git@localhost:') }
let_it_be(:group, reload: true) { create(:group, path: 'foo') }
let_it_be(:project, reload: true) { create(:project, namespace: group, path: 'bar') }
describe '#geo_primary_web_url' do
before do
......
......@@ -13,7 +13,7 @@ describe EE::ServicesHelper do
end
end
set(:project) { create(:project) }
let_it_be(:project) { create(:project) }
subject { controller_class.new }
......
......@@ -3,16 +3,16 @@
require 'spec_helper'
describe ::TodosHelper do
set(:user) { create(:user) }
set(:author) { create(:user) }
set(:issue) { create(:issue) }
set(:design) { create(:design, issue: issue) }
set(:note) do
let_it_be(:user) { create(:user) }
let_it_be(:author) { create(:user) }
let_it_be(:issue) { create(:issue) }
let_it_be(:design) { create(:design, issue: issue) }
let_it_be(:note) do
create(:note,
project: issue.project,
note: "I am note, hear me roar")
end
set(:design_todo) do
let_it_be(:design_todo) do
create(:todo, :mentioned,
user: user,
project: issue.project,
......
......@@ -173,8 +173,8 @@ describe EE::UserCalloutsHelper do
describe '#render_dashboard_gold_trial' do
using RSpec::Parameterized::TableSyntax
set(:namespace) { create(:namespace) }
set(:gold_plan) { create(:gold_plan) }
let_it_be(:namespace) { create(:namespace) }
let_it_be(:gold_plan) { create(:gold_plan) }
let(:user) { namespace.owner }
where(:has_some_namespaces_with_no_trials?, :show_gold_trial?, :user_default_dashboard?, :has_no_trial_or_gold_plan?, :should_render?) do
......@@ -220,9 +220,9 @@ describe EE::UserCalloutsHelper do
using RSpec::Parameterized::TableSyntax
let(:namespace) { create(:namespace) }
set(:free_plan) { create(:free_plan) }
set(:silver_plan) { create(:silver_plan) }
set(:gold_plan) { create(:gold_plan) }
let_it_be(:free_plan) { create(:free_plan) }
let_it_be(:silver_plan) { create(:silver_plan) }
let_it_be(:gold_plan) { create(:gold_plan) }
let(:user) { namespace.owner }
let(:gitlab_subscription) { create(:gitlab_subscription, namespace: namespace) }
......
......@@ -3,7 +3,7 @@
require 'spec_helper'
describe FeatureFlagsHelper do
set(:project) { create(:project) }
let_it_be(:project) { create(:project) }
context '#unleash_api_url' do
subject { helper.unleash_api_url(project) }
......
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