Skip to content

docs: prohibit InternalsVisibleTo in .NET test guidance#804

Merged
SteveSandersonMS merged 2 commits intomainfrom
copilot/update-copilot-instructions-dotnet
Mar 12, 2026
Merged

docs: prohibit InternalsVisibleTo in .NET test guidance#804
SteveSandersonMS merged 2 commits intomainfrom
copilot/update-copilot-instructions-dotnet

Conversation

Copy link
Contributor

Copilot AI commented Mar 12, 2026

Copilot agents were occasionally adding InternalsVisibleTo to .NET project files when writing tests. This is undesirable — tests should only exercise public APIs.

Change

  • Added an explicit instruction to .github/copilot-instructions.md under the .NET developer workflow entry, stating that InternalsVisibleTo must never be added to any project file when writing tests.

Copilot AI and others added 2 commits March 12, 2026 15:34
Co-authored-by: stephentoub <2642209+stephentoub@users.noreply.github.com>
@stephentoub stephentoub marked this pull request as ready for review March 12, 2026 16:04
@stephentoub stephentoub requested a review from a team as a code owner March 12, 2026 16:04
Copilot AI review requested due to automatic review settings March 12, 2026 16:04
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the repository’s Copilot/agent guidance to prevent .NET tests from accessing internals via InternalsVisibleTo, reinforcing the repo’s intent that tests validate public API surface only.

Changes:

  • Add an explicit .NET testing note prohibiting InternalsVisibleTo in any project file.

You can also share your feedback on Copilot code review. Take the survey.

@SteveSandersonMS SteveSandersonMS added this pull request to the merge queue Mar 12, 2026
Merged via the queue into main with commit e1ea008 Mar 12, 2026
14 checks passed
@SteveSandersonMS SteveSandersonMS deleted the copilot/update-copilot-instructions-dotnet branch March 12, 2026 22:39
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.

4 participants