apply code review and also catch "." as username

This commit is contained in:
holger krekel
2024-07-09 18:46:37 +02:00
parent a1f0a3e23b
commit 0d593c22d1
2 changed files with 13 additions and 3 deletions

View File

@@ -43,7 +43,15 @@ def test_get_user_maildir(make_config):
with pytest.raises(ValueError):
config.get_user_maildir("")
with pytest.raises(ValueError):
config.get_user_maildir(None)
with pytest.raises(ValueError):
config.get_user_maildir("../some@something.testrun.org")
with pytest.raises(ValueError):
config.get_user_maildir("..")
with pytest.raises(ValueError):
config.get_user_maildir(".")