Skip to content

Commit 0139201

Browse files
prhaclaude
andcommitted
Fix partitioned asset check test to include partition in evaluation
The AssetCheckEvaluation class has a partition field that needs to be set when storing evaluation events for partitioned asset checks. This field is used by the storage layer to properly associate evaluations with their partitions, enabling partition-based filtering in the GraphQL API. Changes: - Added partition parameter to AssetCheckEvaluation in test events - This ensures evaluations are properly linked to their partitions - All partition filter tests now pass 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent c1d7a34 commit 0139201

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

python_modules/dagster-graphql/dagster_graphql_tests/graphql/test_asset_checks.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1601,6 +1601,7 @@ def test_partitioned_asset_check_executions_with_partition_filter(
16011601
passed=True,
16021602
severity=AssetCheckSeverity.WARN,
16031603
description="Check for January",
1604+
partition="2024-01",
16041605
),
16051606
)
16061607
)
@@ -1625,6 +1626,7 @@ def test_partitioned_asset_check_executions_with_partition_filter(
16251626
passed=True,
16261627
severity=AssetCheckSeverity.WARN,
16271628
description="Check for February",
1629+
partition="2024-02",
16281630
),
16291631
)
16301632
)
@@ -1643,6 +1645,7 @@ def test_partitioned_asset_check_executions_with_partition_filter(
16431645
executions = res.data["assetCheckExecutions"]
16441646
assert len(executions) == 1
16451647
assert executions[0]["runId"] == run_id_one
1648+
assert executions[0]["evaluation"] is not None
16461649
assert executions[0]["evaluation"]["description"] == "Check for January"
16471650

16481651
# Query with partition filter for "2024-02"
@@ -1659,6 +1662,7 @@ def test_partitioned_asset_check_executions_with_partition_filter(
16591662
executions = res.data["assetCheckExecutions"]
16601663
assert len(executions) == 1
16611664
assert executions[0]["runId"] == run_id_two
1665+
assert executions[0]["evaluation"] is not None
16621666
assert executions[0]["evaluation"]["description"] == "Check for February"
16631667

16641668
# Query without partition filter - should get both

0 commit comments

Comments
 (0)