Skip to content

Integration Test: Reply Command Testing#10

Open
silouanwright wants to merge 12 commits into
mainfrom
integration-test-20250802-224635
Open

Integration Test: Reply Command Testing#10
silouanwright wants to merge 12 commits into
mainfrom
integration-test-20250802-224635

Conversation

@silouanwright
Copy link
Copy Markdown
Owner

Testing reply command functionality with both issue and review comments as documented in integration testing guide

- Add prompts command with 6 professional code review templates
- Implement CREG emoji system for structured feedback
- Add comprehensive regression tests for critical bug fixes
- Update documentation and help text for accuracy
- Remove non-existent integration-test-example.js
- Add integration test results log
- GitHub API requires line-specific comments to be part of a review
- Fix HTTP 422 'No subschema in oneOf matched' errors
- Create minimal review with COMMENT event for single comments
- Resolves integration testing failures for add command
…omments

- Update help text to explain add creates single-comment reviews
- Clarify comments appear in 'Files Changed' tab, not general conversation
- Direct users to 'gh pr comment' for general PR discussion
- Improves user understanding of GitHub API behavior
✅ MAJOR RESTRUCTURING COMPLETE:

- Convert add command: now creates general PR discussion comments (not reviews)
- Update review command: clarified for line-specific code review comments
- Remove add-review command: redundant with review command functionality
- Fix all unit tests: updated for new command interfaces
- Update integration tests: aligned with new command structure

CLEAR DISTINCTION ACHIEVED:
- 'gh comment add' = general discussion, threaded replies, approvals
- 'gh comment review' = line-specific code review, multiple comments + events

This resolves user confusion about comment types and GitHub API behavior.
Integration tests have minor issues but core functionality verified working.
- Fix review command PR auto-detection when PR number is explicitly provided
- Fix add command argument parsing with --message flags and PR numbers
- Move review comment validation before dry-run check to catch errors early
- Enhance review comment parsing to handle quoted messages and colon ranges
- Update error message format to match test expectations
- Support both start:end and start-end range formats in review comments

Fixes failing integration tests:
- comment_workflow.txtar
- suggestion_syntax.txtar
- error_scenarios.txtar

All enhanced integration tests now pass, unblocking development.
…nd dash range support

The review command now supports both start:end and start-end range formats,
but the help text only mentioned the dash format. Updated to clarify that
both formats are supported, with colon format being primary as shown in examples.
- Mark integration test failures as resolved with comprehensive details
- Reclassify remaining CI tasks as lower priority optional improvements
- Document successful integration testing methodology
- Update status to reflect development is no longer blocked
…compliance

- Updated 5 prompt files to include [SUGGEST: code] syntax references
- Fixes TestPromptContentQuality test failures that expected syntax mentions
- Added references in logical places within each prompt's content
- Maintains prompt quality while satisfying test requirements

Files updated:
- cmd/prompts/research/code-review-best-practices.md
- cmd/prompts/workflows/README.md
- cmd/prompts/workflows/self-review.md
- cmd/prompts/workflows/address-review.md
- cmd/prompts/workflows/pr-code-review.md

All tests now pass successfully.
…revent HTTP 422 errors

- GitHub API only supports message replies for issue comments, not review comments
- Review comments only support reactions for replies, messages fail with HTTP 422
- Changed default --type from 'review' to 'issue' to make message replies work by default
- Updated help text to clearly explain the GitHub API limitations
- Updated examples to show correct usage patterns

This fixes the critical issue where most reply attempts failed due to wrong default type.
- Updated CLAUDE.md to point to TASKS.md for current state
- Updated TASKS.md with completed work and remaining priorities
- Cleaned up documentation structure and cross-references
- Fixed HTTP 422 errors in review comment text replies
- Changed from incorrect endpoint with in_reply_to_id to proper /repos/{owner}/{repo}/pulls/comments/{comment_id}/replies
- Simplified payload to only include body (GitHub API handles threading automatically)
- Removed unnecessary original comment fetching and complex payload construction

This fixes the critical bug where text replies to review comments failed with HTTP 422.
The GitHub API for review comment replies uses a dedicated endpoint, not a new comment with reply metadata.
@silouanwright
Copy link
Copy Markdown
Owner Author

This is a general discussion comment for reply testing

Copy link
Copy Markdown
Owner Author

@silouanwright silouanwright left a comment

Choose a reason for hiding this comment

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

Code review for reply testing

Comment thread src/api.js
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Aug 3, 2025

📊 Benchmark Results

Performance comparison

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Aug 3, 2025

📊 Benchmark Results

Performance comparison

@silouanwright
Copy link
Copy Markdown
Owner Author

test message

2 similar comments
@silouanwright
Copy link
Copy Markdown
Owner Author

test message

@silouanwright
Copy link
Copy Markdown
Owner Author

test message

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.

1 participant