diff --git a/python/src/deltachat/message.py b/python/src/deltachat/message.py index 370863231..e94ba0e1c 100644 --- a/python/src/deltachat/message.py +++ b/python/src/deltachat/message.py @@ -276,6 +276,10 @@ class Message(object): """ return True if it's a file message. """ return self._view_type == const.DC_MSG_FILE + def mark_seen(self): + """ mark this message as seen. """ + self.account.mark_seen_messages([self.id]) + # some code for handling DC_MSG_* view types diff --git a/python/tests/test_account.py b/python/tests/test_account.py index cc26d8feb..191178b84 100644 --- a/python/tests/test_account.py +++ b/python/tests/test_account.py @@ -805,7 +805,7 @@ class TestOnlineAccount: lp.sec("check that a second call to mark_seen does not create change or smtp job") ac2._evtracker.consume_events() - ac2.mark_seen_messages([msg_in]) + msg_in.mark_seen() try: ac2._evtracker.get_matching("DC_EVENT_MSG_READ", timeout=0.01) except queue.Empty: diff --git a/python/tox.ini b/python/tox.ini index 1b6f0dbd9..a1d26c4a1 100644 --- a/python/tox.ini +++ b/python/tox.ini @@ -8,7 +8,7 @@ envlist = [testenv] commands = pytest -n6 --reruns 2 --reruns-delay 5 -v -rsXx --ignored {posargs: tests examples} - # python tests/package_wheels.py {toxworkdir}/wheelhouse + python tests/package_wheels.py {toxworkdir}/wheelhouse passenv = TRAVIS DCC_RS_DEV