1 write to Name
Microsoft.Extensions.DependencyModel (1)
Library.cs (1)
58
Name
= name;
61 references to Name
dotnet (1)
CommandFactory\CommandResolution\DepsJsonCommandResolver.cs (1)
119
runtimeLibrary.
Name
,
Microsoft.AspNetCore.Mvc.Testing (2)
WebApplicationFactory.cs (2)
488
.ToDictionary(r => r.
Name
, r => r, StringComparer.Ordinal);
502
if (runtimeProjectLibraries.TryGetValue(candidate.
Name
, out var runtimeLibrary))
Microsoft.DotNet.Cli.Utils (1)
FrameworkDependencyFile.cs (1)
34
.FirstOrDefault(l => "netstandard.library".Equals(l.
Name
, StringComparison.OrdinalIgnoreCase))
Microsoft.Extensions.DependencyModel (10)
CollectionExtensions.netcoreapp.cs (1)
15
return collection.ToDictionary(l => l.
Name
, StringComparer.OrdinalIgnoreCase);
CompilationLibrary.cs (1)
78
throw new InvalidOperationException(SR.Format(SR.LibraryLocationNotFound,
Name
));
DependencyContext.cs (3)
86
return StringComparer.OrdinalIgnoreCase.Equals(x?.
Name
, y?.
Name
);
91
return StringComparer.OrdinalIgnoreCase.GetHashCode(obj.
Name
);
DependencyContextWriter.cs (3)
139
WriteTargetLibrary(library.
Name
+ DependencyContextStrings.VersionSeparator + library.Version, library, jsonWriter);
170
WritePortableTargetLibrary(library.
Name
+ DependencyContextStrings.VersionSeparator + library.Version,
424
.GroupBy(library => library.
Name
+ DependencyContextStrings.VersionSeparator + library.Version);
Resolution\ReferenceAssemblyPathResolver.cs (1)
56
throw new InvalidOperationException(SR.Format(SR.ReferenceAssemblyNotFound, assembly, library.
Name
));
Resolution\ResolverUtils.cs (1)
15
path = Path.Combine(library.
Name
, library.Version);
Microsoft.ML.TestFrameworkCommon (1)
Utility\PathResolver.cs (1)
104
runtimeLib.
Name
.ToLowerInvariant(),
Microsoft.NET.Build.Tasks (10)
DependencyContextBuilder.cs (9)
353
var libraries = runtimeLibraries.ToDictionary(lib => lib.Library.
Name
, lib => lib);
361
dep.Dependents.Add(reference.Library.
Name
);
374
if (lib.Library.
Name
.Equals("xunit", StringComparison.OrdinalIgnoreCase) ||
375
lib.Library.
Name
.Equals("xunit.core", StringComparison.OrdinalIgnoreCase))
388
libraries.Remove(lib.Library.
Name
);
393
value.Dependents.Remove(lib.Library.
Name
);
501
var libraryNames = runtimeLibraries.Select(lib => lib.Library.
Name
).Concat(compilationLibraries.Select(lib => lib.
Name
)).ToHashSet();
509
library.Library.
Name
,
GenerateDepsFile.cs (1)
278
affectedLibs.Add(lib.
Name
);
Microsoft.NET.Build.Tasks.UnitTests (14)
GivenADependencyContextBuilder.cs (14)
199
dependencyContext.RuntimeLibraries[0].
Name
.Should().Be("simple.dependencies"); // This is the entrypoint
208
.Contain(c => c.
Name
== "System.NotConflicting" && c.Type == "referenceassembly");
213
.Contain(c => c.
Name
== "System.Collections.NonGeneric.Reference" && c.Type == "referenceassembly");
215
.Contain(c => c.
Name
== "System.Collections.NonGeneric.Reference.Reference" && c.Type == "referenceassembly");
313
dependencyContext.RuntimeLibraries.Should().Contain(x => x.
Name
.Equals("System.A"));
340
dependencyContext.RuntimeLibraries.Should().Contain(x => x.
Name
.Equals("System.A"));
341
dependencyContext.RuntimeLibraries.Should().Contain(x => x.
Name
.Equals("System.B"));
356
dependencyContext.RuntimeLibraries.Should().Contain(x => x.
Name
.Equals("System.B"));
372
dependencyContext.RuntimeLibraries.Should().Contain(x => x.
Name
.Equals("System.C"));
373
dependencyContext.RuntimeLibraries.Should().Contain(x => x.
Name
.Equals("System.B"));
389
dependencyContext.RuntimeLibraries.Should().Contain(x => x.
Name
.Equals("System.B"));
390
if (dependencyContext.RuntimeLibraries.Any(x => x.
Name
.Equals("System.A")))
392
dependencyContext.RuntimeLibraries.Should().NotContain(x => x.
Name
.Equals("System.C"));
396
dependencyContext.RuntimeLibraries.Should().Contain(x => x.
Name
.Equals("System.C"));
Microsoft.NET.Build.Tests (8)
GivenThatWeWantToBuildADesktopLibrary.cs (7)
128
dependencyContext.CompileLibraries.Any(l => l.
Name
.Equals("Library")).Should().BeTrue();
129
dependencyContext.RuntimeLibraries.Any(l => l.
Name
.Equals("Library")).Should().BeTrue();
133
dependencyContext.CompileLibraries.Any(l => l.
Name
.Equals("Nerdbank.GitVersioning")).Should().BeTrue();
134
dependencyContext.RuntimeLibraries.Any(l => l.
Name
.Equals("Nerdbank.GitVersioning")).Should().BeFalse();
165
dependencyContext.RuntimeLibraries.Any(l => l.
Name
.Equals("Nerdbank.GitVersioning")).Should().BeFalse();
169
dependencyContext.RuntimeLibraries.Any(l => l.
Name
.Equals("Nerdbank.GitVersioning")).Should().BeTrue();
192
dependencyContext.RuntimeLibraries.Any(l => l.
Name
.Equals("xunit.core")).Should().BeTrue();
GivenThatWeWantToBuildAnAppWithTransitiveNonSdkProjectRefs.cs (1)
80
var projectNames = dependencyContext.RuntimeLibraries.Select(library => library.
Name
).ToList();
Microsoft.NET.Publish.Tests (8)
GivenThatAPublishedDepsJsonShouldContainVersionInformation.cs (2)
172
var libuvRuntimeLibrary = dependencyContext.RuntimeLibraries.Single(l => l.
Name
== "Libuv");
181
var immutableRuntimeLibrary = dependencyContext.RuntimeLibraries.Single(l => l.
Name
== "System.Collections.Immutable");
GivenThatWeWantToPreserveCompilationContext.cs (4)
134
.FirstOrDefault(l => string.Equals(l.
Name
, "testlibrary", StringComparison.OrdinalIgnoreCase));
144
.FirstOrDefault(l => string.Equals(l.
Name
, "mscorlib", StringComparison.OrdinalIgnoreCase));
150
.FirstOrDefault(l => string.Equals(l.
Name
, "system.core", StringComparison.OrdinalIgnoreCase));
156
.FirstOrDefault(l => string.Equals(l.
Name
, "system.collections.reference", StringComparison.OrdinalIgnoreCase));
GivenThatWeWantToPublishAProjectWithAllFeatures.cs (2)
224
.FirstOrDefault(l => string.Equals(l.
Name
, name, StringComparison.OrdinalIgnoreCase));
237
.FirstOrDefault(l => string.Equals(l.
Name
, $"{name}.{locale}", StringComparison.OrdinalIgnoreCase));
Microsoft.NET.Sdk.Razor.Tests (4)
MvcBuildIntegrationTest21NetFx.cs (2)
112
var packageReference = dependencyContext.CompileLibraries.First(l => l.
Name
== "System.Runtime.CompilerServices.Unsafe");
115
var projectReference = dependencyContext.CompileLibraries.First(l => l.
Name
== TestProjectName);
MvcBuildIntegrationTestLegacy.cs (2)
119
var packageReference = dependencyContext.CompileLibraries.First(l => l.
Name
== "System.Runtime.CompilerServices.Unsafe");
122
var projectReference = dependencyContext.CompileLibraries.First(l => l.
Name
== TestProjectName);
Microsoft.NET.TestFramework (2)
Assertions\DependencyContextAssertions.cs (2)
91
packageLibrary.Path.Should().NotBeNullOrEmpty($"Every Library with Type='package' should have a Path, but {packageLibrary.
Name
} does not.");
92
packageLibrary.HashPath.Should().NotBeNullOrEmpty($"Every Library with Type='package' should have a HashPath, but {packageLibrary.
Name
} does not.");