aboutsummaryrefslogtreecommitdiffstats
path: root/tests/test_gui.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_gui.py')
-rw-r--r--tests/test_gui.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/test_gui.py b/tests/test_gui.py
index 891584b..8a5b6e3 100644
--- a/tests/test_gui.py
+++ b/tests/test_gui.py
@@ -515,6 +515,11 @@ class SmokeTest(unittest.TestCase):
self.assertEqual(len(w.hint_dialogs), 1)
d = w.hint_dialogs[0]
self.assertIn('-VERSION="3.11.1"\n+VERSION="3.12.0"', d.diff.toPlainText())
+ doc = d.diff.document()
+ colors = {doc.findBlockByNumber(i).text()[:3]:
+ doc.findBlockByNumber(i).layout().formats()[0].format.foreground().color().name()
+ for i in range(doc.blockCount()) if doc.findBlockByNumber(i).layout().formats()}
+ self.assertEqual(colors, {"@@ ": "#3b8bd0", '-VE': "#d03b3b", '+VE': "#0ca30c"})
d.revert()
d.revert() # a second revert must not reach the helper: it would delete the hint
self.assertEqual([c for c in remote.calls if c[0] == "hint-revert"], [("hint-revert", "nuclei")])