From 0b44cf9c0a2e4eb80f2c67e84db061e761cd72f2 Mon Sep 17 00:00:00 2001 From: Veronica Berglyd Olsen <1619840+vkbo@users.noreply.github.com> Date: Tue, 8 Nov 2022 22:29:54 +0100 Subject: [PATCH] Fix issues with variying file order in zip archive --- tests/test_core/test_core_storage.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/test_core/test_core_storage.py b/tests/test_core/test_core_storage.py index 7f986185..7545a870 100644 --- a/tests/test_core/test_core_storage.py +++ b/tests/test_core/test_core_storage.py @@ -320,12 +320,12 @@ def testCoreStorage_ZipIt(monkeypatch, mockGUI, fncPath, tmpPath, mockRnd): # Check content with ZipFile(zipFile, mode="r") as archive: names = archive.namelist() - assert names[0] == nwFiles.PROJ_FILE - assert names[1] == f"meta/{nwFiles.OPTS_FILE}" - assert names[2] == f"meta/{nwFiles.INDEX_FILE}" - assert names[3] == f"content/{C.hTitlePage}.nwd" - assert names[4] == f"content/{C.hChapterDoc}.nwd" - assert names[5] == f"content/{C.hSceneDoc}.nwd" + assert nwFiles.PROJ_FILE in names + assert f"meta/{nwFiles.OPTS_FILE}" in names + assert f"meta/{nwFiles.INDEX_FILE}" in names + assert f"content/{C.hTitlePage}.nwd" in names + assert f"content/{C.hChapterDoc}.nwd" in names + assert f"content/{C.hSceneDoc}.nwd" in names theProject.closeProject()