-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
TODO: Would be really nice to run SQLFluff, Black, Isort... in the CI as well. But SQLFluff requires a database connection and deps to work. TODO: Now that we test the loading of the DAGs, we should test running ours with a mock behind it.
- Loading branch information
Showing
5 changed files
with
68 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,5 +4,6 @@ | |
black | ||
pre-commit | ||
pytest | ||
pytest-subtests | ||
tox | ||
requests-mock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
from airflow.models import DagBag | ||
|
||
|
||
def test_dags_generic(subtests): | ||
dagbag = DagBag() | ||
for dag_id in dagbag.dag_ids: | ||
with subtests.test(msg="DAG generic checks", dag_id=dag_id): | ||
dag = dagbag.get_dag(dag_id=dag_id) | ||
assert dagbag.import_errors == {} | ||
assert dag is not None | ||
assert len(dag.tasks) >= 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters