diff --git a/lostplaces/lostplaces_app/tests/models/test_voucher_model.py b/lostplaces/lostplaces_app/tests/models/test_voucher_model.py index 5ab7b4b..608f38b 100644 --- a/lostplaces/lostplaces_app/tests/models/test_voucher_model.py +++ b/lostplaces/lostplaces_app/tests/models/test_voucher_model.py @@ -2,6 +2,7 @@ import datetime from django.test import TestCase from django.db import models +from django.utils import timezone from lostplaces_app.models import Voucher from lostplaces_app.tests.models import ModelTestCase @@ -10,7 +11,7 @@ from lostplaces_app.tests.models import ModelTestCase def mock_voucher(): return Voucher.objects.create( code='ayDraJCCwfhcFiYmSR5GrcjcchDfcahv', - expires_when=datetime.datetime.now() + datetime.timedelta(days=1) + expires_when=timezone.now() + datetime.timedelta(days=1) )