mirror of
https://github.com/chatmail/core.git
synced 2026-04-05 23:22:11 +03:00
python: test get_mute_duration()
This commit is contained in:
committed by
link2xt
parent
da5796e8a6
commit
6d68fd4500
@@ -276,12 +276,15 @@ class TestOfflineChat:
|
||||
def test_mute(self, ac1):
|
||||
chat = ac1.create_group_chat(name="title1")
|
||||
assert not chat.is_muted()
|
||||
assert chat.get_mute_duration() == 0
|
||||
chat.mute()
|
||||
assert chat.is_muted()
|
||||
assert chat.get_mute_duration() == -1
|
||||
chat.unmute()
|
||||
assert not chat.is_muted()
|
||||
chat.mute(50)
|
||||
assert chat.is_muted()
|
||||
assert chat.get_mute_duration() <= 50
|
||||
with pytest.raises(ValueError):
|
||||
chat.mute(-51)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user