diff --git a/qfieldsync/tests/test_export.py b/qfieldsync/tests/test_export.py index 0552c002..e6c7ac6f 100644 --- a/qfieldsync/tests/test_export.py +++ b/qfieldsync/tests/test_export.py @@ -61,13 +61,15 @@ def test_copy(self): self.assertIn('spatialite.db', files) dcim_folder = os.path.join(export_folder, "DCIM") - self.assertIn('qfield_photo_1.jpg', dcim_folder) - self.assertIn('qfield_photo_2.jpg', dcim_folder) - self.assertIn('qfield_photo_3.jpg', dcim_folder) + dcim_files = os.listdir(dcim_folder) + self.assertIn('qfield-photo_1.jpg', dcim_files) + self.assertIn('qfield-photo_2.jpg', dcim_files) + self.assertIn('qfield-photo_3.jpg', dcim_files) dcim_subfolder = os.path.join(dcim_folder, "subfolder") - self.assertIn('qfield_photo_sub_1.jpg', dcim_subfolder) - self.assertIn('qfield_photo_sub_2.jpg', dcim_subfolder) - self.assertIn('qfield_photo_sub_3.jpg', dcim_subfolder) + dcim_subfiles = os.listdir(dcim_subfolder) + self.assertIn('qfield-photo_sub_1.jpg', dcim_subfiles) + self.assertIn('qfield-photo_sub_2.jpg', dcim_subfiles) + self.assertIn('qfield-photo_sub_3.jpg', dcim_subfiles) shutil.rmtree(export_folder) shutil.rmtree(source_folder) @@ -75,4 +77,4 @@ def test_copy(self): def load_project(self, path): project = QgsProject.instance() self.assertTrue(project.read(path)) - return project + return project \ No newline at end of file