33import string
44
55import allure
6+ import psutil
67import pytest
78from allure import step
89from . import marks
@@ -28,8 +29,11 @@ def keys_screen(main_window) -> KeysView:
2829
2930
3031@allure .testcase ('https://ethstatus.testrail.net/index.php?/cases/view/703421' , 'Generate new keys' )
31- @pytest .mark .case (703421 )
32+ @allure .testcase ('https://ethstatus.testrail.net/index.php?/cases/view/703010' , 'Settings - Sign out & Quit' )
33+ @pytest .mark .case (703421 , 703010 )
3234@pytest .mark .critical
35+ @pytest .mark .flaky
36+ # reason='https://github.com/status-im/status-desktop/issues/13013'
3337@pytest .mark .parametrize ('user_name, password, user_image, zoom, shift' , [
3438 pytest .param (
3539 '' .join ((random .choice (
@@ -44,7 +48,7 @@ def keys_screen(main_window) -> KeysView:
4448 5 ,
4549 shift_image (0 , 1000 , 1000 , 0 ))
4650])
47- def test_generate_new_keys (main_window , keys_screen , user_name : str , password , user_image : str , zoom : int , shift ):
51+ def test_generate_new_keys (aut , main_window , keys_screen , user_name : str , password , user_image : str , zoom : int , shift ):
4852
4953 with step ('Click generate new keys and open profile view' ):
5054 profile_view = keys_screen .generate_new_keys ()
@@ -118,3 +122,14 @@ def test_generate_new_keys(main_window, keys_screen, user_name: str, password, u
118122 f'Chat key in user profile is wrong, current: { profile_popup_chat_key } , expected: { chat_key } '
119123 assert profile_popup .get_emoji_hash == emoji_hash_public_key , \
120124 f'Public keys should match when they dont'
125+
126+ with step ('Open settings again' ):
127+ main_window .left_panel .click ()
128+ settings = main_window .left_panel .open_settings ()
129+
130+ with step ('Click sign out and quit in settings' ):
131+ sign_out_screen = settings .left_panel .open_sign_out_and_quit ()
132+ sign_out_screen .sign_out_and_quit ()
133+
134+ with step ('Check that app was closed' ):
135+ psutil .Process (aut .pid ).wait (timeout = 10 )
0 commit comments