From 788ec8bcecdbe31941154a552163ce420fbd2c01 Mon Sep 17 00:00:00 2001 From: Yasuhisa Yoshida Date: Sun, 18 Feb 2024 00:55:33 +0900 Subject: [PATCH] Add test cases --- .../unit/adapters/algos/test_test_relationship.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/tests/unit/adapters/algos/test_test_relationship.py b/tests/unit/adapters/algos/test_test_relationship.py index 298c8af..469bf4f 100644 --- a/tests/unit/adapters/algos/test_test_relationship.py +++ b/tests/unit/adapters/algos/test_test_relationship.py @@ -142,6 +142,16 @@ class DummyManifestRel: nodes=["model.dbt_resto.table-r1", "model.dbt_resto.table-r2"] ), ), + "test.dbt_resto.relationships_table1_recursive": ManifestNode( + test_metadata=ManifestNodeTestMetaData( + kwargs={"column_name": "f1", "field": "f2", "to": "ref('table1')"} + ), + meta={}, + columns={}, + depends_on=ManifestNodeDependsOn( + nodes=["model.dbt_resto.table1"] + ), + ), } @@ -354,6 +364,11 @@ def test_get_compiled(self, manifest, expected): ], column_map=["f2", "f1"], ), + Ref( + name="relationships_table1_recursive", + table_map=["model.dbt_resto.table1", "model.dbt_resto.table1"], + column_map=["f2", "f1"], + ), ], ), (