Skip to content

Commit

Permalink
Added test for unpivot all cols
Browse files Browse the repository at this point in the history
  • Loading branch information
edurdevic committed Dec 31, 2023
1 parent b1f0405 commit 804c7c9
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tests/unit/dx_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,14 @@ def test_sql_template_fails_for_incorrect_sql(spark):
assert no_search_term_error.value.args[0] == "No SQL statements were successfully executed."


def test_unpivot_all_columns(spark):
dx = DX(spark=spark)

df = dx.from_tables("*.*.tb_1").unpivot_all_columns().apply()

assert df.filter(col("column_name") == "id").count() >= 1


def test_unpivot_string_columns(spark):
dx = DX(spark=spark)

Expand Down

0 comments on commit 804c7c9

Please sign in to comment.