Skip to content

[main] Source code updates from dotnet/dotnet #50073

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 26 commits into from
Aug 12, 2025
Merged
Show file tree
Hide file tree
Changes from 14 commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
a811f78
Backflow from https://github.com/dotnet/dotnet / 8cb85e0 build 278022
dotnet-maestro[bot] Aug 6, 2025
d627ecb
Merge main into darc-main-3179108c-c6b8-45ea-ab29-d26b162530ec
dotnet-maestro[bot] Aug 6, 2025
dd307c8
Update dependencies from https://github.com/dotnet/dotnet build 278022
dotnet-maestro[bot] Aug 6, 2025
9da1999
Merge branch 'main' of https://github.com/dotnet/sdk into darc-main-3…
Aug 6, 2025
b2b323f
Merge branch 'main' into darc-main-3179108c-c6b8-45ea-ab29-d26b162530ec
tmat Aug 6, 2025
36ac5c4
Backflow from https://github.com/dotnet/dotnet / 30bc8f9 build 278224
dotnet-maestro[bot] Aug 7, 2025
063475c
Update dependencies from https://github.com/dotnet/dotnet build 278224
dotnet-maestro[bot] Aug 7, 2025
ff0d7ba
Merge branch 'main' of https://github.com/dotnet/sdk into darc-main-3…
Aug 7, 2025
b3b3c1f
Update editorconfig template
sbomer Aug 7, 2025
3308ce3
Make AssemblyInfo a set
sbomer Aug 7, 2025
289053b
Merge main into darc-main-3179108c-c6b8-45ea-ab29-d26b162530ec
dotnet-maestro[bot] Aug 8, 2025
fdd1fe2
Update dependencies from https://github.com/dotnet/dotnet build 278405
dotnet-maestro[bot] Aug 8, 2025
efae8b7
Merge branch 'main' of https://github.com/dotnet/sdk into darc-main-3…
Aug 8, 2025
3c4ec5f
Don't trim trailing space for expected editorconfig
akoeplinger Aug 8, 2025
73e8c09
Apply suggestion from @jjonescz
akoeplinger Aug 8, 2025
e3121e8
Use equivalence check in It_respects_opt_outs
akoeplinger Aug 8, 2025
43e4d6e
Fix Build_AddsApplicationPartAttributes
akoeplinger Aug 8, 2025
e52707b
Skip PublishingRegistersWrittenFilesForProperCleanup for now
akoeplinger Aug 8, 2025
fb9f1c0
Merge main into darc-main-3179108c-c6b8-45ea-ab29-d26b162530ec
dotnet-maestro[bot] Aug 9, 2025
69bd343
Update dependencies from https://github.com/dotnet/dotnet build 278512
dotnet-maestro[bot] Aug 9, 2025
954fdcd
Backflow from https://github.com/dotnet/dotnet / e9f665e build 278626
dotnet-maestro[bot] Aug 11, 2025
0547b6c
Merge main into darc-main-3179108c-c6b8-45ea-ab29-d26b162530ec
dotnet-maestro[bot] Aug 11, 2025
a99af9c
Update dependencies from https://github.com/dotnet/dotnet build 278626
dotnet-maestro[bot] Aug 11, 2025
6f3d7f8
Reapply reverted changes
akoeplinger Aug 11, 2025
ab51d7d
Skip unstable test case
Aug 12, 2025
c4e5eff
Update dependencies from https://github.com/dotnet/dotnet build 278647
dotnet-maestro[bot] Aug 12, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -78,11 +78,11 @@
<PackageVersion Include="Microsoft.Web.Xdt" Version="$(MicrosoftWebXdtPackageVersion)" />
<PackageVersion Include="Microsoft.Win32.SystemEvents" Version="$(MicrosoftWin32SystemEventsPackageVersion)" />
<PackageVersion Include="Microsoft.Windows.CsWin32" Version="$(MicrosoftWindowsCsWin32PackageVersion)" />
<PackageVersion Include="Microsoft.WixToolset.Bal.wixext" Version="$(MicrosoftWixToolsetVersion)" />
<PackageVersion Include="Microsoft.WixToolset.Dependency.wixext" Version="$(MicrosoftWixToolsetVersion)" />
<PackageVersion Include="Microsoft.WixToolset.Heat" Version="$(MicrosoftWixToolsetVersion)" />
<PackageVersion Include="Microsoft.WixToolset.Util.wixext" Version="$(MicrosoftWixToolsetVersion)" />
<PackageVersion Include="Microsoft.WixToolset.UI.wixext" Version="$(MicrosoftWixToolsetVersion)" />
<PackageVersion Include="Microsoft.WixToolset.Bal.wixext" Version="$(MicrosoftWixToolsetSdkVersion)" />
<PackageVersion Include="Microsoft.WixToolset.Dependency.wixext" Version="$(MicrosoftWixToolsetSdkVersion)" />
<PackageVersion Include="Microsoft.WixToolset.Heat" Version="$(MicrosoftWixToolsetSdkVersion)" />
<PackageVersion Include="Microsoft.WixToolset.Util.wixext" Version="$(MicrosoftWixToolsetSdkVersion)" />
<PackageVersion Include="Microsoft.WixToolset.UI.wixext" Version="$(MicrosoftWixToolsetSdkVersion)" />
<PackageVersion Include="MSBuild.StructuredLogger" Version="2.2.386" />
<PackageVersion Include="Moq" Version="$(MoqPackageVersion)" />
<PackageVersion Include="NETStandard.Library.NETFramework" Version="$(NETStandardLibraryNETFrameworkVersion)" />
Expand Down
290 changes: 145 additions & 145 deletions eng/Version.Details.props

