13 lines
445 B
Python
Raw Normal View History

2021-05-31 01:11:50 +02:00
import pytest
from mobilizon_bots.models.notification import Notification, NotificationStatus
2021-05-31 01:11:50 +02:00
@pytest.mark.asyncio
async def test_notification_create(notification_model_generator):
notification_model = notification_model_generator()
await notification_model.save()
notification_db = await Notification.all().first()
assert notification_db.status == NotificationStatus.WAITING
assert notification_db.message == "message_1"