From b54b3dabb2c5b409460ba89175e5218f20b100be Mon Sep 17 00:00:00 2001 From: Jon Herron Date: Tue, 15 Nov 2022 15:56:12 -0500 Subject: [PATCH] Getting ./bin/pyl to pass --- .../services/process_instance_report_service.py | 2 +- .../unit/test_process_instance_report_service.py | 14 ++++---------- 2 files changed, 5 insertions(+), 11 deletions(-) diff --git a/spiffworkflow-backend/src/spiffworkflow_backend/services/process_instance_report_service.py b/spiffworkflow-backend/src/spiffworkflow_backend/services/process_instance_report_service.py index 95ba93d7..e90120d8 100644 --- a/spiffworkflow-backend/src/spiffworkflow_backend/services/process_instance_report_service.py +++ b/spiffworkflow-backend/src/spiffworkflow_backend/services/process_instance_report_service.py @@ -19,7 +19,7 @@ class ProcessInstanceReportFilter: process_status: Optional[list[str]] = None def to_dict(self) -> dict[str, str]: - """to_dict.""" + """To_dict.""" d = {} if self.process_model_identifier is not None: diff --git a/spiffworkflow-backend/tests/spiffworkflow_backend/unit/test_process_instance_report_service.py b/spiffworkflow-backend/tests/spiffworkflow_backend/unit/test_process_instance_report_service.py index 0e3227a1..98412faa 100644 --- a/spiffworkflow-backend/tests/spiffworkflow_backend/unit/test_process_instance_report_service.py +++ b/spiffworkflow-backend/tests/spiffworkflow_backend/unit/test_process_instance_report_service.py @@ -13,13 +13,13 @@ from spiffworkflow_backend.services.process_instance_report_service import ( ProcessInstanceReportFilter, ) from spiffworkflow_backend.services.process_instance_report_service import ( - ProcessInstanceReportFilter, ProcessInstanceReportService, ) class TestProcessInstanceReportFilter(BaseTest): """TestProcessInstanceReportFilter.""" + def test_empty_filter_to_dict( self, app: Flask, @@ -40,9 +40,7 @@ class TestProcessInstanceReportFilter(BaseTest): with_super_admin_user: UserModel, ) -> None: """Docstring.""" - d = ProcessInstanceReportFilter( - process_model_identifier="bob" - ).to_dict() + d = ProcessInstanceReportFilter(process_model_identifier="bob").to_dict() assert d == {"process_model_identifier": "bob"} @@ -76,9 +74,7 @@ class TestProcessInstanceReportFilter(BaseTest): with_super_admin_user: UserModel, ) -> None: """Docstring.""" - d = ProcessInstanceReportFilter( - process_status=["bob"] - ).to_dict() + d = ProcessInstanceReportFilter(process_status=["bob"]).to_dict() assert d == {"process_status": "bob"} @@ -90,9 +86,7 @@ class TestProcessInstanceReportFilter(BaseTest): with_super_admin_user: UserModel, ) -> None: """Docstring.""" - d = ProcessInstanceReportFilter( - process_status=["joe", "bob", "sue"] - ).to_dict() + d = ProcessInstanceReportFilter(process_status=["joe", "bob", "sue"]).to_dict() assert d == {"process_status": "joe,bob,sue"}