Better user specs for joining tables
This commit is contained in:
@@ -10,3 +10,16 @@ step "the user should be redirected to the archived list path" do
|
||||
route_should_be 'user#history_list'
|
||||
page.should have_selector ".order-row-#{@order.id}"
|
||||
end
|
||||
|
||||
step 'there is another user' do
|
||||
@other_user ||= create :user
|
||||
end
|
||||
|
||||
step "the other user clicks the join table button" do
|
||||
find('.join-table-button').click
|
||||
end
|
||||
|
||||
step "the other user should be redirected to the user menu page" do
|
||||
Capybara.session_name = :other_user
|
||||
route_should_be 'user#list_products'
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user