-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
Description
Hello!
- Vote on this issue by adding a 👍 reaction
- If you want to implement this feature, comment to let us know (we'll work with you on design, scheduling, etc.)
Issue details
Add DotNetTargetFramework option to allow tests to override the target framework specified in .csproj files.
Use Cases
- Testing SDK compatibility across multiple .NET versions without maintaining separate test projects
- CI matrix testing across frameworks (net6.0, net7.0, net8.0, etc.)
- Validating that a locally-built SDK works with different framework versions
Proposed API
test := NewPulumiTest(t,
"path/to/csharp/project",
opttest.DotNetTargetFramework("net7.0"),
)Implementation Notes
- Would modify
<TargetFramework>element in.csprojduring test setup - Requires corresponding .NET SDK to be installed on the test machine
- NuGet packages must be compatible with the specified framework
- Test projects should typically specify their framework in
.csproj
Priority
Low - test projects should typically specify their framework; framework testing is better handled via separate test projects or CI matrix
Affected area/feature
.NET/C# Testing