Notes![what is notes.io? What is notes.io?](/theme/images/whatisnotesio.png)
![]() ![]() Notes - notes.io |
from PageObjects.UsersAndCustomersPages.CustomermanagementPage import Routing
from PageObjects.UsersAndCustomersPages.CustomermanagementPage import *
from SeleniumBasePackage.SeleniumBaseClass import *
from Utils.Utils import Utils
class ObjectivePage_routing(SeleniumBaseClass):
def __init__(self, driver):
self.driver = driver
def edit_routing_settings_text_fields(self):
_utilInstance = Utils()
self.click(SettingsPage._location_settings)
self.click(Routing._routing)
random_text_list = []
for random_text in xrange(4):
randomtext = _utilInstance._get_random_alphanumeric_string()
random_text_list.append(randomtext)
locator_list = [Routing._start_address, Routing._start_city, Routing._start_state, Routing._start_zip]
for text_field in xrange(4):
self.clear_and_type(locator_list[text_field], random_text_list[text_field])
self.click(Routing._enable_routing)
self.explicitly_wait_for_time(8)
for value in xrange(4):
text_field_saved = self.get_locator_value(locator_list[value])
assert text_field_saved == random_text_list[value]
def edit_routing_settings_dropdowns(self):
earlier_departure_hours_list = ['1', '7', '8', '12']
earlier_departure_minutes_list = ['01', '15', '25', '55']
earlier_departure_am_pm_list = ['am', 'pm']
maximum_early_arrival_allowed_and_location_hour = ['1', '5', '8', '11']
maximum_early_arrival_allowed_and_location_mins = ['02', '30', '40', '55']
self.click(SettingsPage._location_settings)
self.click(Routing._routing)
_departure_hour = self.select_new_value_in_drop_down(Routing._edit_routing_settings_dropdowns_1, earlier_departure_hours_list)
_departure_mins = self.select_new_value_in_drop_down(Routing._edit_routing_settings_dropdowns_2, earlier_departure_minutes_list)
_departure_am_pm = self.select_new_value_in_drop_down(Routing._deliver_earliest_departure_am_pm, earlier_departure_am_pm_list)
_max_early_arrival_allowed_hour = self.select_new_value_in_drop_down(Routing._maximum_early_arrival_allowed_hour, maximum_early_arrival_allowed_and_location_hour)
_max_early_arrival_allowed_mins = self.select_new_value_in_drop_down(Routing._maximum_early_arrival_allowed_mins, maximum_early_arrival_allowed_and_location_mins)
_time_at_delivery_loc_hour = self.select_new_value_in_drop_down(Routing._time_at_delivery_loc_hour, maximum_early_arrival_allowed_and_location_hour)
_time_at_delivery_loc_mins = self.select_new_value_in_drop_down(Routing._time_at_delivery_loc_mins, maximum_early_arrival_allowed_and_location_mins)
self.click(Routing._enable_routing)
self.explicitly_wait_for_time(8)
assert self.get_first_selected_option(Routing._edit_routing_settings_dropdowns_1) == _departure_hour
assert self.get_first_selected_option(Routing._edit_routing_settings_dropdowns_2) == _departure_mins
assert self.get_first_selected_option(Routing._deliver_earliest_departure_am_pm) == _departure_am_pm
assert self.get_first_selected_option(Routing._maximum_early_arrival_allowed_hour) == _max_early_arrival_allowed_hour
assert self.get_first_selected_option(Routing._maximum_early_arrival_allowed_mins) == _max_early_arrival_allowed_mins
assert self.get_first_selected_option(Routing._time_at_delivery_loc_hour) == _time_at_delivery_loc_hour
assert self.get_first_selected_option(Routing._time_at_delivery_loc_mins) == _time_at_delivery_loc_mins
def click_on_disabled_in_app_button(self):
self.click(SettingsPage._location_settings)
self.click(Routing._routing)
self.click(Routing._disable_in_app)
self.wait_till_alert_present_assert_mesage_and_dismiss('Are you sure you want to disable routing for this account?')
self.click(Routing._disable_in_app)
self.wait_till_alert_present_and_assert('Are you sure you want to disable routing for this account?')
_routing_disabled_in_app_confirmation_msg = self.get_text(Routing._disable_in_app_confirmation_mesage)
_routing_disabled_in_app_confirmation_msg = _routing_disabled_in_app_confirmation_msg.split('n')[-1]
assert _routing_disabled_in_app_confirmation_msg == 'In App Routing has been disabled. Please reload settings in Lavu POS.'
self.click(Routing._continue_button)
self.click(Routing._enable_in_app_button)
self.explicitly_wait_for_time(3)
assert self.get_text(Routing._edit_routing_page) == 'Edit Routing Settings'
![]() |
Notes is a web-based application for online taking notes. You can take your notes and share with others people. If you like taking long notes, notes.io is designed for you. To date, over 8,000,000,000+ notes created and continuing...
With notes.io;
- * You can take a note from anywhere and any device with internet connection.
- * You can share the notes in social platforms (YouTube, Facebook, Twitter, instagram etc.).
- * You can quickly share your contents without website, blog and e-mail.
- * You don't need to create any Account to share a note. As you wish you can use quick, easy and best shortened notes with sms, websites, e-mail, or messaging services (WhatsApp, iMessage, Telegram, Signal).
- * Notes.io has fabulous infrastructure design for a short link and allows you to share the note as an easy and understandable link.
Fast: Notes.io is built for speed and performance. You can take a notes quickly and browse your archive.
Easy: Notes.io doesn’t require installation. Just write and share note!
Short: Notes.io’s url just 8 character. You’ll get shorten link of your note when you want to share. (Ex: notes.io/q )
Free: Notes.io works for 14 years and has been free since the day it was started.
You immediately create your first note and start sharing with the ones you wish. If you want to contact us, you can use the following communication channels;
Email: [email protected]
Twitter: http://twitter.com/notesio
Instagram: http://instagram.com/notes.io
Facebook: http://facebook.com/notesio
Regards;
Notes.io Team