mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-27 01:43:22 +00:00
Use local time zone in tests instead of hardcoded
This commit is contained in:
@@ -147,9 +147,8 @@ feature %q{
|
||||
page.should have_content 'Your order cycle has been created.'
|
||||
|
||||
page.should have_selector 'a', text: 'Plums & Avos'
|
||||
|
||||
page.should have_selector "input[value='2040-11-06 06:00:00 +1100']"
|
||||
page.should have_selector "input[value='2040-11-13 17:00:00 +1100']"
|
||||
page.should have_selector "input[value='#{Time.zone.local(2040, 11, 06, 06, 00, 00)}']"
|
||||
page.should have_selector "input[value='#{Time.zone.local(2040, 11, 13, 17, 00, 00)}']"
|
||||
page.should have_content 'My coordinator'
|
||||
|
||||
page.should have_selector 'td.suppliers', text: 'My supplier'
|
||||
@@ -382,8 +381,8 @@ feature %q{
|
||||
|
||||
page.should have_selector 'a', text: 'Plums & Avos'
|
||||
|
||||
page.should have_selector "input[value='2040-11-06 06:00:00 +1100']"
|
||||
page.should have_selector "input[value='2040-11-13 17:00:00 +1100']"
|
||||
page.should have_selector "input[value='#{Time.zone.local(2040, 11, 06, 06, 00, 00)}']"
|
||||
page.should have_selector "input[value='#{Time.zone.local(2040, 11, 13, 17, 00, 00)}']"
|
||||
page.should have_content coordinator.name
|
||||
|
||||
page.should have_selector 'td.suppliers', text: 'My supplier'
|
||||
@@ -907,8 +906,8 @@ feature %q{
|
||||
# Then my order cycle should have been created
|
||||
page.should have_content 'Your order cycle has been created.'
|
||||
page.should have_selector 'a', text: 'Plums & Avos'
|
||||
page.should have_selector "input[value='2040-10-17 06:00:00 +1100']"
|
||||
page.should have_selector "input[value='2040-10-24 17:00:00 +1100']"
|
||||
page.should have_selector "input[value='#{Time.zone.local(2040, 10, 17, 06, 00, 00)}']"
|
||||
page.should have_selector "input[value='#{Time.zone.local(2040, 10, 24, 17, 00, 00)}']"
|
||||
|
||||
# And it should have some variants selected
|
||||
oc = OrderCycle.last
|
||||
@@ -995,8 +994,8 @@ feature %q{
|
||||
# Then my order cycle should have been updated
|
||||
page.should have_content 'Your order cycle has been updated.'
|
||||
page.should have_selector 'a', text: 'Plums & Avos'
|
||||
page.should have_selector "input[value='2040-10-17 06:00:00 +1100']"
|
||||
page.should have_selector "input[value='2040-10-24 17:00:00 +1100']"
|
||||
page.should have_selector "input[value='#{Time.zone.local(2040, 10, 17, 06, 00, 00)}']"
|
||||
page.should have_selector "input[value='#{Time.zone.local(2040, 10, 24, 17, 00, 00)}']"
|
||||
|
||||
# And it should have a variant selected
|
||||
oc = OrderCycle.last
|
||||
|
||||
Reference in New Issue
Block a user