The problem I’m having
I keep getting the following error when I try to run my custom dbt test:
19:38:44 Completed with 1 error, 0 partial successes, and 0 warnings:
19:38:44
19:38:44 Compilation Error in test at_least_one_row_mymodelname_ (models/summary/schema.yml)
'test_at_least_one_row' is undefined. This can happen when calling a macro that does not exist. Check for typos and/or install package dependencies with "dbt deps".
What I’ve already tried
I’ve tried changing the file name and test name.
schema.yml
models:
- name: mymodelname
tests:
- at_least_one_row:
severity: warn
##at_least_one_row.sql
{% test at_least_one_row(model) %}
select 1
from {{ model }}
limit 10
{% endtest %}
Any thoughts on what might be going on here?
I’m using dbt-core 1.9 in case that makes a difference.