diff options
author | mathieui <mathieui@mathieui.net> | 2021-07-02 21:10:20 +0200 |
---|---|---|
committer | mathieui <mathieui@mathieui.net> | 2021-07-02 21:10:20 +0200 |
commit | e3b07d95f252a3dd54ea98b4fd5168b2e79d1be3 (patch) | |
tree | 9347137752f64c881586e762930c6dd644c84f32 | |
parent | 66c615fd94ae90772d5aa5ca3ab3b49487615f73 (diff) | |
download | poezio-e3b07d95f252a3dd54ea98b4fd5168b2e79d1be3.tar.gz poezio-e3b07d95f252a3dd54ea98b4fd5168b2e79d1be3.tar.bz2 poezio-e3b07d95f252a3dd54ea98b4fd5168b2e79d1be3.tar.xz poezio-e3b07d95f252a3dd54ea98b4fd5168b2e79d1be3.zip |
tests: fix expected get_by_tabname input type
-rw-r--r-- | test/test_config.py | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/test/test_config.py b/test/test_config.py index e562f425..8e92bf3f 100644 --- a/test/test_config.py +++ b/test/test_config.py @@ -9,6 +9,7 @@ from pathlib import Path import pytest from poezio import config +from slixmpp import JID @pytest.fixture(scope="module") @@ -104,10 +105,10 @@ class TestTabNames(object): config_obj.set_and_save('test2', value='value2@toto.com', section='@toto.com') - assert config_obj.get_by_tabname('test', 'toto@toto.com') == 'value.toto@toto.com' - assert config_obj.get_by_tabname('test2', 'toto@toto.com') == 'value2@toto.com' - assert config_obj.get_by_tabname('test2', 'toto@toto.com', fallback=False) == 'value2@toto.com' - assert config_obj.get_by_tabname('test2', 'toto@toto.com', fallback_server=False) == 'true' - assert config_obj.get_by_tabname('test_int', 'toto@toto.com', fallback=False) == '' + assert config_obj.get_by_tabname('test', JID('toto@toto.com')) == 'value.toto@toto.com' + assert config_obj.get_by_tabname('test2', JID('toto@toto.com')) == 'value2@toto.com' + assert config_obj.get_by_tabname('test2', JID('toto@toto.com'), fallback=False) == 'value2@toto.com' + assert config_obj.get_by_tabname('test2', JID('toto@toto.com'), fallback_server=False) == 'true' + assert config_obj.get_by_tabname('test_int', JID('toto@toto.com'), fallback=False) == '' |