Greenification of the specs
This commit is contained in:
@@ -7,5 +7,6 @@ Feature: Getting product information during an order
|
||||
And I am signed in as a user
|
||||
And I am on the user homepage
|
||||
When the user scans a table QR code
|
||||
And the users clicks on the product category "Beer" title
|
||||
And the user clicks on the more info button for the product with name 'Heineken beer'
|
||||
Then the user page should have product information 'Brewed in Amsterdam'
|
||||
|
||||
@@ -6,9 +6,11 @@ Feature: Ordering a product as a user
|
||||
And I am signed in as a user
|
||||
And I am on the user homepage
|
||||
When the user scans a table QR code
|
||||
And the users clicks on the product category "Beer" title
|
||||
And the user clicks on the order 'Heineken beer' twice
|
||||
Then the user order 'Heineken beer' should be in the order list with price
|
||||
And the user order total should not be visible for only one order
|
||||
And the users clicks on the product category "Lunch" title
|
||||
When the user clicks on the order product button 'Apple pie'
|
||||
Then the user order total should be visible with the correct total price
|
||||
When the user clicks on the user order button
|
||||
@@ -31,6 +33,7 @@ Feature: Ordering a product as a user
|
||||
And I am signed in as a user
|
||||
And I am on the user homepage
|
||||
When the user scans a table QR code
|
||||
And the users clicks on the product category "Beer" title
|
||||
And the user clicks on the order product button 'Australian beer'
|
||||
And the user selects the product variant 'Without foam'
|
||||
Then the user order 'Australian beer' with variant 'Without foam' should be in the order list
|
||||
@@ -42,7 +45,9 @@ Feature: Ordering a product as a user
|
||||
And I am signed in as a user
|
||||
And I am on the user homepage
|
||||
When the user scans a table QR code
|
||||
And the users clicks on the product category "Beer" title
|
||||
And the user clicks on the order 'Heineken beer' twice
|
||||
And the users clicks on the product category "Lunch" title
|
||||
And the user clicks on the order product button 'Apple pie'
|
||||
And the user clicks on the clear order for the last order button
|
||||
And the user clicks on the clear order for the last order button
|
||||
@@ -64,5 +69,5 @@ Feature: Ordering a product as a user
|
||||
And the user clicks on the lists link in the side menu
|
||||
And the user opens the side menu again
|
||||
And the user clicks on the order products link in the side menu
|
||||
Then the user page contains the product category beer
|
||||
Then the user page contains the product category "Beer"
|
||||
And the user should see the products listed for the active list
|
||||
|
||||
@@ -7,11 +7,11 @@ Feature:
|
||||
And there is a table
|
||||
And I am signed in as a user
|
||||
When the user is on the order products page
|
||||
Then the user page contains the product category lunch
|
||||
Then the user page contains the product category "Lunch"
|
||||
When the product category lunch is not visible today
|
||||
And I reload the page
|
||||
Then the user page contains the product category beer
|
||||
And the user page does not contain the product category lunch
|
||||
Then the user page contains the product category "Beer"
|
||||
And the user page does not contain the product category "Lunch"
|
||||
|
||||
@javascript
|
||||
Scenario: Product category visibility by minute when inside the range
|
||||
@@ -19,11 +19,11 @@ Feature:
|
||||
And there is a table
|
||||
And I am signed in as a user
|
||||
When the user is on the order products page
|
||||
Then the user page contains the product category lunch
|
||||
Then the user page contains the product category "Lunch"
|
||||
When the product category lunch is visible at this time
|
||||
And I reload the page
|
||||
Then the user page contains the product category beer
|
||||
And the user page contains the product category lunch
|
||||
Then the user page contains the product category "Beer"
|
||||
And the user page contains the product category "Lunch"
|
||||
|
||||
@javascript
|
||||
Scenario: Product category visibility by minute when category is visible after now
|
||||
@@ -31,11 +31,11 @@ Feature:
|
||||
And there is a table
|
||||
And I am signed in as a user
|
||||
When the user is on the order products page
|
||||
Then the user page contains the product category lunch
|
||||
Then the user page contains the product category "Lunch"
|
||||
When the product category lunch is visible later than now
|
||||
And I reload the page
|
||||
Then the user page contains the product category beer
|
||||
And the user page does not contain the product category lunch
|
||||
Then the user page contains the product category "Beer"
|
||||
And the user page does not contain the product category "Lunch"
|
||||
|
||||
@javascript
|
||||
Scenario: Product category visibility by minute when category is visible before now
|
||||
@@ -43,8 +43,8 @@ Feature:
|
||||
And there is a table
|
||||
And I am signed in as a user
|
||||
When the user is on the order products page
|
||||
Then the user page contains the product category lunch
|
||||
Then the user page contains the product category "Lunch"
|
||||
When the product category lunch is visible earlyer than now
|
||||
And I reload the page
|
||||
Then the user page contains the product category beer
|
||||
And the user page does not contain the product category lunch
|
||||
Then the user page contains the product category "Beer"
|
||||
And the user page does not contain the product category "Lunch"
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
Feature: Submitting contact form
|
||||
Scenario: Website visitor submits contact form
|
||||
Given there are standard website pages
|
||||
When I visit '/contact'
|
||||
When I visit '/en/contact'
|
||||
And I fill in the website contact form
|
||||
And I submit the website contact form
|
||||
Then I should be redirected to the homepage
|
||||
|
||||
@@ -134,7 +134,7 @@ end
|
||||
|
||||
step "the supplier main board table number should be updated to the new table number" do
|
||||
expect( find(".list-row-#{@list.id} .table-number").text ).to eq "# 65"
|
||||
expect( find(".order-row-#{@list.orders.first.id} .table-number").text ).to eq "65"
|
||||
expect( find(".order-row-#{@list.orders.first.id} .table-number").text ).to eq "# 65"
|
||||
end
|
||||
|
||||
step "the supplier main board section name should be updated to the new section" do
|
||||
|
||||
@@ -14,8 +14,9 @@ step "the user 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'
|
||||
page.should have_content 'Apple pie'
|
||||
ember_route_should_be '/active-list'
|
||||
product_order = @list.orders.first.product_orders.first
|
||||
page.should have_content "#{product_order.quantity} x #{product_order.product_name}"
|
||||
all('.table-number').map(&:text).uniq.should == ["# #{@other_table.number.to_s}"]
|
||||
end
|
||||
|
||||
|
||||
@@ -7,7 +7,8 @@ step "the user clicks on the submit feedback button" do
|
||||
end
|
||||
|
||||
step "the user should see the feedback submitted message" do
|
||||
page.should have_content 'Thank you for your feedback'
|
||||
#page.should have_content 'Thank you for your feedback'
|
||||
page.should have_content 'Dank je voor het meedenken'
|
||||
end
|
||||
|
||||
step "a user feedback should be created containing the feedback" do
|
||||
|
||||
@@ -140,12 +140,12 @@ step "the user has an active list with a/an :order_status order" do |order_statu
|
||||
end
|
||||
end
|
||||
|
||||
step "the user page contains the product category lunch" do
|
||||
js_text("#product-category-#{@category_lunch.id} .product_category-title").should include @category_lunch.name
|
||||
step "the user page contains the product category :product_category_name" do |product_category_name|
|
||||
product_category = ProductCategory.find_by_name(product_category_name)
|
||||
js_text("#product-category-#{product_category.id} .product_category-title").should include product_category.name
|
||||
end
|
||||
step "the user page contains the product category beer" do
|
||||
js_text("#product-category-#{@category_beer.id} .product_category-title").should include @category_beer.name
|
||||
end
|
||||
step "the user page does not contain the product category lunch" do
|
||||
page.should_not have_selector "#product-category-#{@category_lunch.id} .product_category-title"
|
||||
|
||||
step "the user page does not contain the product category :product_category_name" do |product_category_name|
|
||||
product_category = ProductCategory.find_by_name(product_category_name)
|
||||
page.should_not have_selector "#product-category-#{product_category.id} .product_category-title"
|
||||
end
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
|
||||
step "the users clicks on the product category :product_category_name title" do |product_category_name|
|
||||
product_category = ProductCategory.find_by_name product_category_name
|
||||
js_click "#product-category-#{product_category.id} .product_category-title"
|
||||
end
|
||||
@@ -9,8 +9,8 @@ describe User do
|
||||
user.supplier_name.should == 'Benji setup'
|
||||
end
|
||||
|
||||
it 'falls back to unkown if not present' do
|
||||
user.supplier_name.should == I18n.t('supplier.user.unkown_name')
|
||||
it 'falls back to unknown if not present' do
|
||||
user.supplier_name.should == I18n.t('supplier.user.unknown_name')
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user