Skip to content

Commit

Permalink
show divisor line in test report also in red
Browse files Browse the repository at this point in the history
  • Loading branch information
psousa50 committed Aug 31, 2022
1 parent 854d4b3 commit 7c11966
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion macros/output.sql
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,12 @@
{% set cells = [] %}
{% for col_name in agate_table.column_names %}
{% set col_index = loop.index0 %}
{% do cells.append(dbt_unit_testing.pad("", columns_info[col_index].max_length, c="-")) %}
{% set line = dbt_unit_testing.pad("", columns_info[col_index].max_length, c="-") %}
{% if columns_info[col_index].has_differences %}
{% do cells.append("{RED}" ~ line ~ "{RESET}") %}
{% else %}
{% do cells.append(line) %}
{% endif %}
{% endfor %}
{{ dbt_unit_testing.println("| " ~ cells | join(" | ") ~ " |")}}

Expand Down

0 comments on commit 7c11966

Please sign in to comment.