changing table user acceptance specs in the green

This commit is contained in:
2014-06-25 16:11:29 +02:00
parent 0e4993e8a6
commit 58f0937570
9 changed files with 89 additions and 45 deletions
@@ -14,8 +14,9 @@ step "the uses indicates in the popup that he wants to change the table" do
end
step "the user should see the supplier menu having the other table as base" do
route_should_be 'user#list_products'
find('.table-number').text.should == @other_table.number.to_s
#route_should_be 'user#list_products'
page.should have_content 'Apple pie'
find('.table-number').text.should == "Tafel #{@other_table.number.to_s}"
end
step "the user list should have been moved to the other table" do
@@ -32,7 +33,12 @@ step "there is another table with an active list of another user" do
end
step "the user scans a QR code of another not occupied table" do
page.execute_script "Quser.actions_for_table({table_id: '#{@other_table.id}'})"
r = page.evaluate_script %|
c = App.__container__.lookup('controller:select_qrcode');
c.send('selectQr', {_id: "#{@other_table.id}"});
c.toString()
|
#page.execute_script "Quser.actions_for_table({table_id: '#{@other_table.id}'})"
end
step "the user scans a QR code of another occupied table" do