Commit f0e1f79
feat(bdd): [agent]/[no-ai] bracket annotations replacing @-style comment markers (#2678)
* feat(bdd)!: bracket comment-marker syntax to avoid cucumber tag confusion
Replace the @-prefixed step-marker comments (# @agent, # @no-ai, # @Soft)
with square-bracket markers (# [agent], # [no-ai], # [soft]) so per-step
comment annotations can no longer be mistaken for cucumber's native tag
syntax. Real Gherkin tags (@flow, @param:, scenario-level @no-ai/@Soft)
are unchanged, and $skill tokens still work on marker lines.
Clean break (the package is unreleased): the old syntax no longer routes,
but collectAnnotationFootguns now flags marker-only @-style comments with
a migration hint, surfaced as a new 'legacy-annotation' health kind in
the explore model and dashboard.
* feat(bdd-dashboard): regenerate dev fixture for bracket marker syntax
Regenerated from packages/bdd/example via `midscene-bdd dashboard` after
the comment markers moved to # [agent] / # [no-ai] / # [soft]; picks up
the shifted line numbers from the gherkin-tour explainer comments.
* refactor(bdd): derive marker regexes from one source and trim legacy-marker copy
* chore(bdd-dashboard): tighten legacy-annotation health description
* refactor(bdd): structured annotation footguns per simplify review
collectAnnotationFootguns now returns {kind, line, message} findings, so
the explore model maps health kinds directly instead of sniffing warning
prose (a copy-edit could silently reclassify findings) and stops
re-parsing uri:line out of the message. Legacy @-markers at the start of
a prose line ("# @agent check the logs") now get the migration hint —
they routed before the syntax change, and silence was the one migration
gap. Marker names and the skill-token grammar each derive from a single
source, and the audit reuses the comment normalization markerBody
already computed.
---------
Co-authored-by: ScriptedAlchemy <zack@module-federation.io>1 parent e6ff3a3 commit f0e1f79
27 files changed
Lines changed: 429 additions & 247 deletions
File tree
- apps/bdd-dashboard/src
- components
- fixtures
- model
- packages/bdd
- example
- features
- gherkin-tour
- step_definitions
- scripts
- src
- agents
- explore
- tests
- integration
- fixtures/features
- real-cucumber
- fixture-esm/features
- fixture/features
- unit-test
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | | - | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
44 | 49 | | |
45 | 50 | | |
46 | 51 | | |
47 | 52 | | |
48 | | - | |
| 53 | + | |
49 | 54 | | |
50 | 55 | | |
51 | 56 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
82 | 82 | | |
83 | 83 | | |
84 | 84 | | |
85 | | - | |
86 | | - | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
87 | 88 | | |
88 | 89 | | |
89 | 90 | | |
| |||
0 commit comments