From d6b6682bec8dbf109fc4c026bdf29c276091cf84 Mon Sep 17 00:00:00 2001 From: Hamza Kundi Date: Mon, 6 Nov 2023 09:19:50 -0800 Subject: [PATCH] further fixed testing --- coldfront/config/test_settings.py.sample | 15 +++++++++------ .../test_addition_views/test_request_view.py | 5 +---- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/coldfront/config/test_settings.py.sample b/coldfront/config/test_settings.py.sample index b14dee7a8..60667fe40 100644 --- a/coldfront/config/test_settings.py.sample +++ b/coldfront/config/test_settings.py.sample @@ -66,17 +66,20 @@ REQUEST_APPROVAL_CC_LIST = ['test@test.test'] GOOGLE_DRIVE_PERMISSIONS = () FILE_STORAGE = { - 'backend': 'local_storage', + 'backend': 'google_drive', 'details': { 'NEW_PROJECT_REQUEST_MOU': { - 'location': 'New Project Request MOUs/' + 'location': 'New Project Request MOUs/', + 'filename_type': 'NewProject_MOU', + }, + 'SERVICE_UNITS_PURCHASE_REQUEST_MOU': { + 'location': 'Service Units Purchase Request MOUs/', + 'filename_type': 'AllowancePurchase_MOU', }, 'SECURE_DIRECTORY_REQUEST_MOU': { - 'location': 'Secure Directory Request MOUs/' + 'location': 'Secure Directory Request MOUs/', + 'filename_type': 'SecureDirectory_RUA', }, - 'SERVICE_UNITS_PURCHASE_REQUEST_MOU': { - 'location': 'Service Units Purchase Request MOUs/' - } }, } diff --git a/coldfront/core/project/tests/test_views/test_addition_views/test_request_view.py b/coldfront/core/project/tests/test_views/test_addition_views/test_request_view.py index 1cded3688..e964abfdc 100644 --- a/coldfront/core/project/tests/test_views/test_addition_views/test_request_view.py +++ b/coldfront/core/project/tests/test_views/test_addition_views/test_request_view.py @@ -181,10 +181,7 @@ def test_valid_post(self): extra_fields = request.extra_fields self.assertEqual(len(extra_fields), len(data)) for field in data: - if field == 'num_service_units': - self.assertNotIn(field, extra_fields) - else: - self.assertEqual(data[field], extra_fields[field]) + self.assertEqual(data[field], extra_fields[field]) # A notification email should have been sent to admins. self.assertEqual(len(mail.outbox), 1)