15 lines
397 B
Python
15 lines
397 B
Python
import pytest
|
|
|
|
from django.test import Client
|
|
from django.utils import timezone
|
|
|
|
pytestmark = pytest.mark.django_db
|
|
|
|
|
|
class TestRendererFormView:
|
|
|
|
def test_get_empty_form(self, client: Client):
|
|
response = client.get('/renderer/')
|
|
assert response.status_code == 200
|
|
assert response.context['form']['date'].value() \
|
|
== timezone.now().strftime('%Y-%m-%d')
|