Skip to content

Commit

Permalink
Narrow scope of node_status test
Browse files Browse the repository at this point in the history
  • Loading branch information
aranke committed Oct 14, 2024
1 parent f8d7b7c commit e9e0a7d
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/functional/adapter/hooks/test_on_run_hooks.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import pytest

from dbt.artifacts.schemas.results import RunStatus
from dbt.contracts.graph.nodes import HookNode
from dbt.tests.util import get_artifact, run_dbt_and_capture


Expand Down Expand Up @@ -50,8 +51,10 @@ def test_results(self, project, log_counts, my_model_run_status):

assert [(result.node.unique_id, result.status) for result in results] == expected_results
assert [
(result.node.unique_id, result.node.node_info["node_status"]) for result in results
] == [(id, str(status)) for id, status in expected_results]
(result.node.unique_id, result.node.node_info["node_status"])
for result in results
if isinstance(result.node, HookNode)
] == [(id, str(status)) for id, status in expected_results if id.startswith("operation")]
assert log_counts in log_output
assert "4 project hooks, 1 view model" in log_output

Expand Down

0 comments on commit e9e0a7d

Please sign in to comment.