We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e37d30b commit 1651058Copy full SHA for 1651058
tests/all/integration/api/helpers/test_scheduled_jobs.py
@@ -1,6 +1,6 @@
1
import datetime
2
3
-from app import db
+from app import current_app as app, db
4
from app.factories.event_invoice import EventInvoiceFactory
5
from app.models.event_invoice import EventInvoice
6
from app.api.helpers.scheduled_jobs import event_invoices_mark_due
@@ -13,7 +13,7 @@ class TestScheduledJobs(OpenEventTestCase):
13
def test_event_invoices_mark_due(self):
14
"""Method to test marking of event invoices as due"""
15
16
- with self.app.test_request_context():
+ with app.test_request_context():
17
event_invoice = EventInvoiceFactory(event__ends_at=datetime.datetime(2019, 7, 20))
18
db.session.commit()
19
event_invoice_id = event_invoice.id
0 commit comments