mirror of
https://github.com/deltachat/deltachat-core.git
synced 2025-10-04 02:09:17 +02:00
make set_config|get_config throw an informative error if you try to get/set non-existing config keys
This commit is contained in:
parent
987dc80033
commit
0bbeb65d94
2 changed files with 16 additions and 0 deletions
|
@ -13,6 +13,13 @@ class TestOfflineAccount:
|
|||
with pytest.raises(ValueError):
|
||||
ac1.check_is_configured()
|
||||
|
||||
def test_wrong_config_keys(self, acfactory):
|
||||
ac1 = acfactory.get_unconfigured_account()
|
||||
with pytest.raises(KeyError):
|
||||
ac1.set_config("lqkwje", "value")
|
||||
with pytest.raises(KeyError):
|
||||
ac1.get_config("lqkwje")
|
||||
|
||||
def test_selfcontact_if_unconfigured(self, acfactory):
|
||||
ac1 = acfactory.get_unconfigured_account()
|
||||
with pytest.raises(ValueError):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue