diff options
Diffstat (limited to 'spec/features/projects/show')
3 files changed, 9 insertions, 10 deletions
diff --git a/spec/features/projects/show/user_sees_git_instructions_spec.rb b/spec/features/projects/show/user_sees_git_instructions_spec.rb index dde9490a5e1..0c486056329 100644 --- a/spec/features/projects/show/user_sees_git_instructions_spec.rb +++ b/spec/features/projects/show/user_sees_git_instructions_spec.rb @@ -3,7 +3,7 @@ require 'spec_helper' describe 'Projects > Show > User sees Git instructions' do - set(:user) { create(:user) } + let_it_be(:user) { create(:user) } shared_examples_for 'redirects to the sign in page' do it 'redirects to the sign in page' do @@ -49,7 +49,7 @@ describe 'Projects > Show > User sees Git instructions' do context 'when project is public' do context 'when project has no repo' do - set(:project) { create(:project, :public) } + let_it_be(:project) { create(:project, :public) } before do sign_in(project.owner) @@ -60,7 +60,7 @@ describe 'Projects > Show > User sees Git instructions' do end context 'when project is empty' do - set(:project) { create(:project_empty_repo, :public) } + let_it_be(:project) { create(:project_empty_repo, :public) } context 'when not signed in' do before do @@ -98,7 +98,7 @@ describe 'Projects > Show > User sees Git instructions' do end context 'when project is not empty' do - set(:project) { create(:project, :public, :repository) } + let_it_be(:project) { create(:project, :public, :repository) } before do visit(project_path(project)) @@ -141,7 +141,7 @@ describe 'Projects > Show > User sees Git instructions' do end context 'when project is internal' do - set(:project) { create(:project, :internal, :repository) } + let_it_be(:project) { create(:project, :internal, :repository) } context 'when not signed in' do before do @@ -163,7 +163,7 @@ describe 'Projects > Show > User sees Git instructions' do end context 'when project is private' do - set(:project) { create(:project, :private) } + let_it_be(:project) { create(:project, :private) } before do visit(project_path(project)) diff --git a/spec/features/projects/show/user_sees_last_commit_ci_status_spec.rb b/spec/features/projects/show/user_sees_last_commit_ci_status_spec.rb index cf1a679102c..5aba16597b8 100644 --- a/spec/features/projects/show/user_sees_last_commit_ci_status_spec.rb +++ b/spec/features/projects/show/user_sees_last_commit_ci_status_spec.rb @@ -3,7 +3,7 @@ require 'spec_helper' describe 'Projects > Show > User sees last commit CI status' do - set(:project) { create(:project, :repository, :public) } + let_it_be(:project) { create(:project, :repository, :public) } it 'shows the project README', :js do project.enable_ci diff --git a/spec/features/projects/show/user_sees_readme_spec.rb b/spec/features/projects/show/user_sees_readme_spec.rb index 98906de4620..52745b06cd3 100644 --- a/spec/features/projects/show/user_sees_readme_spec.rb +++ b/spec/features/projects/show/user_sees_readme_spec.rb @@ -3,9 +3,8 @@ require 'spec_helper' describe 'Projects > Show > User sees README' do - set(:user) { create(:user) } - - set(:project) { create(:project, :repository, :public) } + let_it_be(:user) { create(:user) } + let_it_be(:project) { create(:project, :repository, :public) } it 'shows the project README', :js do visit project_path(project) |