diff --git a/tests/core/jobs/test_playtime_entries.py b/tests/core/jobs/test_playtime_entries.py index dc7ba5b1e9..6d9e994e57 100644 --- a/tests/core/jobs/test_playtime_entries.py +++ b/tests/core/jobs/test_playtime_entries.py @@ -163,15 +163,14 @@ def test_do_run(self, db: DatabaseTransactionFixture): playtime(db.session, identifier2, date3m(3), 5) playtime(db.session, identifier2, date3m(4), 6) - with ( - patch("core.jobs.playtime_entries.csv.writer") as writer, - patch("core.jobs.playtime_entries.EmailManager") as email, - patch( - "core.jobs.playtime_entries.os.environ", - new={ - Configuration.REPORTING_EMAIL_ENVIRONMENT_VARIABLE: "reporting@test.email" - }, - ), + # Horrible unbracketted syntax for python 3.8 + with patch("core.jobs.playtime_entries.csv.writer") as writer, patch( + "core.jobs.playtime_entries.EmailManager" + ) as email, patch( + "core.jobs.playtime_entries.os.environ", + new={ + Configuration.REPORTING_EMAIL_ENVIRONMENT_VARIABLE: "reporting@test.email" + }, ): PlaytimeEntriesEmailReportsScript(db.session).run()