diff options
Diffstat (limited to 'tests/unit/completion/test_models.py')
-rw-r--r-- | tests/unit/completion/test_models.py | 22 |
1 files changed, 5 insertions, 17 deletions
diff --git a/tests/unit/completion/test_models.py b/tests/unit/completion/test_models.py index 6dea77321..e0bce8f04 100644 --- a/tests/unit/completion/test_models.py +++ b/tests/unit/completion/test_models.py @@ -1,19 +1,6 @@ -# Copyright 2016-2021 Ryan Roden-Corrent (rcorre) <ryan@rcorre.net> +# SPDX-FileCopyrightText: Ryan Roden-Corrent (rcorre) <ryan@rcorre.net> # -# This file is part of qutebrowser. -# -# qutebrowser is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# (at your option) any later version. -# -# qutebrowser is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with qutebrowser. If not, see <https://www.gnu.org/licenses/>. +# SPDX-License-Identifier: GPL-3.0-or-later """Tests for completion models.""" @@ -1323,11 +1310,11 @@ def test_url_completion_benchmark(benchmark, info, web_history.completion.insert_batch(entries) quickmark_manager_stub.marks = collections.OrderedDict([ - ('title{}'.format(i), 'example.com/{}'.format(i)) + ('title{}'.format('a'*i), 'example.com/{}'.format(i)) for i in range(1000)]) bookmark_manager_stub.marks = collections.OrderedDict([ - ('example.com/{}'.format(i), 'title{}'.format(i)) + ('example.com/{}'.format('a'*i), 'title{}'.format(i)) for i in range(1000)]) def bench(): @@ -1339,6 +1326,7 @@ def test_url_completion_benchmark(benchmark, info, model.set_pattern('ex 1') model.set_pattern('ex 12') model.set_pattern('ex 123') + model.set_pattern('zzzzz') # no match benchmark(bench) |