Skip to content

Commit

Permalink
Single file listing actually does return the content length
Browse files Browse the repository at this point in the history
  • Loading branch information
Jay Chia committed Sep 22, 2023
1 parent 4db517b commit dd0f408
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/integration/io/test_list_files_http.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@


def compare_http_result(daft_ls_result: list, fsspec_result: list):
daft_files = [(f["path"], f["type"].lower()) for f in daft_ls_result]
httpfs_files = [(f["name"], f["type"]) for f in fsspec_result]
daft_files = [(f["path"], f["type"].lower(), f["size"]) for f in daft_ls_result]
httpfs_files = [(f["name"], f["type"], f["size"]) for f in fsspec_result]
assert len(daft_files) == len(httpfs_files)
assert sorted(daft_files) == sorted(httpfs_files)

Expand Down Expand Up @@ -61,7 +61,7 @@ def test_gs_single_file_listing(nginx_http_url):
# fsspec_result = fs.ls(path, detail=True)

assert len(daft_ls_result) == 1
assert daft_ls_result[0] == {"path": path, "size": None, "type": "File"}
assert daft_ls_result[0] == {"path": path, "size": 0, "type": "File"}


@pytest.mark.integration()
Expand Down

0 comments on commit dd0f408

Please sign in to comment.