mirror of
https://github.com/onionshare/onionshare.git
synced 2025-02-14 05:31:25 -05:00
commit
cd3af7283d
@ -80,7 +80,7 @@ class GuiBaseTest(unittest.TestCase):
|
||||
|
||||
def verify_new_tab(self, tab):
|
||||
# Make sure the new tab widget is showing, and no mode has been started
|
||||
QtTest.QTest.qWait(500)
|
||||
QtTest.QTest.qWait(1000)
|
||||
self.assertTrue(tab.new_tab.isVisible())
|
||||
self.assertFalse(hasattr(tab, "share_mode"))
|
||||
self.assertFalse(hasattr(tab, "receive_mode"))
|
||||
@ -349,7 +349,7 @@ class GuiBaseTest(unittest.TestCase):
|
||||
|
||||
def web_server_is_stopped(self, tab):
|
||||
"""Test that the web server also stopped"""
|
||||
QtTest.QTest.qWait(200)
|
||||
QtTest.QTest.qWait(800)
|
||||
|
||||
try:
|
||||
requests.get(f"http://127.0.0.1:{tab.app.port}/")
|
||||
|
@ -33,7 +33,7 @@ class MyOnion:
|
||||
self.scheduled_key = None
|
||||
|
||||
@staticmethod
|
||||
def start_onion_service(self, await_publication=True, save_scheduled_key=False):
|
||||
def start_onion_service(self, mode_settings_obj, await_publication=True, save_scheduled_key=False):
|
||||
return "test_service_id.onion"
|
||||
|
||||
|
||||
|
@ -561,6 +561,11 @@ class TestShare(GuiBaseTest):
|
||||
Rate limit should be triggered
|
||||
"""
|
||||
tab = self.new_share_tab()
|
||||
def accept_dialog():
|
||||
window = tab.common.gui.qtapp.activeWindow()
|
||||
if window:
|
||||
window.close()
|
||||
|
||||
tab.get_mode().autostop_sharing_checkbox.click()
|
||||
|
||||
self.run_all_common_setup_tests()
|
||||
@ -575,6 +580,11 @@ class TestShare(GuiBaseTest):
|
||||
Public mode should skip the rate limit
|
||||
"""
|
||||
tab = self.new_share_tab()
|
||||
def accept_dialog():
|
||||
window = tab.common.gui.qtapp.activeWindow()
|
||||
if window:
|
||||
window.close()
|
||||
|
||||
tab.get_mode().autostop_sharing_checkbox.click()
|
||||
tab.get_mode().mode_settings_widget.public_checkbox.click()
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user