worked on removing time.sleep methods from all the test cases

This commit is contained in:
navjot 2021-03-12 00:18:09 +05:30
parent 50a258f412
commit d62d464b61
No known key found for this signature in database
GPG Key ID: 9EE70AFD71357F1C
11 changed files with 169 additions and 186 deletions

View File

@ -3,6 +3,7 @@ import shutil
import tempfile import tempfile
from telenium.tests import TeleniumTestCase from telenium.tests import TeleniumTestCase
from threads import addressGenerator, sqlThread
_files = ( _files = (

View File

@ -13,92 +13,92 @@ class AddressBook(TeleniumTestProcess):
def test_save_address(self): def test_save_address(self):
"""Save Address On Address Book Screen/Window""" """Save Address On Address Book Screen/Window"""
print("=====================Test -Save Address In Address Book=====================") print("=====================Test -Save Address In Address Book=====================")
time.sleep(6) self.cli.sleep(6)
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(4) self.cli.sleep(4)
self.cli.drag("//NavigationItem[@text=\"Sent\"]","//NavigationItem[@text=\"Inbox\"]",1) self.cli.drag("//NavigationItem[@text=\"Sent\"]","//NavigationItem[@text=\"Inbox\"]",1)
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//NavigationItem[6]') self.cli.click_on('//NavigationItem[6]')
time.sleep(4) self.cli.sleep(4)
self.cli.execute('app.addingtoaddressbook()') self.cli.execute('app.addingtoaddressbook()')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//GrashofPopup/BoxLayout[0]/MDTextField[0]') self.cli.click_on('//GrashofPopup/BoxLayout[0]/MDTextField[0]')
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//GrashofPopup/BoxLayout[0]/MDTextField[1]') self.cli.click_on('//GrashofPopup/BoxLayout[0]/MDTextField[1]')
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//MDRaisedButton[0]') self.cli.click_on('//MDRaisedButton[0]')
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//GrashofPopup/BoxLayout[0]/MDTextField[0]') self.cli.click_on('//GrashofPopup/BoxLayout[0]/MDTextField[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[0]','text','peter') self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[0]','text','peter')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDRaisedButton[0]') self.cli.click_on('//MDRaisedButton[0]')
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//GrashofPopup/BoxLayout[0]/MDTextField[1]') self.cli.click_on('//GrashofPopup/BoxLayout[0]/MDTextField[1]')
time.sleep(3) self.cli.sleep(3)
self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[1]','text','sectorAppartment') self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[1]','text','sectorAppartment')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDRaisedButton[0]') self.cli.click_on('//MDRaisedButton[0]')
time.sleep(5) self.cli.sleep(5)
self.cli.click_on('//GrashofPopup/BoxLayout[0]/MDTextField[1]') self.cli.click_on('//GrashofPopup/BoxLayout[0]/MDTextField[1]')
time.sleep(3) self.cli.sleep(3)
self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[1]','text',data[0]) self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[1]','text',data[0])
time.sleep(3) self.cli.sleep(3)
self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[1]','text','') self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[1]','text','')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDRaisedButton[0]') self.cli.click_on('//MDRaisedButton[0]')
time.sleep(4) self.cli.sleep(4)
self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[1]','text','BM-2cX78L9CZpb6GGC3rRVizYiUBwHELMLybd') self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[1]','text','BM-2cX78L9CZpb6GGC3rRVizYiUBwHELMLybd')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDRaisedButton[0]') self.cli.click_on('//MDRaisedButton[0]')
time.sleep(4) self.cli.sleep(4)
@ordered @ordered
def test_cancel_address(self): def test_cancel_address(self):
"""Cancel Address""" """Cancel Address"""
print("=====================Test -Cancel Address=====================") print("=====================Test -Cancel Address=====================")
time.sleep(3) self.cli.sleep(3)
self.cli.execute('app.addingtoaddressbook()') self.cli.execute('app.addingtoaddressbook()')
time.sleep(3) self.cli.sleep(3)
self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[0]','text','prachi') self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[0]','text','prachi')
time.sleep(3) self.cli.sleep(3)
self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[1]','text',data[0]) self.cli.setattr('//GrashofPopup/BoxLayout[0]/MDTextField[1]','text',data[0])
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDRaisedButton[1]') self.cli.click_on('//MDRaisedButton[1]')
@ordered @ordered
def test_send_message_to_addressbook(self): def test_send_message_to_addressbook(self):
"""Directly Send Message To The User""" """Directly Send Message To The User"""
print("=====================Test -Directly Send Message To The User=====================") print("=====================Test -Directly Send Message To The User=====================")
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//AddressBook/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]') self.cli.click_on('//AddressBook/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDRaisedButton[0]') self.cli.click_on('//MDRaisedButton[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[0]/BoxLayout[0]/CustomSpinner[0]/ArrowImg[0]') self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[0]/BoxLayout[0]/CustomSpinner[0]/ArrowImg[0]')
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/BoxLayout[0]/MyTextInput[0]') self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/BoxLayout[0]/MyTextInput[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]', 'text', 'Second') self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]', 'text', 'Second')
time.sleep(3) self.cli.sleep(3)
random_label="" random_label=""
for char in "Hey This is Message From Address Book": for char in "Hey This is Message From Address Book":
random_label += char random_label += char
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]', 'text', random_label) self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]', 'text', random_label)
time.sleep(0.2) self.cli.sleep(0.2)
self.cli.click_on('//MDIconButton[2]') self.cli.click_on('//MDIconButton[2]')
time.sleep(2) self.cli.sleep(2)
@ordered @ordered
def test_delete_address_from_address_contact(self): def test_delete_address_from_address_contact(self):
"""Delete Address From Address Book""" """Delete Address From Address Book"""
print("=====================Test -Delete Address From Address Book=====================") print("=====================Test -Delete Address From Address Book=====================")
time.sleep(3) self.cli.sleep(3)
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//NavigationItem[6]') self.cli.click_on('//NavigationItem[6]')
time.sleep(3) self.cli.sleep(3)
self.cli.drag('//AddressBook/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]//TwoLineAvatarIconListItem[0]/BoxLayout[0]', self.cli.drag('//AddressBook/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]//TwoLineAvatarIconListItem[0]/BoxLayout[0]',
'//AddressBook/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]//TwoLineAvatarIconListItem[0]/BoxLayout[2]', 2) '//AddressBook/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]//TwoLineAvatarIconListItem[0]/BoxLayout[2]', 2)
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//AddressBook/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]//Button[0]') self.cli.click_on('//AddressBook/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]//Button[0]')