Large diffs are not rendered by default.

550 changes: 275 additions & 275 deletions eng/Version.Details.xml

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions global.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"errorMessage": "The .NET SDK is not installed or is not configured correctly. Please run ./build to install the correct SDK version locally."
},
"tools": {
"dotnet": "10.0.100-preview.7.25367.101",
"dotnet": "10.0.100-preview.7.25372.107",
"runtimes": {
"dotnet": [
"$(MicrosoftNETCorePlatformsPackageVersion)"
Expand All @@ -21,8 +21,8 @@
}
},
"msbuild-sdks": {
"Microsoft.DotNet.Arcade.Sdk": "10.0.0-beta.25377.103",
"Microsoft.DotNet.Helix.Sdk": "10.0.0-beta.25377.103",
"Microsoft.DotNet.Arcade.Sdk": "10.0.0-beta.25407.105",
"Microsoft.DotNet.Helix.Sdk": "10.0.0-beta.25407.105",
"Microsoft.Build.NoTargets": "3.7.0",
"Microsoft.Build.Traversal": "3.4.0",
"Microsoft.WixToolset.Sdk": "5.0.2-dotnet.2737382"
Expand Down
5 changes: 0 additions & 5 deletions src/BuiltInTools/dotnet-watch/HotReload/CompilationHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@ internal sealed class CompilationHandler : IDisposable

private bool _isDisposed;

static CompilationHandler()
{
WatchHotReloadService.RequireCommit = true;
}

public CompilationHandler(IReporter reporter, ProcessRunner processRunner)
{
_reporter = reporter;
Expand Down
2 changes: 2 additions & 0 deletions src/Cli/dotnet/Commands/Run/CSharpCompilerCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,8 @@ private void PrepareAuxiliaryFiles(out string rspPath)
build_property.EnableSingleFileAnalyzer = true
build_property.EnableTrimAnalyzer = true
build_property.IncludeAllContentForSelfExtract =
build_property.VerifyReferenceTrimCompatibility =
build_property.VerifyReferenceAotCompatibility =
build_property.TargetFramework = net{TargetFrameworkVersion}
build_property.TargetFrameworkIdentifier = .NETCoreApp
build_property.TargetFrameworkVersion = v{TargetFrameworkVersion}
Expand Down
2 changes: 1 addition & 1 deletion src/Layout/pkg/windows/bundles/sdk/bundle.wixproj
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
<DefineConstants>$(DefineConstants);MinimumVSVersion=$(MinimumVSVersion)</DefineConstants>

<!-- PlatformToken is used to generate a generate a WiX variable name using a preprocessor variable so casing matters. -->
<DefineConstants>$(DefineConstants);PlatformToken=$(InstallerPlatform.ToUpper())</DefineConstants>
<DefineConstants>$(DefineConstants);PlatformToken=$(TargetArchitecture.ToUpper())</DefineConstants>

<!-- Source paths for packages to chain. -->
<DefineConstants>$(DefineConstants);FinalizerExeSourceFile=$(FinalizerExeSourceFile)</DefineConstants>
Expand Down
5 changes: 3 additions & 2 deletions src/Layout/redist/redist.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,9 @@
<ProjectReference Include="$(RepoRoot)template_feed\*\*.csproj" ReferenceOutputAssembly="false" SkipGetTargetFrameworkProperties="true" Private="false" />
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\finalizer\finalizer.csproj" Condition="'$(OS)' == 'Windows_NT'" ReferenceOutputAssembly="false" SkipGetTargetFrameworkProperties="true" Private="false" />
<ItemGroup Condition="'$(OS)' == 'Windows_NT'">
<ProjectReference Include="..\pkg\windows\bundles\sdk\bundle.wixproj" ReferenceOutputAssembly="false" SkipGetTargetFrameworkProperties="true" Condition="'$(MSBuildRestoreSessionId)' != ''" />
<ProjectReference Include="..\finalizer\finalizer.csproj" ReferenceOutputAssembly="false" SkipGetTargetFrameworkProperties="true" Private="false" />
</ItemGroup>

<!-- In .NET product build mode, explicitly build workloads in build pass 2.
Expand Down
5 changes: 3 additions & 2 deletions src/Workloads/VSInsertion/workloads.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -95,14 +95,15 @@
</ItemGroup>

<ItemGroup Condition="'$(BuildWorkloads)' == 'true'">
<!-- we use MicrosoftNETCoreAppRuntimePackageVersion for both runtime and emsdk packages since they're aligned in VMR builds -->
<PackageDownload Include="@(RuntimeWorkloadPacksToDownload)" Version="[$(MicrosoftNETCoreAppRuntimePackageVersion)]" />
<PackageDownload Include="@(EmsdkWorkloadPacksToDownload)" Version="[$(MicrosoftNETRuntimeEmscripten3156Cachewinx64Version)]" />
<PackageDownload Include="@(EmsdkWorkloadPacksToDownload)" Version="[$(MicrosoftNETCoreAppRuntimePackageVersion)]" />
</ItemGroup>

<Target Name="_CollectDownloadedWorkloadPacks">
<ItemGroup>
<DownloadedWorkloadPacks Include="$(NuGetPackageRoot)\%(RuntimeWorkloadPacksToDownload.Identity)\$(MicrosoftNETCoreAppRuntimePackageVersion)\*.nupkg" />
<DownloadedWorkloadPacks Include="$(NuGetPackageRoot)\%(EmsdkWorkloadPacksToDownload.Identity)\$(MicrosoftNETRuntimeEmscripten3156Cachewinx64Version)\*.nupkg" />
<DownloadedWorkloadPacks Include="$(NuGetPackageRoot)\%(EmsdkWorkloadPacksToDownload.Identity)\$(MicrosoftNETCoreAppRuntimePackageVersion)\*.nupkg" />
</ItemGroup>

<Copy SourceFiles="@(DownloadedWorkloadPacks)"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@

#nullable disable

using Microsoft.VisualBasic;

namespace Microsoft.NET.Build.Tests
{
public class GivenThatWeWantToControlGeneratedAssemblyInfo : SdkTest
Expand Down Expand Up @@ -50,19 +52,19 @@ public void It_respects_opt_outs(string attributeToOptOut)
.Should()
.Pass();

var expectedInfo = new SortedDictionary<string, string>
{
{ "AssemblyInformationalVersionAttribute", "1.2.3-beta" },
{ "AssemblyFileVersionAttribute", "4.5.6.7" },
{ "AssemblyVersionAttribute", "8.9.10.11" },
{ "AssemblyCompanyAttribute", "TestCompany" },
{ "AssemblyConfigurationAttribute", "Release" },
{ "AssemblyCopyrightAttribute", "TestCopyright" },
{ "AssemblyDescriptionAttribute", "TestDescription" },
{ "AssemblyProductAttribute", "TestProduct" },
{ "AssemblyTitleAttribute", "TestTitle" },
{ "AssemblyTrademarkAttribute", "TestTrademark" },
{ "NeutralResourcesLanguageAttribute", "fr" },
var expectedInfo = new HashSet<(string Key, string Value)>
{
("AssemblyInformationalVersionAttribute", "1.2.3-beta"),
("AssemblyFileVersionAttribute", "4.5.6.7"),
("AssemblyVersionAttribute", "8.9.10.11"),
("AssemblyCompanyAttribute", "TestCompany"),
("AssemblyConfigurationAttribute", "Release"),
("AssemblyCopyrightAttribute", "TestCopyright"),
("AssemblyDescriptionAttribute", "TestDescription"),
("AssemblyProductAttribute", "TestProduct"),
("AssemblyTitleAttribute", "TestTitle"),
("AssemblyTrademarkAttribute", "TestTrademark"),
("NeutralResourcesLanguageAttribute", "fr"),
};

if (attributeToOptOut == "All")
Expand All @@ -71,10 +73,10 @@ public void It_respects_opt_outs(string attributeToOptOut)
}
else
{
expectedInfo.Remove(attributeToOptOut);
expectedInfo.RemoveWhere(i => i.Key == attributeToOptOut);
}

expectedInfo.Add("TargetFrameworkAttribute", $".NETCoreApp,Version=v{ToolsetInfo.CurrentTargetFrameworkVersion}");
expectedInfo.Add(("TargetFrameworkAttribute", $".NETCoreApp,Version=v{ToolsetInfo.CurrentTargetFrameworkVersion}"));

var assemblyPath = Path.Combine(buildCommand.GetOutputDirectory(ToolsetInfo.CurrentTargetFramework, "Release").FullName, "HelloWorld.dll");
var actualInfo = AssemblyInfo.Get(assemblyPath);
Expand Down Expand Up @@ -258,9 +260,9 @@ public void It_respects_version_prefix(string targetFramework)
var assemblyPath = Path.Combine(buildCommand.GetOutputDirectory(targetFramework).FullName, "HelloWorld.dll");
var info = AssemblyInfo.Get(assemblyPath);

info["AssemblyVersionAttribute"].Should().Be("1.2.3.0");
info["AssemblyFileVersionAttribute"].Should().Be("1.2.3.0");
info["AssemblyInformationalVersionAttribute"].Should().Be("1.2.3");
info.Should().Contain(("AssemblyVersionAttribute", "1.2.3.0"));
info.Should().Contain(("AssemblyFileVersionAttribute", "1.2.3.0"));
info.Should().Contain(("AssemblyInformationalVersionAttribute", "1.2.3"));
}

[WindowsOnlyTheory]
Expand All @@ -285,7 +287,7 @@ public void It_respects_version_changes_on_incremental_build(string targetFramew
// Then the version of the built assembly shall match the provided VersionPrefix
var assemblyPath = Path.Combine(incrementalBuildCommand.GetOutputDirectory(targetFramework).FullName, "HelloWorld.dll");
var info = AssemblyInfo.Get(assemblyPath);
info["AssemblyVersionAttribute"].Should().Be("1.2.4.0");
info.Should().Contain(("AssemblyVersionAttribute", "1.2.4.0"));

BuildCommand BuildProject(string versionPrefix)
{
Expand All @@ -307,7 +309,7 @@ public void It_respects_custom_assembly_attribute_items_on_incremental_build()

var firstBuildCommand = BuildProject(buildNumber: "1");
var assemblyPath = Path.Combine(firstBuildCommand.GetOutputDirectory(targetFramework).FullName, "TestLibrary.dll");
AssemblyInfo.Get(assemblyPath)["AssemblyMetadataAttribute"].Should().Be("BuildNumber:1");
AssemblyInfo.Get(assemblyPath).Should().Contain(("AssemblyMetadataAttribute", "BuildNumber:1"));

var firstWriteTime = File.GetLastWriteTimeUtc(assemblyPath);

Expand All @@ -324,7 +326,7 @@ public void It_respects_custom_assembly_attribute_items_on_incremental_build()
File.GetLastWriteTimeUtc(assemblyPath).Should().NotBe(firstWriteTime);

// and the custom assembly should be generated with the updated value.
AssemblyInfo.Get(assemblyPath)["AssemblyMetadataAttribute"].Should().Be("BuildNumber:2");
AssemblyInfo.Get(assemblyPath).Should().Contain(("AssemblyMetadataAttribute", "BuildNumber:2"));

BuildCommand BuildProject(string buildNumber)
{
Expand Down Expand Up @@ -358,7 +360,7 @@ public void It_includes_internals_visible_to()

var assemblyPath = Path.Combine(buildCommand.GetOutputDirectory("netstandard2.0").FullName, "HelloWorld.dll");

AssemblyInfo.Get(assemblyPath)["InternalsVisibleToAttribute"].Should().Be("Tests");
AssemblyInfo.Get(assemblyPath).Should().Contain(("InternalsVisibleToAttribute", "Tests"));
}

[RequiresMSBuildVersionTheory("17.0.0.32901")]
Expand Down Expand Up @@ -552,7 +554,7 @@ public void It_respects_out_out_of_internals_visible_to()

var assemblyPath = Path.Combine(buildCommand.GetOutputDirectory("netstandard2.0").FullName, "HelloWorld.dll");

Assert.False(AssemblyInfo.Get(assemblyPath).ContainsKey("InternalsVisibleToAttribute"));
AssemblyInfo.Get(assemblyPath).Should().NotContain(i => i.Key == "InternalsVisibleToAttribute");
}

[Fact]
Expand All @@ -578,7 +580,7 @@ public void It_includes_internals_visible_to_with_key()

var assemblyPath = Path.Combine(buildCommand.GetOutputDirectory("netstandard2.0").FullName, "HelloWorld.dll");

AssemblyInfo.Get(assemblyPath)["InternalsVisibleToAttribute"].Should().Be("Tests, PublicKey=00240000048000009400000006020000002400005253413100040000010001001d3e6bbb36e11ea61ceff6e1022b23dd779fc6230838db2d25a2c7c8433b3fcf86b16c25b281fc3db1027c0675395e7d0548e6add88b6a811962bf958101fa9e243b1618313bee11f5e3b3fefda7b1d1226311b6cc2d07e87ff893ba6890b20082df34a0aac14b605b8be055e81081a626f8c69e9ed4bbaa4eae9f94a35accd2");
AssemblyInfo.Get(assemblyPath).Should().Contain(("InternalsVisibleToAttribute", "Tests, PublicKey=00240000048000009400000006020000002400005253413100040000010001001d3e6bbb36e11ea61ceff6e1022b23dd779fc6230838db2d25a2c7c8433b3fcf86b16c25b281fc3db1027c0675395e7d0548e6add88b6a811962bf958101fa9e243b1618313bee11f5e3b3fefda7b1d1226311b6cc2d07e87ff893ba6890b20082df34a0aac14b605b8be055e81081a626f8c69e9ed4bbaa4eae9f94a35accd2"));
}

[Fact]
Expand All @@ -605,7 +607,7 @@ public void It_includes_internals_visible_to_with_project_publickey()

var assemblyPath = Path.Combine(buildCommand.GetOutputDirectory("netstandard2.0").FullName, "HelloWorld.dll");

AssemblyInfo.Get(assemblyPath)["InternalsVisibleToAttribute"].Should().Be("Tests, PublicKey=00240000048000009400000006020000002400005253413100040000010001001d3e6bbb36e11ea61ceff6e1022b23dd779fc6230838db2d25a2c7c8433b3fcf86b16c25b281fc3db1027c0675395e7d0548e6add88b6a811962bf958101fa9e243b1618313bee11f5e3b3fefda7b1d1226311b6cc2d07e87ff893ba6890b20082df34a0aac14b605b8be055e81081a626f8c69e9ed4bbaa4eae9f94a35accd2");
AssemblyInfo.Get(assemblyPath).Should().Contain(("InternalsVisibleToAttribute", "Tests, PublicKey=00240000048000009400000006020000002400005253413100040000010001001d3e6bbb36e11ea61ceff6e1022b23dd779fc6230838db2d25a2c7c8433b3fcf86b16c25b281fc3db1027c0675395e7d0548e6add88b6a811962bf958101fa9e243b1618313bee11f5e3b3fefda7b1d1226311b6cc2d07e87ff893ba6890b20082df34a0aac14b605b8be055e81081a626f8c69e9ed4bbaa4eae9f94a35accd2"));
}

[Fact]
Expand All @@ -631,11 +633,11 @@ public void It_includes_assembly_metadata()

var assemblyPath = Path.Combine(buildCommand.GetOutputDirectory("netstandard2.0").FullName, "HelloWorld.dll");

AssemblyInfo.Get(assemblyPath)["AssemblyMetadataAttribute"].Should().Be("MetadataKey:MetadataValue");
AssemblyInfo.Get(assemblyPath).Should().Contain(("AssemblyMetadataAttribute", "MetadataKey:MetadataValue"));
}

[Fact]
public void It_respects_out_out_of_assembly_metadata()
public void It_respects_opt_out_of_assembly_metadata()
{
var testAsset = _testAssetsManager
.CopyTestAsset("HelloWorld")
Expand All @@ -659,7 +661,7 @@ public void It_respects_out_out_of_assembly_metadata()

var assemblyPath = Path.Combine(buildCommand.GetOutputDirectory("netstandard2.0").FullName, "HelloWorld.dll");

Assert.False(AssemblyInfo.Get(assemblyPath).ContainsKey("AssemblyMetadataAttribute"));
AssemblyInfo.Get(assemblyPath).Should().NotContain(i => i.Key == "AssemblyMetadataAttribute");
}

[Theory]
Expand Down Expand Up @@ -699,11 +701,11 @@ public void GenerateUserSecrets(bool referenceAspNetCore, bool referenceExtensio

if (shouldHaveAttribute)
{
AssemblyInfo.Get(assemblyPath)["UserSecretsIdAttribute"].Should().Be("SecretsIdValue");
AssemblyInfo.Get(assemblyPath).Should().Contain(("UserSecretsIdAttribute", "SecretsIdValue"));
}
else
{
AssemblyInfo.Get(assemblyPath).Should().NotContainKey("SecretsIdValue");
AssemblyInfo.Get(assemblyPath).Should().NotContain(i => i.Key == "SecretsIdValue");
}
}

Expand Down Expand Up @@ -743,7 +745,7 @@ public void GenerateUserSecretsForTestProject()

var assemblyPath = Path.Combine(buildCommand.GetOutputDirectory(testTestProject.TargetFrameworks).FullName, testTestProject.Name + ".dll");

AssemblyInfo.Get(assemblyPath)["UserSecretsIdAttribute"].Should().Be("SecretsIdValue");
AssemblyInfo.Get(assemblyPath).Should().Contain(("UserSecretsIdAttribute", "SecretsIdValue"));
}

