diff --git a/qutebrowser/browser/commands.py b/qutebrowser/browser/commands.py index f3f12acba..b6e4a2211 100644 --- a/qutebrowser/browser/commands.py +++ b/qutebrowser/browser/commands.py @@ -975,12 +975,12 @@ class CommandDispatcher: self._tab_focus_last() return index = count if count is not None else index + if index is None: self.tab_next() return elif index == 0: index = self._count() - elif index < 0: index = self._count() + index + 1 diff --git a/tests/unit/commands/test_cmdutils.py b/tests/unit/commands/test_cmdutils.py index 264da8087..aaf63014e 100644 --- a/tests/unit/commands/test_cmdutils.py +++ b/tests/unit/commands/test_cmdutils.py @@ -431,7 +431,6 @@ class TestArgument: pass expected = "zero_count argument cannot exist without count!" - assert str(excinfo.value) == expected def test_no_docstring(self, caplog):