Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions tests/unit/synapseutils/unit_test_synapseutils_sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
import random
import tempfile
from io import StringIO
from pathlib import Path
from typing import Any, Dict
from unittest.mock import AsyncMock, MagicMock, Mock, call, create_autospec, patch

Expand Down Expand Up @@ -885,6 +886,7 @@ def test_sync_from_synapse_manifest_is_suppress(
mock_get_file_entity_provenance_dict: MagicMock,
mock_generate_manifest: MagicMock,
syn: Synapse,
tmp_path: Path,
) -> None:
"""
Verify manifest argument equal to "suppress" that pass in to syncFromSynapse, it won't create any manifest file.
Expand Down Expand Up @@ -966,7 +968,7 @@ async def mock_get_children(*args, **kwargs):
) as patch_activity_from_parent,
):
result = synapseutils.syncFromSynapse(
syn=syn, entity=project, path="./", manifest="suppress"
syn=syn, entity=project, path=str(tmp_path), manifest="suppress"
)
assert [file, file_2] == result
expected_get_children_agrs = [
Expand Down Expand Up @@ -1015,7 +1017,7 @@ async def mock_get_children(*args, **kwargs):
if_collision=method_flags.COLLISION_OVERWRITE_LOCAL,
limit_search=None,
download_file=True,
download_location="./",
download_location=str(tmp_path),
md5=None,
synapse_client=syn,
),
Expand All @@ -1026,7 +1028,7 @@ async def mock_get_children(*args, **kwargs):
if_collision=method_flags.COLLISION_OVERWRITE_LOCAL,
limit_search=None,
download_file=True,
download_location=f"./{FOLDER_NAME}",
download_location=os.path.join(str(tmp_path), FOLDER_NAME),
md5=None,
synapse_client=syn,
),
Expand Down
Loading