diff options
author | Florian Bruhin <me@the-compiler.org> | 2021-12-23 13:57:30 +0100 |
---|---|---|
committer | Florian Bruhin <me@the-compiler.org> | 2021-12-23 13:57:30 +0100 |
commit | e8bbcf3382708a597aeace3bc650884c37558ea2 (patch) | |
tree | ba0e48ab93bed21c837d450ca0859ec4f41fd573 | |
parent | 7f87ecc1c1fb9decc2d4cfef874563acf10670de (diff) | |
download | qutebrowser-e8bbcf3382708a597aeace3bc650884c37558ea2.tar.gz qutebrowser-e8bbcf3382708a597aeace3bc650884c37558ea2.zip |
Add additional tests
-rw-r--r-- | tests/unit/config/test_configcommands.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/tests/unit/config/test_configcommands.py b/tests/unit/config/test_configcommands.py index 0375503e8..384eb92ab 100644 --- a/tests/unit/config/test_configcommands.py +++ b/tests/unit/config/test_configcommands.py @@ -725,15 +725,19 @@ class TestBind: """Get a dict with no bindings.""" return {'normal': {}} + @pytest.mark.parametrize("mode, url", [ + ("normal", QUrl("qute://bindings")), + ("passthrough", QUrl("qute://bindings#passthrough")), + ]) def test_bind_no_args(self, commands, config_stub, no_bindings, - tabbed_browser_stubs): + tabbed_browser_stubs, mode, url): """Run ':bind'. Should open qute://bindings.""" config_stub.val.bindings.default = no_bindings config_stub.val.bindings.commands = no_bindings - commands.bind(win_id=0) - assert tabbed_browser_stubs[0].loaded_url == QUrl('qute://bindings') + commands.bind(win_id=0, mode=mode) + assert tabbed_browser_stubs[0].loaded_url == url @pytest.mark.parametrize('command', ['nop', 'nope']) def test_bind(self, commands, config_stub, no_bindings, key_config_stub, |