2013-01-09 01:14:05 -05:00
|
|
|
class ProjectServices < Spinach::FeatureSteps
|
|
|
|
include SharedAuthentication
|
|
|
|
include SharedProject
|
|
|
|
include SharedPaths
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I visit project "Shop" services page' do
|
2013-01-09 01:14:05 -05:00
|
|
|
visit project_services_path(@project)
|
|
|
|
end
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I should see list of available services' do
|
2013-12-18 09:27:52 -05:00
|
|
|
page.should have_content 'Project services'
|
2013-05-22 11:10:51 -04:00
|
|
|
page.should have_content 'Campfire'
|
2013-05-23 14:10:32 -04:00
|
|
|
page.should have_content 'Hipchat'
|
2013-01-09 01:14:05 -05:00
|
|
|
page.should have_content 'GitLab CI'
|
2013-11-21 07:18:02 -05:00
|
|
|
page.should have_content 'Assembla'
|
2013-01-09 01:14:05 -05:00
|
|
|
end
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I click gitlab-ci service link' do
|
2013-01-09 01:14:05 -05:00
|
|
|
click_link 'GitLab CI'
|
|
|
|
end
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I fill gitlab-ci settings' do
|
2013-01-09 01:14:05 -05:00
|
|
|
check 'Active'
|
2013-05-22 11:10:51 -04:00
|
|
|
fill_in 'Project url', with: 'http://ci.gitlab.org/projects/3'
|
|
|
|
fill_in 'Token', with: 'verySecret'
|
2013-01-09 01:14:05 -05:00
|
|
|
click_button 'Save'
|
|
|
|
end
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I should see service settings saved' do
|
2013-05-22 11:10:51 -04:00
|
|
|
find_field('Project url').value.should == 'http://ci.gitlab.org/projects/3'
|
2013-01-09 01:14:05 -05:00
|
|
|
end
|
2013-05-23 14:10:32 -04:00
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I click hipchat service link' do
|
2013-05-23 14:10:32 -04:00
|
|
|
click_link 'Hipchat'
|
|
|
|
end
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I fill hipchat settings' do
|
2013-05-23 14:10:32 -04:00
|
|
|
check 'Active'
|
|
|
|
fill_in 'Room', with: 'gitlab'
|
|
|
|
fill_in 'Token', with: 'verySecret'
|
|
|
|
click_button 'Save'
|
|
|
|
end
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I should see hipchat service settings saved' do
|
2013-05-23 14:10:32 -04:00
|
|
|
find_field('Room').value.should == 'gitlab'
|
|
|
|
end
|
|
|
|
|
2013-09-25 10:49:39 -04:00
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I click pivotaltracker service link' do
|
2013-09-25 10:49:39 -04:00
|
|
|
click_link 'PivotalTracker'
|
|
|
|
end
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I fill pivotaltracker settings' do
|
2013-09-25 10:49:39 -04:00
|
|
|
check 'Active'
|
|
|
|
fill_in 'Token', with: 'verySecret'
|
|
|
|
click_button 'Save'
|
|
|
|
end
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I should see pivotaltracker service settings saved' do
|
2013-09-25 10:49:39 -04:00
|
|
|
find_field('Token').value.should == 'verySecret'
|
|
|
|
end
|
2013-08-19 05:11:36 -04:00
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I click Flowdock service link' do
|
2013-08-19 05:11:36 -04:00
|
|
|
click_link 'Flowdock'
|
|
|
|
end
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I fill Flowdock settings' do
|
2013-08-19 05:11:36 -04:00
|
|
|
check 'Active'
|
|
|
|
fill_in 'Token', with: 'verySecret'
|
|
|
|
click_button 'Save'
|
|
|
|
end
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I should see Flowdock service settings saved' do
|
2013-08-19 05:11:36 -04:00
|
|
|
find_field('Token').value.should == 'verySecret'
|
|
|
|
end
|
2013-11-21 07:18:02 -05:00
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I click Assembla service link' do
|
2013-11-21 07:18:02 -05:00
|
|
|
click_link 'Assembla'
|
|
|
|
end
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I fill Assembla settings' do
|
2013-11-21 07:18:02 -05:00
|
|
|
check 'Active'
|
|
|
|
fill_in 'Token', with: 'verySecret'
|
|
|
|
click_button 'Save'
|
|
|
|
end
|
|
|
|
|
2013-12-17 09:29:08 -05:00
|
|
|
step 'I should see Assembla service settings saved' do
|
2013-11-21 07:18:02 -05:00
|
|
|
find_field('Token').value.should == 'verySecret'
|
|
|
|
end
|
2013-12-17 09:29:08 -05:00
|
|
|
|
|
|
|
step 'I click email on push service link' do
|
|
|
|
click_link 'Emails on push'
|
|
|
|
end
|
|
|
|
|
|
|
|
step 'I fill email on push settings' do
|
|
|
|
fill_in 'Recipients', with: 'qa@company.name'
|
|
|
|
click_button 'Save'
|
|
|
|
end
|
|
|
|
|
|
|
|
step 'I should see email on push service settings saved' do
|
|
|
|
find_field('Recipients').value.should == 'qa@company.name'
|
|
|
|
end
|
2014-03-18 13:27:03 -04:00
|
|
|
|
|
|
|
step 'I click Slack service link' do
|
|
|
|
click_link 'Slack'
|
|
|
|
end
|
|
|
|
|
|
|
|
step 'I fill Slack settings' do
|
|
|
|
check 'Active'
|
|
|
|
fill_in 'Subdomain', with: 'gitlab'
|
|
|
|
fill_in 'Room', with: '#gitlab'
|
|
|
|
fill_in 'Token', with: 'verySecret'
|
|
|
|
click_button 'Save'
|
|
|
|
end
|
|
|
|
|
|
|
|
step 'I should see Slack service settings saved' do
|
|
|
|
find_field('Subdomain').value.should == 'gitlab'
|
|
|
|
find_field('Room').value.should == '#gitlab'
|
|
|
|
find_field('Token').value.should == 'verySecret'
|
|
|
|
end
|
2013-01-09 01:14:05 -05:00
|
|
|
end
|