From eb5aa3cf44cf09aed76fc809534aefbb824566dc Mon Sep 17 00:00:00 2001 From: Youssef Victor Date: Tue, 31 Mar 2026 17:11:25 +0200 Subject: [PATCH 1/3] Disallow new init-only APIs via Copilot instructions --- .github/copilot-instructions.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/copilot-instructions.md b/.github/copilot-instructions.md index 13a97dc515..ea0396324b 100644 --- a/.github/copilot-instructions.md +++ b/.github/copilot-instructions.md @@ -31,6 +31,12 @@ When making change to resource files, you MUST: - Add a corresponding entry in the resource file (`.resx`). - NEVER manually modify `*.xlf` files. Instead, build the project to automatically generate the corresponding `*.xlf` files. +## Public API guidelines + +- Public API for MSTest and Microsoft.Testing.Platform should **never** use `init` accessors. + - Exception: Existing APIs in Microsoft.Testing.Platform, because changing them right now is a breaking change. But we shouldn't introduce **new** APIs using init accessors. + - IMPORTANT: Make sure to apply this rule strictly both during PR review and when working on code changes. + ## Testing Guidelines - Tests for MTP and MSTest analyzers MUST use MSTest. From ea2ef3361b558c31d02dedff7f09b63286c73ad5 Mon Sep 17 00:00:00 2001 From: Youssef Victor Date: Tue, 31 Mar 2026 17:17:04 +0200 Subject: [PATCH 2/3] Update .github/copilot-instructions.md Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- .github/copilot-instructions.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/copilot-instructions.md b/.github/copilot-instructions.md index ea0396324b..3419548e53 100644 --- a/.github/copilot-instructions.md +++ b/.github/copilot-instructions.md @@ -35,7 +35,7 @@ When making change to resource files, you MUST: - Public API for MSTest and Microsoft.Testing.Platform should **never** use `init` accessors. - Exception: Existing APIs in Microsoft.Testing.Platform, because changing them right now is a breaking change. But we shouldn't introduce **new** APIs using init accessors. - - IMPORTANT: Make sure to apply this rule strictly both during PR review and when working on code changes. + - IMPORTANT: Make sure to apply this rule strictly both during PR review and when working on code changes. ## Testing Guidelines From b67d458fc36a9b961547cc71ce2808294b83e29d Mon Sep 17 00:00:00 2001 From: Youssef Victor Date: Tue, 31 Mar 2026 17:17:29 +0200 Subject: [PATCH 3/3] Update .github/copilot-instructions.md Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- .github/copilot-instructions.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/copilot-instructions.md b/.github/copilot-instructions.md index 3419548e53..6e506c1f3b 100644 --- a/.github/copilot-instructions.md +++ b/.github/copilot-instructions.md @@ -33,8 +33,8 @@ When making change to resource files, you MUST: ## Public API guidelines -- Public API for MSTest and Microsoft.Testing.Platform should **never** use `init` accessors. - - Exception: Existing APIs in Microsoft.Testing.Platform, because changing them right now is a breaking change. But we shouldn't introduce **new** APIs using init accessors. +- Public API for MSTest and Microsoft.Testing.Platform MUST NOT use `init` accessors. + - Exception: Existing APIs in Microsoft.Testing.Platform, because changing them right now would be a breaking change. However, we MUST NOT introduce **new** APIs using `init` accessors. - IMPORTANT: Make sure to apply this rule strictly both during PR review and when working on code changes. ## Testing Guidelines