View File

@ -1,4 +1,3 @@
import time
from bitmessagekivy.tests.telenium_process import TeleniumTestProcess from bitmessagekivy.tests.telenium_process import TeleniumTestProcess
from .common import ordered from .common import ordered
@ -7,21 +6,21 @@ class AllMailMessage(TeleniumTestProcess):
"""AllMail Screen Functionality Testing""" """AllMail Screen Functionality Testing"""
@ordered @ordered
def test_select_all_mails(self): def test_show_allmail_list(self):
"""Show All Messages on Mail Screen/Window""" """Show All Messages on Mail Screen/Window"""
print("=====================Test -Show Messages Of Mail Screen=====================") print("=====================Test -Show Messages Of Mail Screen=====================")
time.sleep(5) self.cli.sleep(5)
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//NavigationItem[5]') self.cli.click_on('//NavigationItem[5]')
time.sleep(4) self.cli.sleep(4)
@ordered @ordered
def test_delete_message_from_draft(self): def test_delete_message_from_allmail_list(self):
"""Delete Message From Message body of Mail Screen/Window""" """Delete Message From Message body of Mail Screen/Window"""
print("=====================Test -Delete Messages Of Mail Screen=====================") print("=====================Test -Delete Messages Of Mail Screen=====================")
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//Allmails[0]/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]') self.cli.click_on('//Allmails[0]/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]')
time.sleep(5) self.cli.sleep(5)
self.cli.click_on('//MDToolbar/BoxLayout[2]/MDIconButton[1]') self.cli.click_on('//MDToolbar/BoxLayout[2]/MDIconButton[1]')
time.sleep(3) self.cli.sleep(3)

View File

