added common method for opening navbar
This commit is contained in:
parent
b87102932c
commit
094a2e66e4
|
@ -22,14 +22,8 @@ class AddressBook(TeleniumTestProcess):
|
||||||
"""Saving a new Address On Address Book Screen/Window"""
|
"""Saving a new Address On Address Book Screen/Window"""
|
||||||
# Checking current Screen(Inbox screen)
|
# Checking current Screen(Inbox screen)
|
||||||
self.assert_wait_no_except('//ScreenManager[@current]', timeout=15, value='inbox')
|
self.assert_wait_no_except('//ScreenManager[@current]', timeout=15, value='inbox')
|
||||||
# This is for checking the Side nav Bar is closed
|
# Method to open side navbar (written in telenium_process.py)
|
||||||
self.assertExists('//MDNavigationDrawer[@status~=\"closed\"]', timeout=5)
|
self.open_side_navbar()
|
||||||
# This is for checking the menu button is appeared
|
|
||||||
self.assertExists('//MDActionTopAppBarButton[@icon~=\"menu\"]', timeout=5)
|
|
||||||
# This is for opening Nav drawer
|
|
||||||
self.cli.wait_click('//MDActionTopAppBarButton[@icon=\"menu\"]', timeout=5)
|
|
||||||
# checking state of Nav drawer
|
|
||||||
self.assertExists("//MDNavigationDrawer[@state~=\"open\"]", timeout=5)
|
|
||||||
# this is for scrolling Nav drawer
|
# this is for scrolling Nav drawer
|
||||||
self.drag("//NavigationItem[@text=\"Sent\"]", "//NavigationItem[@text=\"Inbox\"]")
|
self.drag("//NavigationItem[@text=\"Sent\"]", "//NavigationItem[@text=\"Inbox\"]")
|
||||||
# assert for checking scroll function
|
# assert for checking scroll function
|
||||||
|
@ -145,10 +139,8 @@ class AddressBook(TeleniumTestProcess):
|
||||||
@ordered
|
@ordered
|
||||||
def test_delete_address_from_saved_address(self):
|
def test_delete_address_from_saved_address(self):
|
||||||
"""Delete a saved Address from Address Book"""
|
"""Delete a saved Address from Address Book"""
|
||||||
# this is for opening Nav drawer
|
# Method to open side navbar (written in telenium_process.py)
|
||||||
self.cli.wait_click('//MDActionTopAppBarButton[@icon=\"menu\"]', timeout=2)
|
self.open_side_navbar()
|
||||||
# checking state of Nav drawer(Open)
|
|
||||||
self.assertExists("//MDNavigationDrawer[@state~=\"open\"]", timeout=2)
|
|
||||||
# this is for opening setting screen
|
# this is for opening setting screen
|
||||||
self.cli.wait_click('//NavigationItem[@text=\"Address Book\"]', timeout=2)
|
self.cli.wait_click('//NavigationItem[@text=\"Address Book\"]', timeout=2)
|
||||||
# checking state of Nav drawer(closed)
|
# checking state of Nav drawer(closed)
|
||||||
|
|
Reference in New Issue
Block a user