Admin area improved

This commit is contained in:
Dmitriy Zaporozhets 2012-02-11 19:56:18 +02:00
parent a769204ff4
commit cc043f32d8
39 changed files with 434 additions and 334 deletions

View file

@ -18,7 +18,6 @@ describe "Admin::Projects" do
end
it "should have projects list" do
page.should have_content(@project.code)
page.should have_content(@project.name)
end
end
@ -103,4 +102,18 @@ describe "Admin::Projects" do
page.should have_content(@project.description)
end
end
describe "Add new team member" do
before do
@new_user = Factory :user
visit admin_project_path(@project)
end
it "should create new user" do
select @new_user.name, :from => "user_ids"
expect { click_button "Add" }.to change { UsersProject.count }.by(1)
page.should have_content @new_user.name
current_path.should == admin_project_path(@project)
end
end
end