@ -1,6 +1,5 @@
import os import os
import tempfile import tempfile
import time
from bitmessagekivy.tests.telenium_process import TeleniumTestProcess, cleanup from bitmessagekivy.tests.telenium_process import TeleniumTestProcess, cleanup
from .common import ordered from .common import ordered
@ -12,7 +11,6 @@ class CreateRandomAddress(TeleniumTestProcess):
@classmethod @classmethod
def setUpClass(cls): def setUpClass(cls):
print('ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ', __file__)
os.environ["BITMESSAGE_HOME"] = tempfile.gettempdir() os.environ["BITMESSAGE_HOME"] = tempfile.gettempdir()
cleanup() cleanup()
super(TeleniumTestProcess, cls).setUpClass() super(TeleniumTestProcess, cls).setUpClass()
@ -21,40 +19,40 @@ class CreateRandomAddress(TeleniumTestProcess):
def test_login_screen(self): def test_login_screen(self):
"""Clicking on Proceed Button to Proceed to Next Screen.""" """Clicking on Proceed Button to Proceed to Next Screen."""
print("=====================Test - Login Screen=====================") print("=====================Test - Login Screen=====================")
time.sleep(3) self.cli.sleep(3)
self.cli.wait_click('//Login/BoxLayout[0]/BoxLayout[0]/ScreenManager[0]/Screen[0]/BoxLayout[0]/AnchorLayout[3]/MDFillRoundFlatIconButton[0]') self.cli.wait_click('//Login/BoxLayout[0]/BoxLayout[0]/ScreenManager[0]/Screen[0]/BoxLayout[0]/AnchorLayout[3]/MDFillRoundFlatIconButton[0]')
time.sleep(3) self.cli.sleep(3)
@ordered @ordered
def test_random_screen(self): def test_random_screen(self):
"""Creating New Adress For New User.""" """Creating New Adress For New User."""
print("=====================Test - Create New Address=====================") print("=====================Test - Create New Address=====================")
self.cli.click_on('//RandomBoxlayout/BoxLayout[0]/AnchorLayout[1]/MDTextField[0]') self.cli.click_on('//RandomBoxlayout/BoxLayout[0]/AnchorLayout[1]/MDTextField[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.wait_click('//RandomBoxlayout/BoxLayout[0]/AnchorLayout[2]/MDFillRoundFlatIconButton[0]') self.cli.wait_click('//RandomBoxlayout/BoxLayout[0]/AnchorLayout[2]/MDFillRoundFlatIconButton[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//RandomBoxlayout/BoxLayout[0]/AnchorLayout[1]/MDTextField[0]') self.cli.click_on('//RandomBoxlayout/BoxLayout[0]/AnchorLayout[1]/MDTextField[0]')
time.sleep(3) self.cli.sleep(3)
random_label = "" random_label = ""
for _ in range(10): for _ in range(10):
random_label += choice(ascii_lowercase) random_label += choice(ascii_lowercase)
self.cli.setattr('//RandomBoxlayout/BoxLayout[0]/AnchorLayout[1]/MDTextField[0]', "text", random_label) self.cli.setattr('//RandomBoxlayout/BoxLayout[0]/AnchorLayout[1]/MDTextField[0]', "text", random_label)
time.sleep(0.2) self.cli.sleep(0.2)
time.sleep(1) self.cli.sleep(1)
self.cli.wait_click('//RandomBoxlayout/BoxLayout[0]/AnchorLayout[2]/MDFillRoundFlatIconButton[0]') self.cli.wait_click('//RandomBoxlayout/BoxLayout[0]/AnchorLayout[2]/MDFillRoundFlatIconButton[0]')
time.sleep(5) self.cli.sleep(5)
@ordered @ordered
def test_create_new_address(self): def test_create_new_address(self):
"""Clicking on Navigation Drawer To Open New Address""" """Clicking on Navigation Drawer To Open New Address"""
print("=====================Test - Create New Address=====================") print("=====================Test - Create New Address=====================")
time.sleep(5) self.cli.sleep(5)
self.cli.execute('app.root.ids.nav_drawer.set_state("toggle")') self.cli.execute('app.root.ids.nav_drawer.set_state("toggle")')
time.sleep(2) self.cli.sleep(2)
self.cli.drag("//NavigationItem[@text=\"Sent\"]","//NavigationItem[@text=\"Inbox\"]",1) self.cli.drag("//NavigationItem[@text=\"Sent\"]","//NavigationItem[@text=\"Inbox\"]",1)
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//NavigationItem[9]') self.cli.click_on('//NavigationItem[9]')
time.sleep(4) self.cli.sleep(4)
self.cli.wait_click('//Login/BoxLayout[0]/BoxLayout[0]/ScreenManager[0]/Screen[0]/BoxLayout[0]/AnchorLayout[3]/MDFillRoundFlatIconButton[0]') self.cli.wait_click('//Login/BoxLayout[0]/BoxLayout[0]/ScreenManager[0]/Screen[0]/BoxLayout[0]/AnchorLayout[3]/MDFillRoundFlatIconButton[0]')
self.test_random_screen() self.test_random_screen()
@ -62,12 +60,12 @@ class CreateRandomAddress(TeleniumTestProcess):
def test_select_address(self): def test_select_address(self):
"""Select First Address From Drawer-Box""" """Select First Address From Drawer-Box"""
print("=====================Test - Select First Address From Drawer-Box=======================") print("=====================Test - Select First Address From Drawer-Box=======================")
time.sleep(3) self.cli.sleep(3)
# self.cli.execute('app.root.ids.nav_drawer.set_state("toggle")') # self.cli.execute('app.root.ids.nav_drawer.set_state("toggle")')
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(2) self.cli.sleep(2)
self.cli.drag("//NavigationItem[@text=\"Address Book\"]","//NavigationItem[@text=\"Settings\"]",1) self.cli.drag("//NavigationItem[@text=\"Address Book\"]","//NavigationItem[@text=\"Settings\"]",1)
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//NavigationItem[0]') self.cli.click_on('//NavigationItem[0]')
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//MySpinnerOption[0]') self.cli.click_on('//MySpinnerOption[0]')

View File

@ -1,4 +1,3 @@
import time
from bitmessagekivy.tests.telenium_process import TeleniumTestProcess from bitmessagekivy.tests.telenium_process import TeleniumTestProcess
from .common import ordered from .common import ordered
@ -7,87 +6,87 @@ class DraftMessage(TeleniumTestProcess):
"""Draft Screen Functionality Testing""" """Draft Screen Functionality Testing"""
@ordered @ordered
def test_select_draft_message(self): def test_save_draft_message(self):
"""Select A Draft Screen From Navigaion-Drawer-Box Then """Select A Draft Screen From Navigaion-Drawer-Box Then
Send a drafted message """ Send a drafted message """
print("=====================Test - Select A Draft Screen From Navigaion-Drawer-Box=====================") print("=====================Test - Select A Draft Screen From Navigaion-Drawer-Box=====================")
# OPEN NAVIGATION-DRAWER # OPEN NAVIGATION-DRAWER
time.sleep(4) self.cli.sleep(4)
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(2) self.cli.sleep(2)
# OPEN INBOX SCREEN # OPEN INBOX SCREEN
self.cli.click_on('//NavigationItem[1]') self.cli.click_on('//NavigationItem[1]')
time.sleep(2) self.cli.sleep(2)
# CLICK ON PLUS ICON BUTTON # CLICK ON PLUS ICON BUTTON
self.cli.click_on('//Inbox/ComposerButton[0]/MDFloatingActionButton[0]') self.cli.click_on('//Inbox/ComposerButton[0]/MDFloatingActionButton[0]')
time.sleep(3) self.cli.sleep(3)
# SELECT - TO ADDRESS # SELECT - TO ADDRESS
self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[0]/BoxLayout[0]/CustomSpinner[0]/ArrowImg[0]') self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[0]/BoxLayout[0]/CustomSpinner[0]/ArrowImg[0]')
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//MyTextInput[0]') self.cli.click_on('//MyTextInput[0]')
time.sleep(3) self.cli.sleep(3)
# ADD FROM MESSAGE # ADD FROM MESSAGE
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/BoxLayout[0]/MyTextInput[0]', "text",'BM-2cSsuH1bUWBski8bvdqnK2DivMqQCeQA1J') self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/BoxLayout[0]/MyTextInput[0]', "text",'BM-2cSsuH1bUWBski8bvdqnK2DivMqQCeQA1J')
time.sleep(3) self.cli.sleep(3)
# CLICK BACK-BUTTON # CLICK BACK-BUTTON
self.cli.click_on('//MDToolbar/BoxLayout[0]/MDIconButton[0]') self.cli.click_on('//MDToolbar/BoxLayout[0]/MDIconButton[0]')
time.sleep(5) self.cli.sleep(5)
self.cli.click_on('//Inbox/ComposerButton[0]/MDFloatingActionButton[0]') self.cli.click_on('//Inbox/ComposerButton[0]/MDFloatingActionButton[0]')
time.sleep(3) self.cli.sleep(3)
# SELECT - TO ADDRESS # SELECT - TO ADDRESS
self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[0]/BoxLayout[0]/CustomSpinner[0]/ArrowImg[0]') self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[0]/BoxLayout[0]/CustomSpinner[0]/ArrowImg[0]')
time.sleep(1) self.cli.sleep(1)
self.cli.click_on('//MyTextInput[0]') self.cli.click_on('//MyTextInput[0]')
time.sleep(3) self.cli.sleep(3)
# ADD FROM MESSAGE # ADD FROM MESSAGE
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/BoxLayout[0]/MyTextInput[0]', "text",'BM-2cSsuH1bUWBski8bvdqnK2DivMqQCeQA1J') self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/BoxLayout[0]/MyTextInput[0]', "text",'BM-2cSsuH1bUWBski8bvdqnK2DivMqQCeQA1J')
time.sleep(4) self.cli.sleep(4)
random_label="" random_label=""
for char in "Another Draft message": for char in "Another Draft message":
random_label += char random_label += char
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]', 'text', random_label) self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]', 'text', random_label)
time.sleep(0.2) self.cli.sleep(0.2)
# CLICK BACK-BUTTON # CLICK BACK-BUTTON
self.cli.click_on('//MDToolbar/BoxLayout[0]/MDIconButton[0]') self.cli.click_on('//MDToolbar/BoxLayout[0]/MDIconButton[0]')
time.sleep(4) self.cli.sleep(4)
@ordered @ordered
def test_edit_draft_messgae(self): def test_edit_and_resend_draft_messgae(self):
"""Select A Message From List of Messages Then """Select A Message From List of Messages Then
make changes and send it.""" make changes and send it."""
print("=====================Test - Edit A Message From Draft Screen=====================") print("=====================Test - Edit A Message From Draft Screen=====================")
# OPEN NAVIGATION-DRAWER # OPEN NAVIGATION-DRAWER
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(4) self.cli.sleep(4)
# OPEN DRAFT SCREEN # OPEN DRAFT SCREEN
self.cli.click_on('//NavigationItem[3]') self.cli.click_on('//NavigationItem[3]')
time.sleep(4) self.cli.sleep(4)
# SHOW DRAFT MESSAGE AND SELECT FIRST MESSAGE # SHOW DRAFT MESSAGE AND SELECT FIRST MESSAGE
self.cli.click_on('//Carousel[0]//TwoLineAvatarIconListItem[0]') self.cli.click_on('//Carousel[0]//TwoLineAvatarIconListItem[0]')
time.sleep(3) self.cli.sleep(3)
# CLICK EDIT BUTTON # CLICK EDIT BUTTON
self.cli.click_on('//MDToolbar/BoxLayout[2]/MDIconButton[0]') self.cli.click_on('//MDToolbar/BoxLayout[2]/MDIconButton[0]')
time.sleep(5) self.cli.sleep(5)
random_label="" random_label=""
for char in "Hey,This is draft Message Body": for char in "Hey,This is draft Message Body":
random_label += char random_label += char
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]', 'text', random_label) self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]', 'text', random_label)
time.sleep(0.2) self.cli.sleep(0.2)
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDIconButton[2]') self.cli.click_on('//MDIconButton[2]')
time.sleep(5) self.cli.sleep(5)
@ordered @ordered
def test_delete_draft_message(self): def test_delete_draft_message(self):
"""Delete A Message From List of Messages""" """Delete A Message From List of Messages"""
print("=====================Test - Delete A Message From List of Messages=====================") print("=====================Test - Delete A Message From List of Messages=====================")
time.sleep(5) self.cli.sleep(5)
# self.cli.execute('app.root.ids.nav_drawer.set_state("toggle")') # self.cli.execute('app.root.ids.nav_drawer.set_state("toggle")')
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//NavigationItem[3]') self.cli.click_on('//NavigationItem[3]')
time.sleep(5) self.cli.sleep(5)
self.cli.click_on('//Carousel[0]//TwoLineAvatarIconListItem[0]') self.cli.click_on('//Carousel[0]//TwoLineAvatarIconListItem[0]')
time.sleep(5) self.cli.sleep(5)
self.cli.click_on('//MDToolbar/BoxLayout[2]/MDIconButton[1]') self.cli.click_on('//MDToolbar/BoxLayout[2]/MDIconButton[1]')
time.sleep(2) self.cli.sleep(2)

