diff --git a/lego/apps/events/tasks.py b/lego/apps/events/tasks.py index 3d1945c6c..98b60752a 100644 --- a/lego/apps/events/tasks.py +++ b/lego/apps/events/tasks.py @@ -624,7 +624,8 @@ def assign_penalties_and_unregister_when_payment_overdue(self, logger_context=No event.unregister( registration, - admin_unregistration_reason="Automated unregister", # Needed to not give double penalties + # Needed to not give double penalties + admin_unregistration_reason="Automated unregister", ) notification = EventPaymentOverduePenaltyNotification( diff --git a/lego/apps/events/tests/test_async_tasks.py b/lego/apps/events/tests/test_async_tasks.py index ca81213a5..afbae541f 100644 --- a/lego/apps/events/tests/test_async_tasks.py +++ b/lego/apps/events/tests/test_async_tasks.py @@ -787,7 +787,9 @@ def test_creator_notification_is_not_sent_past_end_time(self, mock_notification) def test_user_is_given_penalty_is_unregistered_and_notified( self, mock_notification ): - """Test that user is given a penalty, is unregistered and notified when payment is overdue""" + """ + Test that user is given a penalty, is unregistered and notified when payment is overdue + """ self.event.payment_due_date = timezone.now() - timedelta(days=2) self.event.save() @@ -822,7 +824,9 @@ def test_user_is_given_penalty_is_unregistered_and_notified( def test_user_is_not_given_penalty_is_not_unregistered_and_not_notified( self, mock_notification ): - """Test that user is NOT given a penalty, is unregistered and notified when payment is overdue""" + """ + Test that user is NOT given a penalty, is unregistered and notified when payment is overdue + """ self.event.payment_due_date = timezone.now() + timedelta(days=2) self.event.save()