Skip to content

PR Reviewer Agent

Shane Neuville edited this page Dec 8, 2025 · 2 revisions

The PR Reviewer agent is a specialized AI assistant for conducting thorough, constructive code reviews of .NET MAUI pull requests.

How to Use This Agent


What It Does

The PR Reviewer agent:

  • Checks out the PR branch and analyzes the code changes
  • Reviews test coverage - evaluates tests included in the PR
  • Forms independent opinion - analyzes WHY the fix works (or doesn't)
  • Identifies edge cases - finds scenarios that could break the fix
  • Runs UI tests - validates the fix works on device/simulator
  • Creates edge case tests - adds targeted tests for gaps identified during analysis
  • Validates API changes - checks PublicAPI.Unshipped.txt correctness
  • Writes comprehensive review - provides detailed feedback with test results

When to Use

Use the PR Reviewer agent when:

  • You want a comprehensive code review with hands-on testing validation
  • You need to verify a PR's fix actually works through UI testing
  • You want to validate test coverage and code quality
  • You want to identify and test edge cases not covered by the PR
  • You're reviewing someone else's PR with thorough analysis

What makes this different: This agent doesn't just read code - it checks out the PR, runs the tests, adds edge case tests if needed, and validates the fix works.

Example Prompts

review PR #12345
review PR #12345 focusing on test coverage
review PR #12345 and check if the API changes are correct
review this PR
does PR #12345 have adequate test coverage?
review PR #12345 and PR #12346 - which approach is better for fixing issue #12000?
review my changes before I submit a PR
review PR #12345 - I'm concerned about thread safety in the Android handler
review PR #12345 and verify PublicAPI.Unshipped.txt is correct

What to Expect

When you invoke the PR Reviewer, it will:

  1. Checkout PR branch - Fetches and switches to the PR code
  2. Review code - Analyzes changes for correctness, performance, security
  3. Review tests - Evaluates UI tests included in the PR
  4. Deep analysis - Forms independent opinion on whether fix is correct
  5. 🛑 Pause for approval - Presents analysis and waits for your confirmation
  6. Run tests - Executes UI tests on device/simulator if you approve
  7. Add edge case tests - Creates additional tests for gaps (if agreed)
  8. Write review - Creates Review_Feedback_Issue_XXXXX.md with comprehensive findings

The review output includes:

  • Recommendation: Approve / Request Changes / Comment
  • Code Analysis: WHY the fix works (or concerns about it)
  • Test Results: Which tests ran and what happened
  • Edge Cases: What scenarios were validated beyond the basic fix
  • Issues Found: Required fixes and recommended improvements

Tips for Best Results

Be Specific About Your Concerns

Instead of:

review PR #12345

Try:

review PR #12345 - I'm concerned about thread safety in the Android handler

Provide Context

review PR #12345 - this is a fix for a crash reported in issue #12000

Context helps the agent understand what to look for.

Ask Follow-up Questions

In your review of PR #12345, you mentioned potential memory leaks. Can you explain that concern in more detail?

The agent can elaborate on any point from its review.

Request Specific Checks

review PR #12345 and verify:
- PublicAPI.Unshipped.txt is correct
- All platforms are handled
- Error handling is comprehensive

What the PR Reviewer Does NOT Do

  • Write comprehensive test suites - For that, use UI Test Coding Agent
    • This agent CAN create targeted edge case tests during validation
    • But won't write full test infrastructure or debug test frameworks
  • Quick manual testing - For exploratory testing without deep analysis, use Sandbox Agent
    • This agent does thorough analysis before testing
    • Sandbox is better for "just try it out" scenarios

Common Use Cases

Before Submitting Your PR

review my changes before I submit a PR

Get feedback while you're still on your feature branch.


Second Opinion

I got review feedback saying this approach is wrong. Can you review PR #12345 and suggest alternatives?

Get a different perspective on a contentious issue.


Learning Best Practices

review PR #12345 and explain any MAUI-specific conventions I should know about

Learn repository patterns while getting your code reviewed.


Validation Checklist

review PR #12345 and create a checklist of items I should address before requesting human review

Get an actionable todo list.


Clone this wiki locally