View File

@ -1,4 +1,3 @@
import time
from bmconfigparser import BMConfigParser from bmconfigparser import BMConfigParser
from bitmessagekivy.tests.telenium_process import TeleniumTestProcess from bitmessagekivy.tests.telenium_process import TeleniumTestProcess
from .common import ordered from .common import ordered
@ -13,44 +12,44 @@ class MyAddressScreen(TeleniumTestProcess):
def test_select_myaddress_list(self): def test_select_myaddress_list(self):
"""Select Address From List of Address""" """Select Address From List of Address"""
print("=====================Test -Select Address From List of Address=====================") print("=====================Test -Select Address From List of Address=====================")
time.sleep(4) self.cli.sleep(4)
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(3) self.cli.sleep(3)
self.cli.drag("//NavigationItem[@text=\"Sent\"]","//NavigationItem[@text=\"Inbox\"]",1) self.cli.drag("//NavigationItem[@text=\"Sent\"]","//NavigationItem[@text=\"Inbox\"]",1)
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//NavigationItem[11]') self.cli.click_on('//NavigationItem[11]')
time.sleep(4) self.cli.sleep(4)
@ordered @ordered
def test_show_Qrcode(self): def test_show_Qrcode(self):
"""Show the Qr code of selected address""" """Show the Qr code of selected address"""
print("=====================Test -Show QR code of selected address=====================") print("=====================Test -Show QR code of selected address=====================")
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//MyAddress/BoxLayout[0]/FloatLayout[0]/MDScrollViewRefreshLayout[0]/MDList[0]/CustomTwoLineAvatarIconListItem[0]') self.cli.click_on('//MyAddress/BoxLayout[0]/FloatLayout[0]/MDScrollViewRefreshLayout[0]/MDList[0]/CustomTwoLineAvatarIconListItem[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MyaddDetailPopup/BoxLayout[1]/MDRaisedButton[1]/MDLabel[0]') self.cli.click_on('//MyaddDetailPopup/BoxLayout[1]/MDRaisedButton[1]/MDLabel[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDToolbar/BoxLayout[0]/MDIconButton[0]') self.cli.click_on('//MDToolbar/BoxLayout[0]/MDIconButton[0]')
time.sleep(3) self.cli.sleep(3)
@ordered @ordered
def test_send_message_from(self): def test_send_message_from(self):
"""Send Message From Send Message From Button""" """Send Message From Send Message From Button"""
print("=====================Test -Send Message From Send Message From Button=====================") print("=====================Test -Send Message From Send Message From Button=====================")
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//MyAddress/BoxLayout[0]/FloatLayout[0]/MDScrollViewRefreshLayout[0]/MDList[0]/CustomTwoLineAvatarIconListItem[0]') self.cli.click_on('//MyAddress/BoxLayout[0]/FloatLayout[0]/MDScrollViewRefreshLayout[0]/MDList[0]/CustomTwoLineAvatarIconListItem[0]')
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//MyaddDetailPopup/BoxLayout[1]/MDRaisedButton[0]/MDLabel[0]') self.cli.click_on('//MyaddDetailPopup/BoxLayout[1]/MDRaisedButton[0]/MDLabel[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/BoxLayout[0]/MyTextInput', "text", data[1]) self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/BoxLayout[0]/MyTextInput', "text", data[1])
time.sleep(3) self.cli.sleep(3)
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]', 'text', 'Hey') self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]', 'text', 'Hey')
time.sleep(3) self.cli.sleep(3)
random_label="" random_label=""
for char in "Hey,i am sending message directly from MyAddress book": for char in "Hey,i am sending message directly from MyAddress book":
random_label += char random_label += char
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]', 'text', random_label) self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]', 'text', random_label)
time.sleep(0.2) self.cli.sleep(0.2)
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//MDIconButton[2]') self.cli.click_on('//MDIconButton[2]')
time.sleep(2) self.cli.sleep(2)

