mirror of
https://github.com/FlipsideCrypto/stellar-models.git
synced 2026-02-06 13:56:45 +00:00
* 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>
53 lines
2.0 KiB
YAML
53 lines
2.0 KiB
YAML
version: 2
|
|
models:
|
|
- name: silver__operations
|
|
|
|
columns:
|
|
- name: ID
|
|
description: "{{ doc('id') }}"
|
|
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:
|
|
- NUMBER
|
|
- name: SOURCE_ACCOUNT
|
|
description: "{{ doc('source_account') }}"
|
|
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: TRANSACTION_ID
|
|
description: "{{ doc('transaction_id') }}"
|
|
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:
|
|
- NUMBER
|
|
- name: LEDGER_SEQUENCE
|
|
description: "{{ doc('ledger_sequence') }}"
|
|
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:
|
|
- NUMBER
|
|
- name: TYPE
|
|
description: "{{ doc('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:
|
|
- NUMBER
|
|
- name: TYPE_STRING
|
|
description: "{{ doc('type_string') }}"
|
|
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 |