Sonalmahajan15/add grouping argument to golden test#6
Conversation
There was a problem hiding this comment.
PR Summary
This PR introduces a grouping argument to the golden test functionality, enabling tests to run in both grouped and ungrouped modes.
• tools/cmd/golden-test/main_test.go now tests WriteDiff with an explicit grouping flag ("true").
• .github/workflows/golden-test.yml adds a matrix strategy to toggle grouping; ensure the header for bot updates matches exactly.
• tools/cmd/golden-test/main.go propagates the grouping argument to both the NilAway binary call and the diff header text.
• Consider switching error logging from the standard log package to the custom logger.error format per guidelines.
3 file(s) reviewed, 1 comment(s)
Edit PR Review Bot Settings | Greptile
| issue_number: issueNumber | ||
| }); | ||
| const botComment = comments.data.find(comment => comment.user.login === 'github-actions[bot]' && comment.body.startsWith('## Golden Test')); | ||
| const botComment = comments.data.find(comment => comment.user.login === 'github-actions[bot]' && comment.body.startsWith('## Golden Test ${{ matrix.grouping }}')); |
There was a problem hiding this comment.
logic: Check that the header string produced by WriteDiff (e.g. '## Golden Test w/ grouping' or '## Golden Test w/o grouping') exactly matches the expectation in the github-script's botComment check. Any discrepancy may prevent updating the existing comment.
No description provided.