View File

@ -1,4 +1,3 @@
import time
from bitmessagekivy.tests.telenium_process import TeleniumTestProcess from bitmessagekivy.tests.telenium_process import TeleniumTestProcess
@ -8,12 +7,12 @@ class NetwrokStatusScreen(TeleniumTestProcess):
def test_network_status(self): def test_network_status(self):
"""Show NetwrokStatus""" """Show NetwrokStatus"""
print("=====================Test -Show NetwrokStatus=====================") print("=====================Test -Show NetwrokStatus=====================")
time.sleep(4) self.cli.sleep(4)
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(3) self.cli.sleep(3)
self.cli.drag("//NavigationItem[@text=\"Sent\"]","//NavigationItem[@text=\"Inbox\"]",1) self.cli.drag("//NavigationItem[@text=\"Sent\"]","//NavigationItem[@text=\"Inbox\"]",1)
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//NavigationItem[10]') self.cli.click_on('//NavigationItem[10]')
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//NetworkStat/MDTabs[0]/MDTabsBar[0]/MDTabsScrollView[0]/MDGridLayout[0]/MDTabsLabel[1]') self.cli.click_on('//NetworkStat/MDTabs[0]/MDTabsBar[0]/MDTabsScrollView[0]/MDGridLayout[0]/MDTabsLabel[1]')
time.sleep(4) self.cli.sleep(4)

