Skip to content

Add test project for Microsoft.TestPlatform.Filter.Source source-only package#15649

Merged
Youssef1313 merged 4 commits intodev/ygerges/filter-source-pkgfrom
copilot/sub-pr-15638
Apr 8, 2026
Merged

Add test project for Microsoft.TestPlatform.Filter.Source source-only package#15649
Youssef1313 merged 4 commits intodev/ygerges/filter-source-pkgfrom
copilot/sub-pr-15638

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 8, 2026

Adds a test project that validates the Microsoft.TestPlatform.Filter.Source source-only package by compiling its source files directly (as end-users would via NuGet), without referencing the csproj.

Key design points

  • No project reference — source files are pulled in via <Compile Include="..." /> items, mirroring real consumer usage
  • IsFilterSourcePackage=true — prevents IS_VSTEST_REPO from being defined, so the internal sealed/[Embedded] code paths are exercised
  • Conflict isolation — a BeforeTargets="ResolveProjectReferences" target removes the FromP2P vstest project references added by Directory.Build.targets, which would otherwise cause CS0436 type conflicts between the inlined source and the compiled vstest assemblies

Tests covered

  • FilterHelperEscape, Unescape, invalid escape sequences, roundtrip
  • FilterExpressionWrapper — parse error detection, Evaluate with =, !=, ~, &, |, ValidForProperties, fast-filter construction
  • TestCaseFilterExpressionMatchTestCase, ValidForProperties, null guard on constructor, parse-error short-circuit

Copilot AI and others added 2 commits April 8, 2026 15:02
Agent-Logs-Url: https://github.com/microsoft/vstest/sessions/7eda9b9e-90f6-4186-950f-4990ee4d4330

Co-authored-by: Youssef1313 <31348972+Youssef1313@users.noreply.github.com>
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Apr 8, 2026

Just as a heads up, I was blocked by some firewall rules while working on your feedback. Expand below for details.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • pkvvsblobprodcus321.vsblob.vsassets.io
    • Triggering command: .dotnet/dotnet .dotnet/dotnet build test/Microsoft.TestPlatform.Filter.Source.UnitTests/Microsoft.TestPlatform.Filter.Source.UnitTests.csproj -f net9.0 --local commit.gpgsign de/node/bin/bash (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Copilot AI changed the title [WIP] Create source-only filter package Add test project for Microsoft.TestPlatform.Filter.Source source-only package Apr 8, 2026
Copilot AI requested a review from Youssef1313 April 8, 2026 15:41
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@copilot Revert the file mode change here.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Reverted in 1684c75.

Agent-Logs-Url: https://github.com/microsoft/vstest/sessions/f40a484c-cfb2-4282-8562-6ed492acf35b

Co-authored-by: Youssef1313 <31348972+Youssef1313@users.noreply.github.com>
Copilot AI requested a review from Youssef1313 April 8, 2026 21:18
@Youssef1313 Youssef1313 marked this pull request as ready for review April 8, 2026 21:31
@Youssef1313 Youssef1313 merged commit 6044993 into dev/ygerges/filter-source-pkg Apr 8, 2026
2 checks passed
@Youssef1313 Youssef1313 deleted the copilot/sub-pr-15638 branch April 8, 2026 21:31
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