mirror of
https://github.com/FlipsideCrypto/aleo-models.git
synced 2026-02-06 14:06:43 +00:00
Revert "removing recency test that frequently fails"
This reverts commit 1651e0e8e6.
This commit is contained in:
parent
1651e0e8e6
commit
6eff123a9d
@ -0,0 +1,27 @@
|
||||
{{ config (
|
||||
materialized = 'view',
|
||||
tags = ['recent_test']
|
||||
) }}
|
||||
|
||||
WITH last_3_days AS (
|
||||
|
||||
SELECT
|
||||
block_date
|
||||
FROM
|
||||
{{ ref("_max_block_by_date") }}
|
||||
qualify ROW_NUMBER() over (
|
||||
ORDER BY
|
||||
block_date DESC
|
||||
) = 3
|
||||
)
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
{{ ref('defi__fact_liquidity_pool_actions') }}
|
||||
WHERE
|
||||
block_timestamp :: DATE >= (
|
||||
SELECT
|
||||
block_date
|
||||
FROM
|
||||
last_3_days
|
||||
)
|
||||
@ -0,0 +1,24 @@
|
||||
version: 2
|
||||
|
||||
models:
|
||||
- name: test_defi__liquidity_actions_recent
|
||||
description: Records of all liquidity pool actions on Aleo.
|
||||
tests:
|
||||
- dbt_utils.unique_combination_of_columns:
|
||||
combination_of_columns:
|
||||
- TX_ID
|
||||
- LIQUIDITY_POOL_PROTOCOL
|
||||
- LIQUIDITY_PROVIDER
|
||||
- TOKEN1_ID
|
||||
- TOKEN2_ID
|
||||
columns:
|
||||
- name: BLOCK_TIMESTAMP
|
||||
tests:
|
||||
- not_null
|
||||
- dbt_expectations.expect_row_values_to_have_recent_data:
|
||||
datepart: hour
|
||||
interval: 3
|
||||
|
||||
- name: BLOCK_ID
|
||||
tests:
|
||||
- not_null
|
||||
Loading…
Reference in New Issue
Block a user