View File

@ -1,4 +1,3 @@
import time
from bitmessagekivy.tests.telenium_process import TeleniumTestProcess from bitmessagekivy.tests.telenium_process import TeleniumTestProcess
@ -8,19 +7,19 @@ class PaymentScreen(TeleniumTestProcess):
def test_select_subscripton(self): def test_select_subscripton(self):
"""Select Subscripton From List of Subscriptons""" """Select Subscripton From List of Subscriptons"""
print("=====================Test -Select Subscripton From List of Subscriptons=====================") print("=====================Test -Select Subscripton From List of Subscriptons=====================")
time.sleep(4) self.cli.sleep(4)
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(3) self.cli.sleep(3)
self.cli.drag("//NavigationItem[@text=\"Sent\"]","//NavigationItem[@text=\"Inbox\"]",1) self.cli.drag("//NavigationItem[@text=\"Sent\"]","//NavigationItem[@text=\"Inbox\"]",1)
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//NavigationItem[8]') self.cli.click_on('//NavigationItem[8]')
time.sleep(3) self.cli.sleep(3)
self.cli.drag('//Payment/BoxLayout[0]/ScrollView[0]/BoxLayout[0]/ProductCategoryLayout[0]/ProductLayout[1]', self.cli.drag('//Payment/BoxLayout[0]/ScrollView[0]/BoxLayout[0]/ProductCategoryLayout[0]/ProductLayout[1]',
'//Payment/BoxLayout[0]/ScrollView[0]/BoxLayout[0]/ProductCategoryLayout[0]/ProductLayout[0]', 1) '//Payment/BoxLayout[0]/ScrollView[0]/BoxLayout[0]/ProductCategoryLayout[0]/ProductLayout[0]', 1)
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//MDRaisedButton[3]') self.cli.click_on('//MDRaisedButton[3]')
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//ListItemWithLabel[0]') self.cli.click_on('//ListItemWithLabel[0]')
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//MDRaisedButton[3]') self.cli.click_on('//MDRaisedButton[3]')
time.sleep(2) self.cli.sleep(2)

