Support trailing commas and comments in .slnf files
- [x] Replace
net8.0with$(CurrentTargetFramework)in App.csproj and Lib.csproj - [x] Update .github/copilot-instructions.md to document using $(CurrentTargetFramework) for test projects
- [x] Verify all tests still pass (4/4 tests passed)
Original prompt
This section details on the original issue you should resolve
<issue_title>Revise
CreateFromFilteredSolutionFileimplementation for trailing comma (and allowing comments)</issue_title> <issue_description>The current implementation of this method doesn't seem to allow trailing commas (and comments).MSBuild supported trailing commas (and comments) of slnf files in https://github.com/dotnet/msbuild/pull/6346
https://github.com/dotnet/sdk/blob/f578225fe1fdd93db9efac273562b3709db9e8e9/src/Cli/dotnet/SlnFileFactory.cs#L92
@baronfel @rainersigwald Another discrepancy due to not having a unified implementation/helper for how to parse solutions and solution filters. Not specific to test command this time :) </issue_description>
Comments on the Issue (you are @copilot in this section)
- Fixes dotnet/sdk#51929
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.
@copilot please replace the two new net8.0 target frameworks you added with $(CurrentTargetFramework). Please update the copilot instructions to let future copilots know to always use $(CurrentTargetFramework) by default when creating new test projects.
Tested in codespaces with a slnf that had trailing commas and comments.
@copilot please replace the two new net8.0 target frameworks you added with
$(CurrentTargetFramework). Please update the copilot instructions to let future copilots know to always use `$(CurrentTarg...
Done in 5fac8cb. Replaced both instances of net8.0 with $(CurrentTargetFramework) and added the guidance to the copilot instructions file.