| ... | @@ -34,19 +34,17 @@ describe "Projects" do |
... | @@ -34,19 +34,17 @@ describe "Projects" do |
|
|
end
|
|
end
|
|
|
|
|
|
|
|
it "should have labels for new project" do
|
|
it "should have labels for new project" do
|
|
|
page.should have_content("Name")
|
|
page.should have_content("Project name is")
|
|
|
page.should have_content("Path")
|
|
|
|
|
page.should have_content("Description")
|
|
|
|
|
end
|
|
end
|
|
|
end
|
|
end
|
|
|
|
|
|
|
|
describe "POST /projects" do
|
|
describe "POST /projects" do
|
|
|
before do
|
|
before do
|
|
|
visit new_project_path
|
|
visit new_project_path
|
|
|
fill_in 'Name', :with => 'NewProject'
|
|
fill_in 'project_name', :with => 'NewProject'
|
|
|
fill_in 'Code', :with => 'NPR'
|
|
fill_in 'project_code', :with => 'NPR'
|
|
|
fill_in 'Path', :with => 'newproject'
|
|
fill_in 'project_path', :with => 'newproject'
|
|
|
expect { click_button "Save" }.to change { Project.count }.by(1)
|
|
expect { click_button "Create project" }.to change { Project.count }.by(1)
|
|
|
@project = Project.last
|
|
@project = Project.last
|
|
|
end
|
|
end
|
|
|
|
|
|
| ... | @@ -120,9 +118,9 @@ describe "Projects" do |
... | @@ -120,9 +118,9 @@ describe "Projects" do |
|
|
end
|
|
end
|
|
|
|
|
|
|
|
it "should have labels for new project" do
|
|
it "should have labels for new project" do
|
|
|
page.should have_content("Name")
|
|
page.should have_content("Project name is")
|
|
|
page.should have_content("Path")
|
|
page.should have_content("Advanced settings:")
|
|
|
page.should have_content("Description")
|
|
page.should have_content("Features:")
|
|
|
end
|
|
end
|
|
|
end
|
|
end
|
|
|
|
|
|
| ... | @@ -133,9 +131,8 @@ describe "Projects" do |
... | @@ -133,9 +131,8 @@ describe "Projects" do |
|
|
|
|
|
|
|
visit edit_project_path(@project)
|
|
visit edit_project_path(@project)
|
|
|
|
|
|
|
|
fill_in 'Name', :with => 'Awesome'
|
|
fill_in 'project_name', :with => 'Awesome'
|
|
|
fill_in 'Path', :with => 'gitlabhq'
|
|
fill_in 'project_path', :with => 'gitlabhq'
|
|
|
fill_in 'Description', :with => 'Awesome project'
|
|
|
|
|
click_button "Save"
|
|
click_button "Save"
|
|
|
@project = @project.reload
|
|
@project = @project.reload
|
|
|
end
|
|
end
|
| ... | |
... | |
| ... | | ... | |