The example provided here suggests there’s no need to manually set db.app… However, it turns out that’s only true if the db knows about the current app, which isn’t always the case.
This PR sets the current app for the test suite (using app_context) and the rest of the time relies on the request to set the context.
Coverage decreased (-0.01%) to 78.164% when pulling 0d7ccb69db75526c552df6c4a36b8fc11a97594f on andylolz:remove-superfluous-line into efdab1f3837f73b7c8b18336e773c4dfbf8ce674 on IATI:master.
The example provided here suggests there’s no need to manually set
db.app
… However, it turns out that’s only true if the db knows about the current app, which isn’t always the case.This PR sets the current app for the test suite (using
app_context
) and the rest of the time relies on the request to set the context.