8000 Sonalmahajan15/add grouping argument to golden test by lizard-boy · Pull Request #6 · greptileai/nilaway · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Sonalmahajan15/add grouping argument to golden test #6

New issue 8000

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

lizard-boy
Copy link
Collaborator

No description provided.

Copy link
@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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

@@ -61,7 +69,7 @@ jobs:
repo: repo,
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 }}'));
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0