diff options
author | Matthew Lemon <y@yulqen.org> | 2024-09-10 17:37:25 +0100 |
---|---|---|
committer | Matthew Lemon <y@yulqen.org> | 2024-09-10 17:37:25 +0100 |
commit | b17cb510c32e22c59e0140c2f2d90cf6ccbed361 (patch) | |
tree | d69e688432e6063f7390fcf25e95d0919bac1792 /pyblackbird_cc/resources/tests/test_file_processing.py | |
parent | 7550f31f604fa45f9030a32b9b8fbc2d0739bed7 (diff) |
All tests pass and sign-up page is editable
Diffstat (limited to 'pyblackbird_cc/resources/tests/test_file_processing.py')
-rw-r--r-- | pyblackbird_cc/resources/tests/test_file_processing.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/pyblackbird_cc/resources/tests/test_file_processing.py b/pyblackbird_cc/resources/tests/test_file_processing.py index e4ac781..7b95a9d 100644 --- a/pyblackbird_cc/resources/tests/test_file_processing.py +++ b/pyblackbird_cc/resources/tests/test_file_processing.py @@ -1,3 +1,6 @@ +from pathlib import Path + +from django.conf import settings from django.contrib.auth import get_user_model from django.core.files.uploadedfile import InMemoryUploadedFile from django.core.files.uploadedfile import SimpleUploadedFile @@ -5,9 +8,8 @@ from django.core.files.uploadedfile import TemporaryUploadedFile from django.test import TestCase from django.urls import reverse -from ..utils import _get_pdf_collection_type - from .. import services +from ..utils import _get_pdf_collection_type def test_detect_snapshotted_pdf_collection(): @@ -25,7 +27,9 @@ def test_detect_snapshotted_pdf_collection(): class PDFFileUploadTestCase(TestCase): def setUp(self): self.url = reverse("resources:create_resource") - self.test_file_path = "resources/tests/testdata/test_small_file.pdf" + self.test_file_path = Path( + settings.BASE_DIR / "pyblackbird_cc" / "resources/tests/testdata/test_small_file.pdf" + ) # Create a test user self.email = "testuser@example.com" |