Skip to content

Commit 033a3b8

Browse files
committed
more tests
1 parent ee7e3f5 commit 033a3b8

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

tests/test_load.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -684,6 +684,15 @@ def test_load_dataset_builder_fail():
684684
datasets.load_dataset_builder("blabla")
685685

686686

687+
def test_load_dataset_builder_with_filesystem(dataset_loading_script_dir, data_dir, mockfs):
688+
builder = datasets.load_dataset_builder(
689+
dataset_loading_script_dir, data_dir=data_dir, cache_dir="mock://", storage_options=mockfs.storage_options
690+
)
691+
assert builder.cache_dir.startswith("mock://")
692+
assert isinstance(builder._fs, type(mockfs))
693+
assert builder._fs.storage_options == mockfs.storage_options
694+
695+
687696
@pytest.mark.parametrize("keep_in_memory", [False, True])
688697
def test_load_dataset_local(dataset_loading_script_dir, data_dir, keep_in_memory, caplog):
689698
with assert_arrow_memory_increases() if keep_in_memory else assert_arrow_memory_doesnt_increase():

0 commit comments

Comments
 (0)