From 969e53b71230a65fe25d0747580321cf938c3fd1 Mon Sep 17 00:00:00 2001 From: Yohann D'ANELLO Date: Tue, 22 Dec 2020 21:31:22 +0100 Subject: [PATCH] Linting --- apps/registration/tests.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/apps/registration/tests.py b/apps/registration/tests.py index 1ce4bea..4f3ff34 100644 --- a/apps/registration/tests.py +++ b/apps/registration/tests.py @@ -1,12 +1,11 @@ from datetime import timedelta import os -from django.core.files.uploadedfile import SimpleUploadedFile - from corres2math.tokens import email_validation_token from django.contrib.auth.models import User from django.contrib.contenttypes.models import ContentType from django.contrib.sites.models import Site +from django.core.files.uploadedfile import SimpleUploadedFile from django.core.management import call_command from django.test import TestCase from django.urls import reverse @@ -291,7 +290,7 @@ class TestRegistration(TestCase): # Don't send too large files response = self.client.post(reverse("registration:upload_user_photo_authorization", args=(self.student.registration.pk,)), data=dict( - photo_authorization=SimpleUploadedFile("file.pdf",content=int(0).to_bytes(2000001, "big"), + photo_authorization=SimpleUploadedFile("file.pdf", content=int(0).to_bytes(2000001, "big"), content_type="application/pdf"), )) self.assertEqual(response.status_code, 200)