Skip to content

Commit 1af83e0

Browse files
[release/9.0.1xx] Fix SB assembly version test (#44334)
1 parent dfbbe85 commit 1af83e0

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/SourceBuild/content/test/Microsoft.DotNet.SourceBuild.SmokeTests/SdkContentTests.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,11 @@ private void RemoveExcludedAssemblyVersionPaths(Dictionary<string, Version?> sbS
9898
{
9999
string assemblyPath = sbSdkFileArray[i];
100100
Version? sbVersion = sbSdkAssemblyVersions[assemblyPath];
101-
Version? msftVersion = msftSdkAssemblyVersions[assemblyPath];
101+
if (!msftSdkAssemblyVersions.TryGetValue(assemblyPath, out Version? msftVersion))
102+
{
103+
sbSdkAssemblyVersions.Remove(assemblyPath);
104+
continue;
105+
}
102106

103107
if (sbVersion is not null &&
104108
msftVersion is not null &&

0 commit comments

Comments
 (0)