View File

@ -1,106 +1,101 @@
import os
import queues
import shutil
import tempfile
import time
from bitmessagekivy.tests.telenium_process import TeleniumTestProcess from bitmessagekivy.tests.telenium_process import TeleniumTestProcess
from bmconfigparser import BMConfigParser from bmconfigparser import BMConfigParser
from .common import ordered from .common import ordered
data = BMConfigParser().addresses() data = BMConfigParser().addresses()
class SendMessage(TeleniumTestProcess): class SendMessage(TeleniumTestProcess):
"""Sent Screen Functionality Testing""" """Sent Screen Functionality Testing"""
@ordered @ordered
def test_send_message_to_same_address(self): def test_send_message_and_validation(self):
""" """
Sending Message From Inbox Screen Sending Message From Inbox Screen
opens a pop-up(screen)which send message from sender to reciever opens a pop-up(screen)which send message from sender to reciever
""" """
print("=====================Test - Sending Message From Inbox Screen=====================") print("=====================Test - Sending Message From Inbox Screen=====================")
time.sleep(2) self.cli.sleep(2)
# self.cli.execute('app.root.ids.nav_drawer.set_state("toggle")') # self.cli.execute('app.root.ids.nav_drawer.set_state("toggle")')
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(1) self.cli.sleep(2)
self.cli.click_on('//NavigationItem[1]') self.cli.click_on('//NavigationItem[1]')
time.sleep(1) self.cli.sleep(2)
self.cli.click_on('//Inbox/ComposerButton[0]/MDFloatingActionButton[0]') self.cli.click_on('//Inbox/ComposerButton[0]/MDFloatingActionButton[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[0]/MyMDTextField[0]') self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[0]/MyMDTextField[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/MyTextInput[0]') self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/MyTextInput[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/MyTextInput[0]', "text", "second add") self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/MyTextInput[0]', "text", "second add")
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]') self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]')
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]') self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]')
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//MDIconButton[2]') self.cli.click_on('//MDIconButton[2]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDFlatButton[0]') self.cli.click_on('//MDFlatButton[0]')
time.sleep(5) self.cli.sleep(5)
self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[0]/BoxLayout[0]/CustomSpinner[0]/ArrowImg[0]') self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[0]/BoxLayout[0]/CustomSpinner[0]/ArrowImg[0]')
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//MyTextInput[0]') self.cli.click_on('//MyTextInput[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]') self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]')
time.sleep(2) self.cli.sleep(2)
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]', 'text', 'heyyyyyy') self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]', 'text', 'heyyyyyy')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]') self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]')
time.sleep(4) self.cli.sleep(4)
random_label="" random_label=""
for char in "how are you this is message body": for char in "how are you this is message body":
random_label += char random_label += char
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]','text',random_label) self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]','text',random_label)
time.sleep(0.2) self.cli.sleep(0.2)
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDIconButton[2]') self.cli.click_on('//MDIconButton[2]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDFlatButton[0]') self.cli.click_on('//MDFlatButton[0]')
time.sleep(6) self.cli.sleep(6)
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/BoxLayout[0]/MyTextInput[0]',"text", data[0]) self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/BoxLayout[0]/MyTextInput[0]',"text", data[0])
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDIconButton[2]') self.cli.click_on('//MDIconButton[2]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//MDFlatButton[0]') self.cli.click_on('//MDFlatButton[0]')
time.sleep(3) self.cli.sleep(3)
@ordered @ordered
def test_sent_multiple_message(self): def test_sent_multiple_messages(self):
""" """
Sending Second Message From Inbox Screen Sending Second Message From Inbox Screen
for testing the search and delete functionality for two messages on the screen for testing the search and delete functionality for two messages on the screen
""" """
print("=====================Test - Sending Message From Inbox Screen=====================") print("=====================Test - Sending Message From Inbox Screen=====================")
time.sleep(3) self.cli.sleep(3)
# self.cli.execute('app.root.ids.nav_drawer.set_state("toggle")') # self.cli.execute('app.root.ids.nav_drawer.set_state("toggle")')
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(5) self.cli.sleep(5)
self.cli.click_on('//NavigationItem[1]') self.cli.click_on('//NavigationItem[1]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//Inbox/ComposerButton[0]/MDFloatingActionButton[0]') self.cli.click_on('//Inbox/ComposerButton[0]/MDFloatingActionButton[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[0]/BoxLayout[0]/CustomSpinner[0]/ArrowImg[0]') self.cli.click_on('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[0]/BoxLayout[0]/CustomSpinner[0]/ArrowImg[0]')
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//MyTextInput[0]') self.cli.click_on('//MyTextInput[0]')
time.sleep(3) self.cli.sleep(3)
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/BoxLayout[0]/MyTextInput[0]', "text", data[0]) self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/BoxLayout[1]/BoxLayout[0]/MyTextInput[0]', "text", data[0])
time.sleep(3) self.cli.sleep(3)
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]', 'text', 'Second') self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/MyMDTextField[0]', 'text', 'Second')
time.sleep(3) self.cli.sleep(3)
random_label="" random_label=""
for char in "Hey This Is Second Message Body": for char in "Hey This Is Second Message Body":
random_label += char random_label += char
self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]',"text",random_label) self.cli.setattr('//DropDownWidget/ScrollView[0]/BoxLayout[0]/ScrollView[0]/TextInput[0]',"text",random_label)
time.sleep(0.2) self.cli.sleep(0.2)
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//MDIconButton[2]') self.cli.click_on('//MDIconButton[2]')
time.sleep(5) self.cli.sleep(5)
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//NavigationItem[2]') self.cli.click_on('//NavigationItem[2]')
time.sleep(3) self.cli.sleep(3)

