mirror of
https://github.com/status-im/status-react.git
synced 2025-01-11 11:34:45 +00:00
nightly fixes
Signed-off-by: Churikova Tetiana <churikova.tm@gmail.com>
This commit is contained in:
parent
9e0b8e76cf
commit
dcd2655860
@ -82,5 +82,6 @@
|
|||||||
[::delete-profile/delete-profile @password])
|
[::delete-profile/delete-profile @password])
|
||||||
(reset! password nil))
|
(reset! password nil))
|
||||||
:theme :negative
|
:theme :negative
|
||||||
|
:accessibility-label :delete-profile-confirm
|
||||||
:disabled ((complement valid-password?) @password)}
|
:disabled ((complement valid-password?) @password)}
|
||||||
(i18n/label :t/delete-profile)]]])]]))))
|
(i18n/label :t/delete-profile)]]])]]))))
|
||||||
|
@ -54,11 +54,13 @@ class NetworkApi(object):
|
|||||||
method = self.network_url + 'module=account&action=balance&address=0x%s&tag=latest&apikey=%s' % (address , self.api_key)
|
method = self.network_url + 'module=account&action=balance&address=0x%s&tag=latest&apikey=%s' % (address , self.api_key)
|
||||||
for i in range(5):
|
for i in range(5):
|
||||||
try:
|
try:
|
||||||
return int(requests.request('GET', method, headers=self.headers).json()["result"])
|
self.log('Trying to get balance for %s, attempt %s' % (address, i + 1))
|
||||||
|
balance = requests.request('GET', method, headers=self.headers).json()["result"]
|
||||||
|
self.log('Balance is %s Gwei' % balance)
|
||||||
|
return int(balance)
|
||||||
except JSONDecodeError as e:
|
except JSONDecodeError as e:
|
||||||
self.log(str(e))
|
self.log(str(e))
|
||||||
time.sleep(5)
|
time.sleep(5)
|
||||||
pass
|
|
||||||
|
|
||||||
def get_latest_block_number(self) -> int:
|
def get_latest_block_number(self) -> int:
|
||||||
method = self.network_url + 'module=proxy&action=eth_blockNumber'
|
method = self.network_url + 'module=proxy&action=eth_blockNumber'
|
||||||
|
@ -503,7 +503,7 @@ class TestGroupChatMultipleDevice(MultipleDeviceTestCase):
|
|||||||
device_1_chat.chat_message_input.click()
|
device_1_chat.chat_message_input.click()
|
||||||
for chat in device_1_chat, device_2_chat, device_3_chat:
|
for chat in device_1_chat, device_2_chat, device_3_chat:
|
||||||
if not chat.play_pause_audio_message_button.is_element_displayed():
|
if not chat.play_pause_audio_message_button.is_element_displayed():
|
||||||
self.errors.append('Audio message is not shown in chat after sending for sender')
|
self.errors.append('Audio message is not shown in chat after sending!')
|
||||||
|
|
||||||
device_1.just_fyi('Send sticker to group chat and verify it on all devices')
|
device_1.just_fyi('Send sticker to group chat and verify it on all devices')
|
||||||
device_1_chat.profile_button.click()
|
device_1_chat.profile_button.click()
|
||||||
|
@ -157,7 +157,7 @@ class TestBrowsing(SingleDeviceTestCase):
|
|||||||
home_view = sign_in.create_user()
|
home_view = sign_in.create_user()
|
||||||
dapp_view = home_view.dapp_tab_button.click()
|
dapp_view = home_view.dapp_tab_button.click()
|
||||||
browsing_view = dapp_view.open_url('google.com')
|
browsing_view = dapp_view.open_url('google.com')
|
||||||
browsing_view.cross_icon.click()
|
browsing_view.back_button.click()
|
||||||
dapp_view = DappsView(self.driver)
|
dapp_view = DappsView(self.driver)
|
||||||
browser_entry = dapp_view.remove_browser_entry_long_press('Google')
|
browser_entry = dapp_view.remove_browser_entry_long_press('Google')
|
||||||
home_view.relogin()
|
home_view.relogin()
|
||||||
@ -166,7 +166,7 @@ class TestBrowsing(SingleDeviceTestCase):
|
|||||||
self.errors.append('The browser entry is present after re-login')
|
self.errors.append('The browser entry is present after re-login')
|
||||||
for entry in ('google.com', 'status.im'):
|
for entry in ('google.com', 'status.im'):
|
||||||
browsing_view = dapp_view.open_url(entry)
|
browsing_view = dapp_view.open_url(entry)
|
||||||
browsing_view.cross_icon.click()
|
browsing_view.back_button.click()
|
||||||
dapp_view.remove_browser_entry_long_press('status', clear_all=True)
|
dapp_view.remove_browser_entry_long_press('status', clear_all=True)
|
||||||
home_view.relogin()
|
home_view.relogin()
|
||||||
home_view.dapp_tab_button.click()
|
home_view.dapp_tab_button.click()
|
||||||
|
@ -514,7 +514,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
|
|||||||
|
|
||||||
send_transaction.just_fyi('Set contact')
|
send_transaction.just_fyi('Set contact')
|
||||||
send_transaction.chose_recipient_button.click()
|
send_transaction.chose_recipient_button.click()
|
||||||
send_transaction.element_by_text('Contacts').click()
|
send_transaction.element_by_text('Contacts').scroll_and_click()
|
||||||
send_transaction.element_by_text(nickname).scroll_and_click()
|
send_transaction.element_by_text(nickname).scroll_and_click()
|
||||||
send_transaction.recipient_done.click()
|
send_transaction.recipient_done.click()
|
||||||
if send_transaction.enter_recipient_address_text.text != \
|
if send_transaction.enter_recipient_address_text.text != \
|
||||||
@ -530,6 +530,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
|
|||||||
send_transaction.ok_button.click()
|
send_transaction.ok_button.click()
|
||||||
send_transaction.element_by_text('↑ 2 STT').scroll_and_click()
|
send_transaction.element_by_text('↑ 2 STT').scroll_and_click()
|
||||||
send_transaction.add_to_favorites(recent_add_to_fav_name)
|
send_transaction.add_to_favorites(recent_add_to_fav_name)
|
||||||
|
wallet_view.element_by_text('Recent').click()
|
||||||
|
|
||||||
send_transaction.just_fyi('Scan code, add it to favorites and recheck that it is preserved')
|
send_transaction.just_fyi('Scan code, add it to favorites and recheck that it is preserved')
|
||||||
send_transaction.scan_qr_code_button.click()
|
send_transaction.scan_qr_code_button.click()
|
||||||
|
@ -59,7 +59,7 @@ class AbstractTestCase:
|
|||||||
desired_caps['build'] = pytest_config_global['build']
|
desired_caps['build'] = pytest_config_global['build']
|
||||||
desired_caps['name'] = test_suite_data.current_test.name
|
desired_caps['name'] = test_suite_data.current_test.name
|
||||||
desired_caps['platformName'] = 'Android'
|
desired_caps['platformName'] = 'Android'
|
||||||
desired_caps['appiumVersion'] = '1.16.0'
|
desired_caps['appiumVersion'] = '1.18.1'
|
||||||
desired_caps['platformVersion'] = '10.0'
|
desired_caps['platformVersion'] = '10.0'
|
||||||
desired_caps['deviceName'] = 'Android GoogleAPI Emulator'
|
desired_caps['deviceName'] = 'Android GoogleAPI Emulator'
|
||||||
desired_caps['deviceOrientation'] = "portrait"
|
desired_caps['deviceOrientation'] = "portrait"
|
||||||
|
@ -127,6 +127,7 @@ class DappsView(BaseView):
|
|||||||
self.enter_url_editbox.click()
|
self.enter_url_editbox.click()
|
||||||
self.enter_url_editbox.send_keys(url)
|
self.enter_url_editbox.send_keys(url)
|
||||||
self.confirm()
|
self.confirm()
|
||||||
|
self.progress_bar.wait_for_invisibility_of_element(50)
|
||||||
return self.get_base_web_view()
|
return self.get_base_web_view()
|
||||||
|
|
||||||
def get_browser_entry(self, name):
|
def get_browser_entry(self, name):
|
||||||
|
@ -573,7 +573,7 @@ class DeleteMyProfilePasswordInput(BaseEditBox):
|
|||||||
class DeleteProfileButton(BaseButton):
|
class DeleteProfileButton(BaseButton):
|
||||||
def __init__(self, driver):
|
def __init__(self, driver):
|
||||||
super(DeleteProfileButton, self).__init__(driver)
|
super(DeleteProfileButton, self).__init__(driver)
|
||||||
self.locator = self.Locator.xpath_selector('(//*[@text="Delete profile"])[2]')
|
self.locator = self.Locator.accessibility_id('delete-profile-confirm')
|
||||||
|
|
||||||
class UseMobileDataToggle(BaseButton):
|
class UseMobileDataToggle(BaseButton):
|
||||||
def __init__(self, driver):
|
def __init__(self, driver):
|
||||||
|
@ -69,6 +69,10 @@ class ChooseRecipientButton(BaseButton):
|
|||||||
super(ChooseRecipientButton, self).__init__(driver)
|
super(ChooseRecipientButton, self).__init__(driver)
|
||||||
self.locator = self.Locator.accessibility_id('choose-recipient-button')
|
self.locator = self.Locator.accessibility_id('choose-recipient-button')
|
||||||
|
|
||||||
|
def click(self):
|
||||||
|
self.click_until_presence_of_element(AccountsButton(self.driver))
|
||||||
|
return self.navigate()
|
||||||
|
|
||||||
|
|
||||||
class AccountsButton(BaseButton):
|
class AccountsButton(BaseButton):
|
||||||
def __init__(self, driver):
|
def __init__(self, driver):
|
||||||
|
@ -262,7 +262,7 @@ class SignInView(BaseView):
|
|||||||
def create_user(self, password=common_password, keycard=False, enable_notifications=False):
|
def create_user(self, password=common_password, keycard=False, enable_notifications=False):
|
||||||
self.get_started_button.click()
|
self.get_started_button.click()
|
||||||
self.generate_key_button.click_until_presence_of_element(self.next_button)
|
self.generate_key_button.click_until_presence_of_element(self.next_button)
|
||||||
self.next_button.click()
|
self.next_button.click_until_absense_of_element(self.element_by_text_part('Choose a chat name'))
|
||||||
if keycard:
|
if keycard:
|
||||||
keycard_flow = self.keycard_storage_button.click()
|
keycard_flow = self.keycard_storage_button.click()
|
||||||
keycard_flow.confirm_pin_and_proceed()
|
keycard_flow.confirm_pin_and_proceed()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user