2014-09-22 10:30:25 -04:00
|
|
|
class Spinach::Features::ProjectIssueTracker < Spinach::FeatureSteps
|
2013-11-01 10:33:47 -04:00
|
|
|
include SharedAuthentication
|
|
|
|
include SharedProject
|
|
|
|
include SharedPaths
|
|
|
|
|
|
|
|
step 'project "Shop" has issues enabled' do
|
2014-01-19 13:55:59 -05:00
|
|
|
@project = Project.find_by(name: "Shop")
|
2014-01-22 14:03:52 -05:00
|
|
|
@project ||= create(:project, name: "Shop", namespace: @user.namespace)
|
2013-11-01 10:33:47 -04:00
|
|
|
@project.issues_enabled = true
|
|
|
|
end
|
|
|
|
|
|
|
|
step 'change the issue tracker to "GitLab"' do
|
|
|
|
select 'GitLab', from: 'project_issues_tracker'
|
|
|
|
end
|
|
|
|
|
|
|
|
step 'I the project should have "GitLab" as issue tracker' do
|
|
|
|
find_field('project_issues_tracker').value.should == 'gitlab'
|
|
|
|
end
|
|
|
|
|
|
|
|
step 'change the issue tracker to "Redmine"' do
|
|
|
|
select 'Redmine', from: 'project_issues_tracker'
|
|
|
|
end
|
|
|
|
|
|
|
|
step 'I the project should have "Redmine" as issue tracker' do
|
|
|
|
find_field('project_issues_tracker').value.should == 'redmine'
|
|
|
|
end
|
|
|
|
|
2014-09-21 17:40:22 -04:00
|
|
|
step 'I save project' do
|
2013-11-01 10:33:47 -04:00
|
|
|
click_button 'Save changes'
|
|
|
|
end
|
|
|
|
end
|