fix(test): make the no-annotation control a valid workflow (main is red) - #353
Merged
Conversation
main is red. TestDescribeWorkflow_NoAnnotationEmitsNoComment fails with unexpected violations [MDL-WF05] for a plain jump and both PRs that produced it were green. #351 added the test with a fixture that is a lone JumpToActivity whose target does not exist, and asserted "no violations at all". #350 then added MDL-WF05, which reports exactly that dangling target. Neither CI run could see the other's change. The rule is right; the fixture was not. It now carries the jump's target as a real activity, so the workflow is valid and the assertion means what it says rather than "no rule has been written yet that notices this". Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
mainis currently red.TestDescribeWorkflow_NoAnnotationEmitsNoCommentfails:Both PRs were green
JumpToActivitywhose target"Review"does not exist, and it assertedlen(violations) == 0.jump tonaming no activity.Each CI run passed because neither branch contained the other's change. The failure only exists in the merge.
The rule is right; the fixture was not
no violations at allis only a meaningful assertion over input that should have none. Over an invalid fixture it quietly asserts something much weaker — "no rule has been written yet that notices this" — and that expires the moment someone writes one.The fixture now carries the jump's target as a real activity, so the workflow is valid and the assertion means what it says. No production code changes.
The general lesson, recorded in the symptom table
When a test asserts the absence of diagnostics, make the input something you would be happy to ship. Two green PRs can merge to red and neither PR's CI can detect it — the only protection is a fixture that doesn't depend on which rules exist today.
Found by running
make teston an unrelated docs branch cut from the mergedmain, which is an argument for doing exactly that after a batch of PRs lands.🤖 Generated with Claude Code