mirror of
https://github.com/onionshare/onionshare.git
synced 2025-05-17 22:00:38 -04:00
Fix tests in Receive Mode that actually do increment the history item widget count where they didn't previously (due to an additional GET that follows the 302 redirect of a POST request on upload)
This commit is contained in:
parent
26c9256679
commit
8e238ab2d6
2 changed files with 4 additions and 30 deletions
|
@ -116,7 +116,7 @@ class GuiBaseTest(object):
|
|||
self.assertEqual(mode.history.isVisible(), not currently_visible)
|
||||
|
||||
|
||||
def history_indicator(self, mode, public_mode):
|
||||
def history_indicator(self, mode, public_mode, indicator_count="1"):
|
||||
'''Test that we can make sure the history is toggled off, do an action, and the indiciator works'''
|
||||
# Make sure history is toggled off
|
||||
if mode.history.isVisible():
|
||||
|
@ -147,7 +147,7 @@ class GuiBaseTest(object):
|
|||
|
||||
# Indicator should be visible, have a value of "1"
|
||||
self.assertTrue(mode.toggle_history.indicator_label.isVisible())
|
||||
self.assertEqual(mode.toggle_history.indicator_label.text(), "1")
|
||||
self.assertEqual(mode.toggle_history.indicator_label.text(), indicator_count)
|
||||
|
||||
# Toggle history back on, indicator should be hidden again
|
||||
QtTest.QTest.mouseClick(mode.toggle_history, QtCore.Qt.LeftButton)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue