3 writes to DependencyTable
Microsoft.Build.Utilities.Core (3)
TrackedDependencies\CanonicalTrackedOutputFiles.cs (3)
85
DependencyTable
= new Dictionary<string, Dictionary<string, DateTime>>(StringComparer.OrdinalIgnoreCase);
138
DependencyTable
= (Dictionary<string, Dictionary<string, DateTime>>)cachedEntry.DependencyTable;
250
DependencyTable
= new Dictionary<string, Dictionary<string, DateTime>>(StringComparer.OrdinalIgnoreCase);
43 references to DependencyTable
Microsoft.Build.Utilities.Core (20)
TrackedDependencies\CanonicalTrackedInputFiles.cs (1)
476
if (_outputs.
DependencyTable
.TryGetValue(sourceFullPath, out Dictionary<string, DateTime> outputFiles))
TrackedDependencies\CanonicalTrackedOutputFiles.cs (19)
185
if (!
DependencyTable
.TryGetValue(tlogEntry, out Dictionary<string, DateTime> dependencies))
188
DependencyTable
.Add(tlogEntry, dependencies);
255
DependencyTableCache.DependencyTable[tLogRootingMarker] = new DependencyTableCacheEntry(_tlogFiles,
DependencyTable
);
280
if (
DependencyTable
.TryGetValue(currentRoot, out Dictionary<string, DateTime> currentOutputs))
285
foreach (KeyValuePair<string, Dictionary<string, DateTime>> root in
DependencyTable
)
305
DependencyTable
.Remove(removedMarker);
319
if (
DependencyTable
.TryGetValue(sourceRoot, out var outputPaths))
323
if (
DependencyTable
[sourceRoot].Count == 0)
325
DependencyTable
.Remove(sourceRoot);
423
foreach (string tableEntryRoot in
DependencyTable
.Keys)
478
if (
DependencyTable
.TryGetValue(sourceKey, out Dictionary<string, DateTime> dependencies))
537
if (!
DependencyTable
.TryGetValue(sourceKey, out Dictionary<string, DateTime> dependencies))
540
DependencyTable
.Add(sourceKey, dependencies);
597
foreach (KeyValuePair<string, Dictionary<string, DateTime>> kvp in
DependencyTable
)
646
DependencyTable
.Remove(rootMarkerToRemove);
651
DependencyTable
.Remove(FileUtilities.NormalizePath(sourceItem.ItemSpec));
685
if (
DependencyTable
.TryGetValue(rootingMarker, out Dictionary<string, DateTime> dependencies))
753
if (
DependencyTable
.TryGetValue(rootingMarker, out Dictionary<string, DateTime> dependencies))
786
DependencyTable
[rootingMarker] = dependenciesWithoutMissingFiles;
Microsoft.Build.Utilities.UnitTests (23)
TrackedDependencies\TrackedDependenciesTests.cs (23)
552
Assert.Empty(d.
DependencyTable
); // "DependencyTable should be empty."
569
Assert.Empty(d.
DependencyTable
); // "DependencyTable should be empty."
586
Assert.Empty(d.
DependencyTable
); // "DependencyTable should be empty."
603
Assert.Empty(d.
DependencyTable
); // "DependencyTable should be empty."
620
Assert.Empty(d.
DependencyTable
); // "DependencyTable should be empty."
818
Assert.Single(writtenOutputs.
DependencyTable
[Path.GetFullPath(Path.Combine("TestFiles", "one.cpp"))]);
821
Assert.Equal(2, writtenOutputs.
DependencyTable
[Path.GetFullPath(Path.Combine("TestFiles", "two.cpp"))].Count);
867
Assert.False(writtenOutputs.
DependencyTable
[Path.GetFullPath(Path.Combine("TestFiles", "one.cpp"))].ContainsKey(Path.GetFullPath(Path.Combine("TestFiles", "one3.obj"))));
938
Assert.False(writtenOutputs.
DependencyTable
[rootingMarker].ContainsKey(Path.GetFullPath(Path.Combine("TestFiles", "one3.obj"))));
999
Assert.True(outputs.
DependencyTable
.ContainsKey(rootingMarker1));
1000
Assert.True(outputs.
DependencyTable
.ContainsKey(rootingMarker2));
1001
Assert.True(outputs.
DependencyTable
.ContainsKey(rootingMarker3));
1005
Assert.True(outputs.
DependencyTable
.ContainsKey(rootingMarker1));
1006
Assert.True(outputs.
DependencyTable
.ContainsKey(rootingMarker2));
1007
Assert.False(outputs.
DependencyTable
.ContainsKey(rootingMarker3));
1045
Assert.True(outputs.
DependencyTable
.ContainsKey(rootingMarker1));
1046
Assert.True(outputs.
DependencyTable
.ContainsKey(rootingMarker2));
1047
Assert.True(outputs.
DependencyTable
.ContainsKey(rootingMarker3));
1051
Assert.True(outputs.
DependencyTable
.ContainsKey(rootingMarker1));
1052
Assert.True(outputs.
DependencyTable
.ContainsKey(rootingMarker2));
1053
Assert.True(outputs.
DependencyTable
.ContainsKey(rootingMarker3));
2542
Assert.Single(outputs.
DependencyTable
[threeRootingMarker]);
2543
Assert.False(outputs.
DependencyTable
[threeRootingMarker].ContainsKey(Path.GetFullPath(Path.Combine("TestFiles", "three.obj"))));