@@ -448,7 +448,7 @@ test_wrong_attestation_type if {
448448test_all_image_processed if {
449449 # regal ignore:line-length
450450 digests_processed := {" image" : {" digests" : [" sha256:4e388ab32b10dc8dbc7e28144f552830adc74787c1e2c0824032078a79f227fb" ]}}
451- pipeline_run := lib_test.att_mock_helper_ref (lib.task_test_image_result_name , digests_processed, " success_23" , _bundle)
451+ pipeline_run := lib_test.att_mock_helper_ref (" IMAGES_PROCESSED " , digests_processed, " success_23" , _bundle)
452452 attestations := [
453453 pipeline_run,
454454 lib_test.att_mock_helper_ref (lib.task_test_result_name, {" result" : " SUCCESS" }, " errored_1" , _bundle),
@@ -460,7 +460,7 @@ test_all_image_processed if {
460460
461461test_all_images_not_processed if {
462462 digests_processed := {" image" : {" digests" : [" sha256:wrongDigest" ]}}
463- pipeline_run := lib_test.att_mock_helper_ref (lib.task_test_image_result_name , digests_processed, " success_23" , _bundle)
463+ pipeline_run := lib_test.att_mock_helper_ref (" IMAGES_PROCESSED " , digests_processed, " success_23" , _bundle)
464464
465465 attestations := [
466466 pipeline_run,
@@ -476,6 +476,25 @@ test_all_images_not_processed if {
476476 with input.image.ref as _bundle
477477}
478478
479+ test_all_images_matrix_tasks if {
480+ # Matrix task scenario: same task name and bundle but different digests processed by each instance
481+ digests_task1 := {" image" : {" digests" : [" sha256:4e388ab32b10dc8dbc7e28144f552830adc74787c1e2c0824032078a79f227fb" ]}}
482+ digests_task2 := {" image" : {" digests" : [" sha256:otherDigest" ]}}
483+
484+ matrix_task1 := lib_test.att_mock_helper_ref (" IMAGES_PROCESSED" , digests_task1, " matrix-test" , _bundle)
485+ matrix_task2 := lib_test.att_mock_helper_ref (" IMAGES_PROCESSED" , digests_task2, " matrix-test" , _bundle)
486+
487+ attestations := [
488+ matrix_task1,
489+ matrix_task2,
490+ lib_test.att_mock_helper_ref (lib.task_test_result_name, {" result" : " SUCCESS" }, " matrix-test" , _bundle),
491+ ]
492+
493+ # Should pass because the grouped results combine digests from both matrix task instances
494+ lib.assert_empty (test.deny) with input.attestations as attestations
495+ with input.image.ref as _bundle
496+ }
497+
479498test_rule_data_provided if {
480499 d := {
481500 " supported_tests_results" : [
0 commit comments