[Theory]
Expand Down Expand Up @@ -775,7 +777,7 @@ public void It_includes_repository_url(bool privateRepo)

var assemblyPath = Path.Combine(buildCommand.GetOutputDirectory(testProject.TargetFrameworks).FullName, testProject.Name + ".dll");

AssemblyInfo.Get(assemblyPath)["AssemblyMetadataAttribute"].Should().Be("RepositoryUrl:" + fakeUrl);
AssemblyInfo.Get(assemblyPath).Should().Contain(("AssemblyMetadataAttribute", "RepositoryUrl:" + fakeUrl));
}

[Theory]
Expand Down Expand Up @@ -804,11 +806,11 @@ public void It_does_not_write_to_undefined_assembly_metadata_attribute(string ta

if (containsAttribute)
{
AssemblyInfo.Get(assemblyPath)["AssemblyMetadataAttribute"].Should().Be("RepositoryUrl:" + fakeUrl);
AssemblyInfo.Get(assemblyPath).Should().Contain(("AssemblyMetadataAttribute", "RepositoryUrl:" + fakeUrl));
}
else
{
AssemblyInfo.Get(assemblyPath).ContainsKey("AssemblyMetadataAttribute").Should().Be(false);
AssemblyInfo.Get(assemblyPath).Should().NotContain(i => i.Key == "AssemblyMetadataAttribute");
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,16 +41,16 @@ public void Nuget_reference_compat(string referencerTarget, string testDescripti

// Process all dependencies in parallel
Parallel.ForEach(
rawDependencyTargets.Split(',', ';', ' ').Where(s => !string.IsNullOrWhiteSpace(s)),
rawDependencyTargets.Split(',', ';', ' ').Where(s => !string.IsNullOrWhiteSpace(s)),
new ParallelOptions { MaxDegreeOfParallelism = Environment.ProcessorCount },
dependencyTarget =>
dependencyTarget =>
{
// Create the dependency project and package
TestProject dependencyProject = GetTestProject(
ConstantStringValues.DependencyDirectoryNamePrefix + dependencyTarget.Replace('.', '_'),
dependencyTarget,
ConstantStringValues.DependencyDirectoryNamePrefix + dependencyTarget.Replace('.', '_'),
dependencyTarget,
true);

TestPackageReference dependencyPackageReference = new(
dependencyProject.Name,
"1.0.0",
Expand Down Expand Up @@ -208,7 +208,7 @@ public void It_chooses_lowest_netfx_in_default_atf()
buildCommand.Execute().Should().Pass();

var referencedDll = buildCommand.GetOutputDirectory().File("net462_net472_pkg.dll").FullName;
var referencedTargetFramework = AssemblyInfo.Get(referencedDll)["TargetFrameworkAttribute"];
var referencedTargetFramework = AssemblyInfo.Get(referencedDll).Where(i => i.Key == "TargetFrameworkAttribute").Single().Value;
referencedTargetFramework.Should().Be(".NETFramework,Version=v4.6.2");
}

Expand Down
Loading
Loading