Files
mozo-backend/spec/acceptance_steps/global_user_steps.rb
T

30 lines
732 B
Ruby

step "I am on the user homepage" do
step "the user is on the homepage"
end
step "the user is on the homepage" do
visit user_root_path
end
step "the user should be redirected to the user order overview page" do
route_should_be 'user#active_list'
end
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