Split backend tests into unit and integration suites, add isolated fixtures and coverage enforcement, and update CI and test documentation. Cover current authentication, content, notification, payment, media, and admin flows; fix behaviors revealed by the new tests. Validate both suites and the per-module gate against local PostgreSQL.
14 lines
426 B
Python
14 lines
426 B
Python
import pytest
|
|
|
|
from apps.communications.resources import AnnouncementResource, PushNotificationDeviceResource
|
|
|
|
|
|
pytestmark = pytest.mark.unit
|
|
|
|
|
|
def test_communication_exports_reference_users_by_username():
|
|
announcements = AnnouncementResource()
|
|
devices = PushNotificationDeviceResource()
|
|
assert announcements.fields["author"].widget.field == "username"
|
|
assert devices.fields["user"].widget.field == "username"
|