2021-05-31 01:11:50 +02:00
|
|
|
import pytest
|
|
|
|
|
2021-08-16 10:49:52 +02:00
|
|
|
from mobilizon_reshare.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"
|