From 98db22362ddbda8778524b7657254dbacc5bc2a4 Mon Sep 17 00:00:00 2001 From: Deepyaman Datta Date: Sun, 3 Mar 2024 22:44:33 -0700 Subject: [PATCH] test(datasets): check `ibis.TableDataset.exists()` Signed-off-by: Deepyaman Datta --- kedro-datasets/tests/ibis/test_table_dataset.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/kedro-datasets/tests/ibis/test_table_dataset.py b/kedro-datasets/tests/ibis/test_table_dataset.py index 11ed445bb..b8e47b487 100644 --- a/kedro-datasets/tests/ibis/test_table_dataset.py +++ b/kedro-datasets/tests/ibis/test_table_dataset.py @@ -35,3 +35,10 @@ def test_save_and_load(self, table_dataset, dummy_table): table_dataset.save(dummy_table) reloaded = table_dataset.load() assert_frame_equal(dummy_table.execute(), reloaded.execute()) + + def test_exists(self, table_dataset, dummy_table): + """Test `exists` method invocation for both existing and + nonexistent data set.""" + assert not table_dataset.exists() + table_dataset.save(dummy_table) + assert table_dataset.exists()