Skip to content

Commit 9d7618c

Browse files
committed
add back cache tests
1 parent 3adcd0e commit 9d7618c

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

tests/test_runs/test_run_functions.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1659,6 +1659,16 @@ def test_run_on_dataset_with_missing_labels_array(self):
16591659
# repeat, fold, row_id, 6 confidences, prediction and correct label
16601660
assert len(row) == 12
16611661

1662+
@pytest.mark.test_server()
1663+
def test_get_cached_run(self):
1664+
openml.config.set_root_cache_directory(self.static_cache_dir)
1665+
openml.runs.functions._get_cached_run(1)
1666+
1667+
def test_get_uncached_run(self):
1668+
openml.config.set_root_cache_directory(self.static_cache_dir)
1669+
with pytest.raises(openml.exceptions.OpenMLCacheException):
1670+
openml.runs.functions._get_cached_run(10)
1671+
16621672
@pytest.mark.sklearn()
16631673
@pytest.mark.test_server()
16641674
def test_run_flow_on_task_downloaded_flow(self):

0 commit comments

Comments
 (0)