Finish select2-ajax for users. Added Select2Helper for tests

This commit is contained in:
Dmitriy Zaporozhets 2013-03-14 10:16:27 +02:00
parent 10f14136f5
commit ef05423f47
11 changed files with 256 additions and 222 deletions

View file

@ -2,6 +2,7 @@ class ProjectTeamManagement < Spinach::FeatureSteps
include SharedAuthentication
include SharedProject
include SharedPaths
include Select2Helper
Then 'I should be able to see myself in team' do
page.should have_content(@user.name)
@ -20,8 +21,9 @@ class ProjectTeamManagement < Spinach::FeatureSteps
And 'I select "Mike" as "Reporter"' do
user = User.find_by_name("Mike")
select2(user.id, from: "#user_ids", multiple: true)
within "#new_team_member" do
select "#{user.name} (#{user.username})", :from => "user_ids"
select "Reporter", :from => "project_access"
end
click_button "Add users"