diff options
-rw-r--r-- | tests/unit/utils/test_log.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/unit/utils/test_log.py b/tests/unit/utils/test_log.py index f73b88b2c..3ae4c3cfc 100644 --- a/tests/unit/utils/test_log.py +++ b/tests/unit/utils/test_log.py @@ -407,6 +407,12 @@ class TestQtMessageHandler: file = attr.ib(default=None) line = attr.ib(default=None) + @pytest.fixture(autouse=True) + def init_args(self): + parser = qutebrowser.get_argparser() + args = parser.parse_args([]) + log.init_log(args) + def test_empty_message(self, caplog): """Make sure there's no crash with an empty message.""" log.qt_message_handler(QtCore.QtDebugMsg, self.Context(), "") |