diff options
Diffstat (limited to 'tests/unit/mainwindow/statusbar/test_textbase.py')
-rw-r--r-- | tests/unit/mainwindow/statusbar/test_textbase.py | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/tests/unit/mainwindow/statusbar/test_textbase.py b/tests/unit/mainwindow/statusbar/test_textbase.py index fbf1688e9..982b09736 100644 --- a/tests/unit/mainwindow/statusbar/test_textbase.py +++ b/tests/unit/mainwindow/statusbar/test_textbase.py @@ -25,12 +25,15 @@ import pytest from qutebrowser.mainwindow.statusbar.textbase import TextBase -@pytest.mark.parametrize('elidemode, check', [ - (QtCore.Qt.ElideRight, lambda s: s.endswith('…') or s.endswith('...')), - (QtCore.Qt.ElideLeft, lambda s: s.startswith('…') or s.startswith('...')), - (QtCore.Qt.ElideMiddle, lambda s: '…' in s or '...' in s), - (QtCore.Qt.ElideNone, lambda s: '…' not in s and '...' not in s), -]) +@pytest.mark.parametrize( + 'elidemode, check', + [ + (QtCore.Qt.ElideRight, lambda s: s.endswith('…') or s.endswith('...')), + (QtCore.Qt.ElideLeft, lambda s: s.startswith('…') or s.startswith('...')), + (QtCore.Qt.ElideMiddle, lambda s: '…' in s or '...' in s), + (QtCore.Qt.ElideNone, lambda s: '…' not in s and '...' not in s), + ], +) def test_elided_text(fake_statusbar, qtbot, elidemode, check): """Ensure that a widget too small to hold the entire label text will elide. |