Skip to content
Merged
Show file tree
Hide file tree
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
4 changes: 4 additions & 0 deletions fsspec/asyn.py
Original file line number Diff line number Diff line change
Expand Up @@ -344,6 +344,10 @@ async def _rm(self, path, recursive=False, batch_size=None, **kwargs):
async def _cp_file(self, path1, path2, **kwargs):
raise NotImplementedError

async def _mv_file(self, path1, path2):
await self._cp_file(path1, path2)
await self._rm_file(path1)

async def _copy(
self,
path1,
Expand Down
34 changes: 19 additions & 15 deletions fsspec/implementations/tests/test_zip.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,21 +164,25 @@ def zip_file_fixture(tmp_path):
def _assert_all_except_context_dependent_variables(result, expected_result):
for path in expected_result.keys():
assert result[path]
result_without_date_time = result[path].copy()
result_without_date_time.pop("date_time")
result_without_date_time.pop("_raw_time")
result_without_date_time.pop("external_attr")
result_without_date_time.pop("create_system")
result_without_date_time.pop("_end_offset", None)
result_without_date_time.pop("header_offset", None)

expected_result_without_date_time = expected_result[path].copy()
expected_result_without_date_time.pop("date_time")
expected_result_without_date_time.pop("_raw_time")
expected_result_without_date_time.pop("external_attr")
expected_result_without_date_time.pop("create_system")
expected_result_without_date_time.pop("_end_offset", None)
expected_result_without_date_time.pop("header_offset", None)
fields = [
"orig_filename",
"filename",
"compress_type",
"comment",
"extra",
"CRC",
"compress_size",
"file_size",
"name",
"size",
"type",
]

result_without_date_time = {k: result[path][k] for k in fields}

expected_result_without_date_time = {
k: expected_result[path][k] for k in fields
}
assert result_without_date_time == expected_result_without_date_time


Expand Down
Loading