2014-10-02 12:42:54 -04:00
|
|
|
class Spinach::Features::ProjectCreate < Spinach::FeatureSteps
|
2012-09-10 11:35:03 -04:00
|
|
|
include SharedAuthentication
|
|
|
|
include SharedPaths
|
2015-12-08 20:02:53 -05:00
|
|
|
include SharedUser
|
2012-09-10 09:35:23 -04:00
|
|
|
|
2014-09-21 17:40:22 -04:00
|
|
|
step 'fill project form with valid data' do
|
2014-12-22 08:02:47 -05:00
|
|
|
fill_in 'project_path', with: 'Empty'
|
2017-05-29 04:24:53 -04:00
|
|
|
page.within '#content-body' do
|
|
|
|
click_button "Create project"
|
2017-06-29 13:06:35 -04:00
|
|
|
end
|
2012-09-10 09:35:23 -04:00
|
|
|
end
|
|
|
|
|
2014-09-21 17:40:22 -04:00
|
|
|
step 'I should see project page' do
|
2015-06-12 00:44:13 -04:00
|
|
|
expect(page).to have_content "Empty"
|
2017-06-29 13:06:35 -04:00
|
|
|
expect(current_path).to eq project_path(Project.last)
|
2012-09-10 09:35:23 -04:00
|
|
|
end
|
|
|
|
|
2016-05-04 17:05:16 -04:00
|
|
|
step 'I should see empty project instructions' do
|
2015-06-12 00:44:13 -04:00
|
|
|
expect(page).to have_content "git init"
|
|
|
|
expect(page).to have_content "git remote"
|
|
|
|
expect(page).to have_content Project.last.url_to_repo
|
2012-09-10 09:35:23 -04:00
|
|
|
end
|
|
|
|
end
|