From 2e18c2017a6012d2f557e57f724174b286a16774 Mon Sep 17 00:00:00 2001 From: Julian Stirling Date: Wed, 2 Jul 2025 09:39:33 +0000 Subject: [PATCH] Apply suggestions from code review of branch download-stitched-image Co-authored-by: Beth Probert --- src/openflexure_microscope_server/scan_directories.py | 2 +- tests/test_scan_directories.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/openflexure_microscope_server/scan_directories.py b/src/openflexure_microscope_server/scan_directories.py index 7aac9fc6..361abf40 100644 --- a/src/openflexure_microscope_server/scan_directories.py +++ b/src/openflexure_microscope_server/scan_directories.py @@ -73,7 +73,7 @@ class ScanDirectoryManager: def get_file_path_from( self, scan_name: str, filename: str, check_exists: bool = False ) -> Optional[str]: - """Return the file full path for the file within a scan directory + """Return the full file path for the file within a scan directory If check_exists is True then None will be returned if the file does not exist. diff --git a/tests/test_scan_directories.py b/tests/test_scan_directories.py index 3fb59760..d1a61f0b 100644 --- a/tests/test_scan_directories.py +++ b/tests/test_scan_directories.py @@ -356,7 +356,7 @@ def test_all_files(): all_files = scan_dir.all_files() # As standard for 8 layers there are 89 jpegs and 1 dzi file. - assert len(all_files) == 90 + assert len(set(all_files)) == 90 dzi_file = None # Check all files exist for file in all_files: