stellar-models/models/silver/silver__assets.yml
Mike Stepanovic 006e314b5e
Add testing strategy (#4)
* added testing strategy

* updated recency within tests, added workflows with different lookback vars

* changed daily lookback to 1

* modified workflows to include USE_VARS in the env config, modified tests to use modified_timestamp (instead of closed_at) as the recency filter

* fixed env variables (switched to vars from secrets)

---------

Co-authored-by: Mike Stepanovic <mike.stepanovic@flipsidecrypto.com>
Co-authored-by: Eric Laurello <eric.laurello@flipsidecrypto.com>
2025-02-13 13:30:50 -07:00

29 lines
1.0 KiB
YAML

version: 2
models:
- name: silver__assets
columns:
- name: ASSET_TYPE
description: "{{ doc('asset_type') }}"
tests:
- not_null:
where: modified_timestamp > current_date - {{ var('test_days_threshold', 3) }}
- dbt_expectations.expect_column_values_to_be_in_type_list:
column_type_list:
- VARCHAR
- name: ASSET_CODE
description: "{{ doc('asset_code') }}"
tests:
- not_null:
where: modified_timestamp > current_date - {{ var('test_days_threshold', 3) }}
- dbt_expectations.expect_column_values_to_be_in_type_list:
column_type_list:
- VARCHAR
- name: ASSET_ISSUER
description: "{{ doc('asset_issuer') }}"
tests:
- not_null:
where: modified_timestamp > current_date - {{ var('test_days_threshold', 3) }}
- dbt_expectations.expect_column_values_to_be_in_type_list:
column_type_list:
- VARCHAR