fix e2e wallet setup

Signed-off-by: Andrey Shovkoplyas <motor4ik@gmail.com>
This commit is contained in:
Serhy 2019-07-12 10:16:02 +03:00 committed by Andrey Shovkoplyas
parent a71901d897
commit 3c0a24f429
No known key found for this signature in database
GPG Key ID: EAAB7C8622D860A4
10 changed files with 77 additions and 65 deletions

View File

@ -79,9 +79,10 @@
(when forward?
[vector-icons/icon :main-icons/next {:color color}])]]))
(defn button [{:keys [on-press label background? button-style label-style disabled?] :or {background? true disabled? false}}]
(defn button [{:keys [on-press label background? button-style label-style disabled? accessibility-label] :or {background? true disabled? false}}]
[react/touchable-highlight {:style (styles/button button-style background? disabled?)
:on-press on-press
:accessibility-label accessibility-label
:disabled disabled?}
[react/text {:style (merge styles/button-label label-style)}
label]])

View File

@ -74,6 +74,7 @@
(i18n/label :t/ens-wallet-address)]
[react/view {:on-layout #(reset! width (-> % .-nativeEvent .-layout .-width))}
[react/text {:number-of-lines 1 :ellipsize-mode :middle
:accessibility-label :address-text
:style {:line-height 22 :font-size 15
:font-family "monospace"}}
(eip55/address->checksum address-hex)]]]
@ -81,6 +82,7 @@
[react/view {:padding-bottom 16}
[components.common/button {:on-press #(re-frame/dispatch [:wallet.accounts/share])
:button-style {:margin-vertical 20 :margin-horizontal 16}
:accessibility-label :share-address-button
:label (i18n/label :t/share-address)}]
[components.common/button {:on-press #(do
(re-frame/dispatch [:hide-popover])

View File

@ -56,7 +56,7 @@ class TestProfileSingleDevice(SingleDeviceTestCase):
profile_view.click_system_back_button()
profile_view.cross_icon.click()
wallet = profile_view.wallet_button.click()
# wallet.set_up_wallet()
wallet.set_up_wallet()
wallet.accounts_status_account.click()
request = wallet.receive_transaction_button.click()
address = wallet.address_text.text
@ -88,7 +88,7 @@ class TestProfileSingleDevice(SingleDeviceTestCase):
chat.get_back_to_home_view()
wallet = home.wallet_button.click()
# wallet.set_up_wallet()
wallet.set_up_wallet()
wallet.accounts_status_account.click()
wallet.receive_transaction_button.click_until_presence_of_element(wallet.send_transaction_request)
address = wallet.address_text.text

View File

@ -48,7 +48,7 @@ class TestWalletManagement(SingleDeviceTestCase):
sign_in_view = SignInView(self.driver)
home_view = sign_in_view.recover_access(user['passphrase'])
wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
transactions_view = wallet_view.transaction_history_button.click()
transaction_details = transactions_view.transactions_table.transaction_by_index(0).click()
@ -66,7 +66,7 @@ class TestWalletManagement(SingleDeviceTestCase):
sign_in_view = SignInView(self.driver)
home_view = sign_in_view.recover_access(user['passphrase'])
wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
transactions_view = wallet_view.transaction_history_button.click()
transaction_details = transactions_view.transactions_table.transaction_by_index(0).click()
@ -86,7 +86,7 @@ class TestWalletManagement(SingleDeviceTestCase):
sign_in = SignInView(self.driver)
sign_in.create_user()
wallet = sign_in.wallet_button.click()
# wallet.set_up_wallet()
wallet.set_up_wallet()
asset = "MDS"
wallet.select_asset(asset)
wallet.asset_by_name(asset).scroll_to_element()
@ -103,7 +103,7 @@ class TestWalletManagement(SingleDeviceTestCase):
sign_in = SignInView(self.driver)
sign_in.create_user()
wallet = sign_in.wallet_button.click()
# wallet.set_up_wallet()
wallet.set_up_wallet()
# if wallet.backup_recovery_phrase.is_element_present():
# pytest.fail("'Backup your Recovery phrase' option is shown on Wallet for an account with no funds")
# wallet.receive_transaction_button.click()
@ -126,7 +126,7 @@ class TestWalletManagement(SingleDeviceTestCase):
profile = sign_in.profile_button.click()
profile.switch_network('Mainnet with upstream RPC')
wallet = sign_in.wallet_button.click()
# wallet.set_up_wallet()
wallet.set_up_wallet()
asset_name = 'CryptoKitties'
wallet.select_asset(asset_name)
wallet.accounts_status_account.click()
@ -141,7 +141,7 @@ class TestWalletManagement(SingleDeviceTestCase):
sign_in = SignInView(self.driver)
sign_in.create_user()
wallet = sign_in.wallet_button.click()
# wallet.set_up_wallet()
wallet.set_up_wallet()
wallet.accounts_status_account.click()
send_transaction = wallet.send_transaction_button.click()
send_transaction.chose_recipient_button.click()
@ -161,7 +161,7 @@ class TestWalletManagement(SingleDeviceTestCase):
sign_in_view = SignInView(self.driver)
sign_in_view.recover_access(passphrase=user['passphrase'])
wallet_view = sign_in_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
transaction_history = wallet_view.transaction_history_button.click()
transaction_history.filters_button.click()
@ -207,7 +207,7 @@ class TestWalletManagement(SingleDeviceTestCase):
profile.switch_network('Rinkeby with upstream RPC')
profile = home_view.profile_button.click()
wallet_view = profile.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.collectibles_button.click()
if not wallet_view.element_by_text('KDO').is_element_displayed():
self.driver.fail('User collectibles token name in not shown')

View File

@ -24,7 +24,7 @@ class TestCommandsMultipleDevices(MultipleDeviceTestCase):
device_1_home, device_2_home = device_1_sign_in.get_home_view(), device_2_sign_in.get_home_view()
device_1_wallet_view = device_1_home.wallet_button.click()
# device_1_wallet_view.set_up_wallet()
device_1_wallet_view.set_up_wallet()
device_1_wallet_view.home_button.click()
public_key = device_2_home.get_public_key()
@ -83,9 +83,9 @@ class TestCommandsMultipleDevices(MultipleDeviceTestCase):
home_1 = device_1.recover_access(passphrase=sender['passphrase'])
home_2 = device_2.recover_access(passphrase=recipient['passphrase'])
wallet_1, wallet_2 = home_1.wallet_button.click(), home_2.wallet_button.click()
# wallet_1.set_up_wallet()
wallet_1.set_up_wallet()
wallet_1.home_button.click()
# wallet_2.set_up_wallet()
wallet_2.set_up_wallet()
init_balance = wallet_2.get_eth_value()
wallet_2.home_button.click()
@ -135,9 +135,9 @@ class TestCommandsMultipleDevices(MultipleDeviceTestCase):
home_1 = device_1.recover_access(passphrase=sender['passphrase'])
home_2 = device_2.recover_access(passphrase=recipient['passphrase'])
wallet_1, wallet_2 = home_1.wallet_button.click(), home_2.wallet_button.click()
# wallet_1.set_up_wallet()
wallet_1.set_up_wallet()
wallet_1.home_button.click()
# wallet_2.set_up_wallet()
wallet_2.set_up_wallet()
init_balance = wallet_2.get_eth_value()
wallet_2.home_button.click()
@ -180,7 +180,7 @@ class TestCommandsMultipleDevices(MultipleDeviceTestCase):
home_1.add_contact(sender['public_key'])
home_1.get_back_to_home_view()
wallet_1 = home_1.wallet_button.click()
# wallet_1.set_up_wallet()
wallet_1.set_up_wallet()
wallet_1.accounts_status_account.click()
send_transaction_device_1 = wallet_1.receive_transaction_button.click_until_presence_of_element(
@ -221,7 +221,7 @@ class TestCommandsMultipleDevices(MultipleDeviceTestCase):
home_view.home_button.click()
self.network_api.get_donate(sender_address)
wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
home_view.home_button.click()
home_view.add_contact(recipient['public_key'])
chat_view = home_view.get_chat_view()
@ -247,7 +247,7 @@ class TestCommandsMultipleDevices(MultipleDeviceTestCase):
home_1 = device_1.recover_access(passphrase=sender['passphrase'])
home_2 = device_2.recover_access(passphrase=recipient['passphrase'])
wallet_1 = home_1.wallet_button.click()
# wallet_1.set_up_wallet()
wallet_1.set_up_wallet()
wallet_1.home_button.click()
chat_1 = home_1.add_contact(recipient['public_key'])
@ -278,9 +278,9 @@ class TestCommandsMultipleDevices(MultipleDeviceTestCase):
home_1 = device_1.recover_access(passphrase=sender['passphrase'])
home_2 = device_2.recover_access(passphrase=recipient['passphrase'])
wallet_1, wallet_2 = home_1.wallet_button.click(), home_2.wallet_button.click()
# wallet_1.set_up_wallet()
wallet_1.set_up_wallet()
wallet_1.home_button.click()
# wallet_2.set_up_wallet()
wallet_2.set_up_wallet()
wallet_2.home_button.click()
chat_2 = home_2.add_contact(sender['public_key'])
@ -313,7 +313,7 @@ class TestCommandsMultipleDevices(MultipleDeviceTestCase):
home_1 = device_1.recover_access(passphrase=sender['passphrase'])
home_2 = device_2.recover_access(passphrase=recipient['passphrase'])
wallet_1 = home_1.wallet_button.click()
# wallet_1.set_up_wallet()
wallet_1.set_up_wallet()
wallet_1.home_button.click()
chat_1 = home_1.add_contact(recipient['public_key'])
@ -355,7 +355,7 @@ class TestCommandsSingleDevices(SingleDeviceTestCase):
sign_in = SignInView(self.driver)
home = sign_in.recover_access(passphrase=sender['passphrase'], password=unique_password)
wallet = home.wallet_button.click()
# wallet.set_up_wallet()
wallet.set_up_wallet()
wallet.home_button.click()
chat = home.add_contact(basic_user['public_key'])
amount = chat.get_unique_amount()
@ -370,7 +370,7 @@ class TestCommandsSingleDevices(SingleDeviceTestCase):
sign_in = SignInView(self.driver)
home = sign_in.recover_access(passphrase=sender['passphrase'])
wallet = home.wallet_button.click()
# wallet.set_up_wallet()
wallet.set_up_wallet()
wallet.home_button.click()
chat = home.add_contact(recipient['public_key'])
@ -397,7 +397,7 @@ class TestCommandsSingleDevices(SingleDeviceTestCase):
sign_in = SignInView(self.driver)
home = sign_in.recover_access(passphrase=sender['passphrase'])
wallet = home.wallet_button.click()
# wallet.set_up_wallet()
wallet.set_up_wallet()
wallet.home_button.click()
chat = home.add_contact(basic_user['public_key'])
amount = chat.get_unique_amount()
@ -412,7 +412,7 @@ class TestCommandsSingleDevices(SingleDeviceTestCase):
sign_in_view = SignInView(self.driver)
sign_in_view.create_user()
wallet_view = sign_in_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
home_view = wallet_view.home_button.click()
chat_view = home_view.add_contact(basic_user['public_key'])
chat_view.commands_button.click()
@ -447,7 +447,7 @@ class TestCommandsSingleDevices(SingleDeviceTestCase):
sign_in_view = SignInView(self.driver)
sign_in_view.recover_access(sender['passphrase'])
wallet_view = sign_in_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
eth_value = wallet_view.get_eth_value()
stt_value = wallet_view.get_stt_value()

View File

@ -447,6 +447,7 @@ class TestMessagesOneToOneChatMultiple(MultipleDeviceTestCase):
# changing currency for both devices
for device in devices:
wallet_view = device['home_view'].wallet_button.click()
wallet_view.set_up_wallet()
wallet_view.set_currency(device['currency'])
wallet_view.get_back_to_home_view()
@ -455,7 +456,6 @@ class TestMessagesOneToOneChatMultiple(MultipleDeviceTestCase):
# setting up device1 wallet
# wallet1 = device1['home_view'].wallet_button.click()
# wallet1.set_up_wallet()
# wallet1.get_back_to_home_view()
# sending ETH to device2 in 1*1 chat

View File

@ -18,6 +18,8 @@ class TestTransactionDApp(SingleDeviceTestCase):
home_view = sign_in_view.recover_access(sender['passphrase'])
address = sender['address']
initial_balance = self.network_api.get_balance(address)
wallet_view = home_view.wallet_button.click()
wallet_view.set_up_wallet()
status_test_dapp = home_view.open_status_test_dapp()
status_test_dapp.wait_for_d_aap_to_load()
status_test_dapp.assets_button.click()
@ -31,6 +33,8 @@ class TestTransactionDApp(SingleDeviceTestCase):
password = 'password_for_daap'
sign_in_view = SignInView(self.driver)
home_view = sign_in_view.create_user(password=password)
wallet_view = home_view.wallet_button.click()
wallet_view.set_up_wallet()
status_test_dapp = home_view.open_status_test_dapp()
status_test_dapp.wait_for_d_aap_to_load()
status_test_dapp.transactions_button.click()
@ -45,8 +49,8 @@ class TestTransactionDApp(SingleDeviceTestCase):
sender = transaction_senders['L']
sign_in_view = SignInView(self.driver)
home_view = sign_in_view.recover_access(sender['passphrase'])
# wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet() ## will be updated when 'View signing phrase' enabled
wallet_view = home_view.wallet_button.click()
wallet_view.set_up_wallet()
status_test_dapp = home_view.open_status_test_dapp()
status_test_dapp.wait_for_d_aap_to_load()
status_test_dapp.transactions_button.click()
@ -63,8 +67,8 @@ class TestTransactionDApp(SingleDeviceTestCase):
sender = transaction_senders['W']
sign_in_view = SignInView(self.driver)
home_view = sign_in_view.recover_access(sender['passphrase'])
# wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet() ## will be updated when 'View signing phrase' enabled
wallet_view = home_view.wallet_button.click()
wallet_view.set_up_wallet()
status_test_dapp = home_view.open_status_test_dapp()
status_test_dapp.wait_for_d_aap_to_load()
status_test_dapp.transactions_button.click()
@ -80,8 +84,8 @@ class TestTransactionDApp(SingleDeviceTestCase):
sender = transaction_senders['W']
sign_in_view = SignInView(self.driver)
home_view = sign_in_view.recover_access(sender['passphrase'])
# wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet() ## will be updated when 'View signing phrase' enabled
wallet_view = home_view.wallet_button.click()
wallet_view.set_up_wallet()
status_test_dapp = home_view.open_status_test_dapp()
status_test_dapp.wait_for_d_aap_to_load()
status_test_dapp.transactions_button.click()
@ -100,8 +104,8 @@ class TestTransactionDApp(SingleDeviceTestCase):
sender = transaction_senders['Z']
sign_in_view = SignInView(self.driver)
home_view = sign_in_view.recover_access(sender['passphrase'])
# wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet() ## will be updated when 'View signing phrase' enabled
wallet_view = home_view.wallet_button.click()
wallet_view.set_up_wallet()
status_test_dapp = home_view.open_status_test_dapp()
status_test_dapp.wait_for_d_aap_to_load()
status_test_dapp.transactions_button.click()
@ -121,8 +125,8 @@ class TestTransactionDApp(SingleDeviceTestCase):
sender = transaction_senders['M']
sign_in_view = SignInView(self.driver)
home_view = sign_in_view.recover_access(sender['passphrase'], unique_password)
# wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet() ## will be updated when 'View signing phrase' enabled
wallet_view = home_view.wallet_button.click()
wallet_view.set_up_wallet()
status_test_dapp = home_view.open_status_test_dapp()
status_test_dapp.wait_for_d_aap_to_load()
status_test_dapp.assets_button.click()
@ -159,12 +163,11 @@ class TestTransactionDApp(SingleDeviceTestCase):
status_test_dapp.ok_button.click()
status_test_dapp.cross_icon.click()
wallet_view = sign_in_view.wallet_button.click()
# wallet_view.set_up_wallet() ## will be updated when 'View signing phrase' enabled
wallet_view.set_up_wallet()
wallet_view.wait_balance_changed_on_wallet_screen()
@marks.testrail_id(5355)
@marks.medium
@marks.skip # No onboarding for now. TO re-enable once wallet onboarding done
def test_onboarding_screen_when_requesting_tokens_for_new_account(self):
signin_view = SignInView(self.driver)
home_view = signin_view.create_user()
@ -177,7 +180,6 @@ class TestTransactionDApp(SingleDeviceTestCase):
@marks.testrail_id(5677)
@marks.high
@marks.skip # No onboarding for now. TO re-enable once wallet onboarding done
def test_onboarding_screen_when_requesting_tokens_for_recovered_account(self):
signin_view = SignInView(self.driver)
home_view = signin_view.recover_access(passphrase=transaction_senders['U']['passphrase'])
@ -218,7 +220,7 @@ class TestTransactionDApp(SingleDeviceTestCase):
singin_view = SignInView(self.driver)
home_view = singin_view.create_user()
wallet = home_view.wallet_button.click()
# wallet.set_up_wallet()
wallet.set_up_wallet()
wallet_address = wallet.get_wallet_address()
home_view = wallet.get_back_to_home_view()
status_test_dapp = home_view.open_status_test_dapp()
@ -293,7 +295,7 @@ class TestTransactionDApp(SingleDeviceTestCase):
singin_view = SignInView(self.driver)
home_view = singin_view.create_user()
wallet = home_view.wallet_button.click()
# wallet.set_up_wallet()
wallet.set_up_wallet()
wallet.select_asset("STT")
wallet_address = wallet.get_wallet_address()
recipient = '0x' + basic_user['address']

View File

@ -23,7 +23,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
home_view.add_contact(recipient['public_key'])
home_view.get_back_to_home_view()
wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
send_transaction = wallet_view.send_transaction_button.click()
send_transaction.amount_edit_box.click()
@ -47,7 +47,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
sign_in_view = SignInView(self.driver)
home_view = sign_in_view.recover_access(sender['passphrase'])
wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
send_transaction = wallet_view.send_transaction_button.click()
send_transaction.amount_edit_box.click()
@ -73,7 +73,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
home_view.add_contact(recipient['public_key'])
home_view.get_back_to_home_view()
wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
send_transaction = wallet_view.send_transaction_button.click()
stt_button = send_transaction.asset_by_name('STT')
@ -100,7 +100,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
sign_in_view.recover_access(sender['passphrase'])
home_view = sign_in_view.get_home_view()
wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
send_transaction = wallet_view.send_transaction_button.click()
send_transaction.amount_edit_box.click()
@ -155,7 +155,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
sign_in_view.recover_access(sender['passphrase'])
home_view = sign_in_view.get_home_view()
wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
send_transaction = wallet_view.send_transaction_button.click()
send_transaction.amount_edit_box.click()
@ -178,7 +178,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
sign_in_view.recover_access(sender['passphrase'], unique_password)
home_view = sign_in_view.get_home_view()
wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
send_transaction = wallet_view.send_transaction_button.click()
send_transaction.amount_edit_box.click()
@ -204,7 +204,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
home_view.add_contact(recipient['public_key'])
home_view.get_back_to_home_view()
wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
send_transaction = wallet_view.send_transaction_button.click()
adi_button = send_transaction.asset_by_name('ADI')
@ -229,7 +229,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
sign_in_view = SignInView(self.driver)
sign_in_view.recover_access(sender['passphrase'])
wallet_view = sign_in_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
send_transaction = wallet_view.send_transaction_button.click()
adi_button = send_transaction.asset_by_name('ADI')
@ -259,7 +259,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
sign_in_view = SignInView(self.driver)
sign_in_view.recover_access(sender['passphrase'])
wallet_view = sign_in_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
bigger_amount = wallet_view.get_eth_value() + 1
send_transaction = wallet_view.send_transaction_button.click()
@ -286,7 +286,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
sign_in_view = SignInView(self.driver)
sign_in_view.create_user()
wallet_view = sign_in_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.select_asset("STT")
wallet_view.accounts_status_account.click()
send_transaction = wallet_view.send_transaction_button.click()
@ -308,7 +308,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
sign_in_view = SignInView(self.driver)
sign_in_view.recover_access(sender['passphrase'])
wallet_view = sign_in_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
eth_value = wallet_view.get_eth_value()
stt_value = wallet_view.get_stt_value()
if eth_value == 0 or stt_value == 0:
@ -333,13 +333,12 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
@marks.testrail_id(5359)
@marks.critical
# @marks.skip
def test_modify_transaction_fee_values(self):
sender = transaction_senders['U']
sign_in_view = SignInView(self.driver)
sign_in_view.recover_access(sender['passphrase'])
wallet_view = sign_in_view.wallet_button.click()
# wallet_view.set_up_wallet
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
send_transaction = wallet_view.send_transaction_button.click()
@ -387,7 +386,7 @@ class TestTransactionWalletSingleDevice(SingleDeviceTestCase):
signin_view = SignInView(self.driver)
home_view = signin_view.recover_access(passphrase=passphrase)
wallet_view = home_view.wallet_button.click()
# wallet_view.set_up_wallet()
wallet_view.set_up_wallet()
wallet_view.accounts_status_account.click()
transaction_view = wallet_view.transaction_history_button.click()
@ -446,7 +445,7 @@ class TestTransactionWalletMultipleDevice(MultipleDeviceTestCase):
chat_1.get_back_to_home_view()
wallet_1 = home_1.wallet_button.click()
# wallet_1.set_up_wallet()
wallet_1.set_up_wallet()
wallet_1.accounts_status_account.click()
send_transaction = wallet_1.send_transaction_button.click()
send_transaction.amount_edit_box.click()

View File

@ -147,13 +147,13 @@ class ShareButton(BaseButton):
def __init__(self, driver):
super(ShareButton, self).__init__(driver)
self.locator = self.Locator.accessibility_id('share-button')
self.locator = self.Locator.accessibility_id('share-address-button')
class OnboardingMessage(BaseElement):
def __init__(self, driver):
super().__init__(driver)
self.locator = self.Locator.text_selector('Set up your wallet')
self.locator = self.Locator.text_selector('This is your signing phrase')
class NotEnoughEthForGas(BaseText):

View File

@ -98,6 +98,7 @@ class SetUpButton(BaseButton):
super(SetUpButton, self).__init__(driver)
self.locator = self.Locator.text_selector("Lets get set up")
class SetCurrencyButton(BaseButton):
def __init__(self, driver):
super(SetCurrencyButton, self).__init__(driver)
@ -107,7 +108,8 @@ class SetCurrencyButton(BaseButton):
class SignInPhraseText(BaseText):
def __init__(self, driver):
super(SignInPhraseText, self).__init__(driver)
self.locator = self.Locator.xpath_selector('//*[@content-desc="signing-phrase"]//android.widget.TextView')
self.locator = self.Locator.xpath_selector('//*[@text="This is your signing phrase"]'
'//following-sibling::*[2]/android.widget.TextView')
@property
def list(self):
@ -154,12 +156,13 @@ class CurrencyText(BaseText):
super(CurrencyText, self).__init__(driver)
self.locator = self.Locator.accessibility_id('total-amount-currency-text')
class CollectiblesButton(BaseButton):
class CollectiblesButton(BaseButton):
def __init__(self, driver):
super(CollectiblesButton, self).__init__(driver)
self.locator = self.Locator.text_selector('Collectibles')
class BackupRecoveryPhrase(BaseButton):
def __init__(self, driver):
super(BackupRecoveryPhrase, self).__init__(driver)
@ -188,6 +191,12 @@ class AccountsStatusAccount(BaseButton):
self.locator = self.Locator.xpath_selector("//android.widget.HorizontalScrollView//*[@text='Status account']")
class OkGotItButton(BaseButton):
def __init__(self,driver):
super(OkGotItButton, self).__init__(driver)
self.locator = self.Locator.xpath_selector("//*[@text='OK, got it']")
class SendTransactionButton(BaseButton):
def __init__(self, driver):
@ -245,6 +254,7 @@ class WalletView(BaseView):
self.accounts_status_account = AccountsStatusAccount(self.driver)
self.collectibles_button = CollectiblesButton(self.driver)
self.set_currency_button = SetCurrencyButton(self.driver)
self.ok_got_it_button = OkGotItButton(self.driver)
def get_usd_total_value(self):
import re
@ -287,10 +297,8 @@ class WalletView(BaseView):
return ' '.join([element.text for element in self.sign_in_phrase.find_elements()])
def set_up_wallet(self):
self.set_up_button.click()
phrase = self.sign_in_phrase.string
self.done_button.click()
self.yes_button.click()
self.ok_got_it_button.click()
return phrase
def get_wallet_address(self):