summaryrefslogtreecommitdiff
path: root/spec/features/projects
diff options
context:
space:
mode:
authorRémy Coutable <remy@rymai.me>2016-04-13 17:00:22 +0200
committerRémy Coutable <remy@rymai.me>2016-04-18 14:47:50 +0200
commitb2370fefad16b6b0a808a75b9a7b1d1613187693 (patch)
tree4b785c0a5a418d8beee7587d67b8f0cbe39bb10e /spec/features/projects
parent2f18c77e1b0e3b6f3d668c3cb1814d4675641a75 (diff)
downloadgitlab-ce-b2370fefad16b6b0a808a75b9a7b1d1613187693.tar.gz
Fix specs
Signed-off-by: Rémy Coutable <remy@rymai.me>
Diffstat (limited to 'spec/features/projects')
-rw-r--r--spec/features/projects/files/project_owner_creates_license_file_spec.rb2
-rw-r--r--spec/features/projects/files/project_owner_sees_link_to_create_license_file_in_empty_project_spec.rb9
2 files changed, 7 insertions, 4 deletions
diff --git a/spec/features/projects/files/project_owner_creates_license_file_spec.rb b/spec/features/projects/files/project_owner_creates_license_file_spec.rb
index c0fcfd06932..3d6ffbc4c6b 100644
--- a/spec/features/projects/files/project_owner_creates_license_file_spec.rb
+++ b/spec/features/projects/files/project_owner_creates_license_file_spec.rb
@@ -1,6 +1,6 @@
require 'spec_helper'
-feature 'creates a license file', feature: true, js: true do
+feature 'project owner creates a license file', feature: true, js: true do
include Select2Helper
let(:project_master) { create(:user) }
diff --git a/spec/features/projects/files/project_owner_sees_link_to_create_license_file_in_empty_project_spec.rb b/spec/features/projects/files/project_owner_sees_link_to_create_license_file_in_empty_project_spec.rb
index 6c51d00d813..3268e240200 100644
--- a/spec/features/projects/files/project_owner_sees_link_to_create_license_file_in_empty_project_spec.rb
+++ b/spec/features/projects/files/project_owner_sees_link_to_create_license_file_in_empty_project_spec.rb
@@ -1,17 +1,18 @@
require 'spec_helper'
-feature 'creates a license file in empty project', feature: true, js: true do
+feature 'project owner sees a link to create a license file in empty project', feature: true, js: true do
include Select2Helper
let(:project_master) { create(:user) }
- let(:project) { create(:project_empty_repo) }
+ let(:project) { create(:empty_project) }
background do
project.team << [project_master, :master]
login_as(project_master)
- visit namespace_project_path(project.namespace, project)
end
scenario 'project master creates a license file from a template' do
+ visit namespace_project_path(project.namespace, project)
+ click_link 'Create empty bare repository'
click_on 'LICENSE'
expect(current_path).to eq(
@@ -26,6 +27,8 @@ feature 'creates a license file in empty project', feature: true, js: true do
expect(file_content).to have_content("Copyright (c) 2016 #{project.namespace.human_name}")
fill_in :commit_message, with: 'Add a LICENSE file', visible: true
+ # Remove pre-receive hook so we can push without auth
+ FileUtils.rm_f(File.join(project.repository.path, 'hooks', 'pre-receive'))
click_button 'Commit Changes'
expect(current_path).to eq(