View File

@ -1,21 +1,16 @@
import time
from bitmessagekivy.tests.telenium_process import TeleniumTestProcess from bitmessagekivy.tests.telenium_process import TeleniumTestProcess
class SettingScreen(TeleniumTestProcess): class SettingScreen(TeleniumTestProcess):
"""Setting Screen Functionality Testing""" """Setting Screen Functionality Testing"""
# @classmethod
# def setUpClass(cls):
# super(SettingScreen, cls).setUpClass()
def test_setting_screen(self): def test_setting_screen(self):
"""Show Setting Screen""" """Show Setting Screen"""
print("=====================Test -Show Setting Screen=====================") print("=====================Test -Show Setting Screen=====================")
time.sleep(4) self.cli.sleep(3)
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(3) self.cli.sleep(3)
self.cli.drag("//NavigationItem[@text=\"Sent\"]","//NavigationItem[@text=\"Inbox\"]",1) self.cli.drag("//NavigationItem[@text=\"Sent\"]","//NavigationItem[@text=\"Inbox\"]",1)
time.sleep(3) self.cli.sleep(3)
self.cli.click_on('//NavigationItem[7]') self.cli.click_on('//NavigationItem[7]')
time.sleep(2) self.cli.sleep(2)

View File

@ -1,4 +1,3 @@
import time
from bitmessagekivy.tests.telenium_process import TeleniumTestProcess from bitmessagekivy.tests.telenium_process import TeleniumTestProcess
@ -6,17 +5,17 @@ class TrashMessage(TeleniumTestProcess):
"""Trash Screen Functionality Testing""" """Trash Screen Functionality Testing"""
def test_delete_trash_message(self): def test_delete_trash_message(self):
"""Delete Message From List of Message Permanently Of Trash Screen/Window""" """Delete Trash message permanently from trash message listing"""
print("=====================Test -Delete Messages Of Trash Screen=====================") print("=====================Test -Delete Message From Trash Message Listing=====================")
time.sleep(6) self.cli.sleep(4)
self.cli.execute('app.clickNavDrawer()') self.cli.execute('app.clickNavDrawer()')
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//NavigationItem[4]') self.cli.click_on('//NavigationItem[4]')
time.sleep(4) self.cli.sleep(4)
self.cli.drag('//Trash/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]//TwoLineAvatarIconListItem[0]/BoxLayout[0]', self.cli.drag('//Trash/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]//TwoLineAvatarIconListItem[0]/BoxLayout[0]',
'//Trash/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]//TwoLineAvatarIconListItem[0]/BoxLayout[2]', 2) '//Trash/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]//TwoLineAvatarIconListItem[0]/BoxLayout[2]', 2)
time.sleep(4) self.cli.sleep(4)
self.cli.click_on('//Trash/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]//Button[0]') self.cli.click_on('//Trash/BoxLayout[0]/BoxLayout[0]/ScrollView[0]/MDList[0]/Carousel[0]//Button[0]')
time.sleep(2) self.cli.sleep(2)
self.cli.click_on('//MDDialog/MDCard[0]/AnchorLayout[0]/MDBoxLayout[0]/MDFlatButton[0]') self.cli.click_on('//MDDialog/MDCard[0]/AnchorLayout[0]/MDBoxLayout[0]/MDFlatButton[0]')
time.sleep(4) self.cli.sleep(4)