From eb4691adfce64ff9a6b6e60c48489fa9bfd6db20 Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Mon, 11 Sep 2017 21:51:18 +0200 Subject: [PATCH] Fix test_progress_affecting_statusbar_height on Windows Fixes #2825 --- tests/unit/mainwindow/statusbar/test_progress.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/unit/mainwindow/statusbar/test_progress.py b/tests/unit/mainwindow/statusbar/test_progress.py index 753838842..91dd4ef18 100644 --- a/tests/unit/mainwindow/statusbar/test_progress.py +++ b/tests/unit/mainwindow/statusbar/test_progress.py @@ -68,12 +68,16 @@ def test_tab_changed(fake_web_tab, progress_widget, progress, load_status, assert actual == expected -def test_progress_affecting_statusbar_height(fake_statusbar, progress_widget): +def test_progress_affecting_statusbar_height(config_stub, fake_statusbar, + progress_widget): """Make sure the statusbar stays the same height when progress is shown. https://github.com/qutebrowser/qutebrowser/issues/886 https://github.com/qutebrowser/qutebrowser/pull/890 """ + # For some reason on Windows, with Courier, there's a 1px difference. + config_stub.val.fonts.statusbar = '8pt monospace' + expected_height = fake_statusbar.fontMetrics().height() assert fake_statusbar.height() == expected_height