chore: test edit network fixed

This commit is contained in:
Valentina Novgorodtceva 2024-01-16 13:24:39 +07:00 committed by Valentina1133
parent f2721bc0b1
commit a467cbf9f9
3 changed files with 8 additions and 11 deletions

View File

@ -45,8 +45,8 @@ class WalletNetworkNaming(Enum):
class WalletNetworkDefaultValues(Enum):
ETHEREUM_LIVE_MAIN = 'https://eth-archival.gateway.pokt.network'
ETHEREUM_TEST_MAIN = 'https://goerli-archival.gateway.pokt.network'
ETHEREUM_LIVE_MAIN = 'https://eth-archival.rpc.grove.city'
ETHEREUM_TEST_MAIN = 'https://goerli-archival.rpc.grove.city'
ETHEREUM_LIVE_FAILOVER = 'https://mainnet.infura.io'
ETHEREUM_TEST_FAILOVER = 'https://goerli.infura.io'

View File

@ -461,14 +461,12 @@ class EditNetworkSettings(WalletSettingsView):
self._live_network_tab.click()
current_value = self.get_edit_network_main_json_rpc_url_value()
return True if current_value.startswith(
WalletNetworkDefaultValues.ETHEREUM_LIVE_MAIN.value) and current_value.endswith("****") \
else False
WalletNetworkDefaultValues.ETHEREUM_LIVE_MAIN.value) and current_value.endswith("****") else False
case WalletNetworkSettings.EDIT_NETWORK_TEST_TAB.value:
self._test_network_tab.click()
current_value = self.get_edit_network_main_json_rpc_url_value()
return True if current_value.startswith(
WalletNetworkDefaultValues.ETHEREUM_TEST_MAIN.value) and current_value.endswith("****") \
else False
WalletNetworkDefaultValues.ETHEREUM_TEST_MAIN.value) and current_value.endswith("****") else False
@allure.step('Verify value in Failover JSON RPC input')
def verify_edit_network_failover_json_rpc_url_value(self, network_tab):
@ -477,14 +475,14 @@ class EditNetworkSettings(WalletSettingsView):
self._live_network_tab.click()
current_value = self.get_edit_network_failover_json_rpc_url_value()
return True if current_value.startswith(
WalletNetworkDefaultValues.ETHEREUM_LIVE_FAILOVER.value) and current_value.endswith("****") \
else False
WalletNetworkDefaultValues.ETHEREUM_LIVE_FAILOVER.value) and current_value.endswith(
"****") else False
case WalletNetworkSettings.EDIT_NETWORK_TEST_TAB.value:
self._test_network_tab.click()
current_value = self.get_edit_network_failover_json_rpc_url_value()
return True if current_value.startswith(
WalletNetworkDefaultValues.ETHEREUM_TEST_FAILOVER.value) and current_value.endswith("****") \
else False
WalletNetworkDefaultValues.ETHEREUM_TEST_FAILOVER.value) and current_value.endswith(
"****") else False
class EditAccountOrderSettings(WalletSettingsView):

View File

@ -17,7 +17,6 @@ pytestmark = marks
pytest.param(WalletNetworkSettings.EDIT_NETWORK_LIVE_TAB.value),
pytest.param(WalletNetworkSettings.EDIT_NETWORK_TEST_TAB.value)
])
@pytest.mark.skip(reason="https://github.com/status-im/desktop-qa-automation/issues/440")
def test_settings_networks_edit_restore_defaults(main_screen: MainWindow, network_tab: str):
networks = main_screen.left_panel.open_settings().left_panel.open_wallet_settings().open_networks()