From bef8cacdc8eb06d2b6198c66e0538d36feb0f59c Mon Sep 17 00:00:00 2001 From: Malene Lundemo Date: Thu, 3 Apr 2025 15:40:41 +0200 Subject: [PATCH] Delete backend/tests/test_robust_boundary_file_size.py --- .../tests/test_robust_boundary_file_size.py | 19 ------------------- 1 file changed, 19 deletions(-) delete mode 100644 backend/tests/test_robust_boundary_file_size.py diff --git a/backend/tests/test_robust_boundary_file_size.py b/backend/tests/test_robust_boundary_file_size.py deleted file mode 100644 index 325b4d1..0000000 --- a/backend/tests/test_robust_boundary_file_size.py +++ /dev/null @@ -1,19 +0,0 @@ -""" -TC_003 - Robust boundary test for file size above maximum size -""" -from django.test import TestCase - -def test_file_size_robust_boundary(self): - # Creates a file with invalid size - invalid_above_file = SimpleUploadedFile("test_above_max.txt", b"x" * (max_size + 1)) - # Creates AthleteFile object with the invalid file - athlete_above_file = AthleteFile(athlete=self.user, owner=self.user, file=invalid_above_file) - - try: - # Runs a validation check - athlete_above_file.full_clean() - # Fails if no validation errors are raised - self.fail("ValidationError not raised for file above maximum size.") - except ValidationError as e: - # Passes if validation error is raised. - self.assertIn('file', e.message_dict)