Add embedded action step expansion to --dag-mermaid output#156
Merged
Conversation
- Add DagRenderer interface and DagRendererBase struct in dag.go to share common functionality between ASCII and Mermaid renderers - Refactor dag_ascii.go and dag_mermaid.go to use embedded DagRendererBase, eliminating duplicate code - Add embedded job step expansion to Mermaid output, matching the existing behavior in ASCII output - Add tests for embedded action rendering in dag_mermaid_test.go - Add golden test files for embedded_action and embedded_expanded Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This comment has been minimized.
This comment has been minimized.
Code Metrics Report
Details | | main (e50a772) | #156 (847d5b5) | +/- |
|---------------------|----------------|----------------|-------|
+ | Coverage | 55.0% | 55.1% | +0.1% |
| Files | 64 | 65 | +1 |
| Lines | 6518 | 6536 | +18 |
+ | Covered | 3590 | 3607 | +17 |
- | Code to Test Ratio | 1:1.0 | 1:1.0 | -0.1 |
| Code | 12808 | 12846 | +38 |
| Test | 13180 | 13180 | 0 |
- | Test Execution Time | 6s | 12s | +6s |Code coverage of files in pull request scope (89.7% → 89.9%)
Reported by octocov |
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.
Summary
--dag-mermaidoutput, matching the existing behavior in--dag-asciiDagRendererinterface andDagRendererBasestruct indag.goto share common functionality between ASCII and Mermaid renderersdag_ascii.goanddag_mermaid.goto eliminate duplicate codeChanges
DagRendererinterfaceDagRendererBasestruct withGetEvaluatedVars,ExpandPath,ResolvePathmethodsLoadEmbeddedJobfunctionDagRendererBase, remove duplicate methodsDagRendererBase, add embedded step expansionTest plan
go test -run "DagMermaid"- All Mermaid renderer tests passgo test -run "DagAscii"- All ASCII renderer tests passgo test ./...- All tests pass🤖 Generated with Claude Code