Skip to content

Commit 215c22e

Browse files
committed
Updated packages
1 parent 1b5cba2 commit 215c22e

14 files changed

Lines changed: 138 additions & 126 deletions

File tree

ApprovalTestTool/ApprovalTestTool.csproj

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
</ItemGroup>
1313

1414
<ItemGroup>
15-
<ProjectReference Include="..\CodeParser\CodeParser.csproj"/>
16-
<ProjectReference Include="..\CodeGraph\CodeGraph.csproj"/>
15+
<ProjectReference Include="..\CodeParser\CodeParser.csproj" />
16+
<ProjectReference Include="..\CodeGraph\CodeGraph.csproj" />
1717
</ItemGroup>
1818

1919
<ItemGroup>
@@ -22,4 +22,8 @@
2222
</None>
2323
</ItemGroup>
2424

25+
<ItemGroup>
26+
<PackageReference Update="Microsoft.Build.Framework" Version="18.0.2" />
27+
</ItemGroup>
28+
2529
</Project>

CSharpCodeAnalyst/Analyzers/EventRegistration/Analyzer.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,4 +80,9 @@ bool IsIncomplete(Relationship r)
8080
return !(r.HasAttribute(RelationshipAttribute.EventUnregistration) && r.HasAttribute(RelationshipAttribute.EventRegistration));
8181
}
8282
}
83+
84+
protected virtual void OnDataChanged()
85+
{
86+
DataChanged?.Invoke(this, EventArgs.Empty);
87+
}
8388
}

CSharpCodeAnalyst/Areas/CycleGroupsArea/CycleGroupViewModel.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public CycleGroupViewModel(CycleGroup cycleGroup)
1717
{
1818
CycleGroup = cycleGroup;
1919

20-
Name = cycleGroup.Name;
20+
_name = cycleGroup.Name;
2121

2222
var nodes = CycleGroup.CodeGraph.Nodes.Values;
2323
List<CodeElementLineViewModel> vms;

CSharpCodeAnalyst/Areas/TreeArea/TreeViewModel.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -383,7 +383,7 @@ public void ExecuteSearch()
383383
if (!string.IsNullOrEmpty(_lastSelectedCodeElement))
384384
{
385385
// Since I want to keep the highlighting, I likely want to keep the location.
386-
if ((bool)_codeGraph?.Nodes.ContainsKey(_lastSelectedCodeElement))
386+
if (_codeGraph != null && _codeGraph.Nodes.ContainsKey(_lastSelectedCodeElement))
387387
{
388388
_messaging.Publish(new LocateInTreeRequest(_lastSelectedCodeElement));
389389
}

CSharpCodeAnalyst/CSharpCodeAnalyst.csproj

Lines changed: 95 additions & 91 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
</PropertyGroup>
1111

1212
<ItemGroup>
13-
<None Remove="Resources\collapse-all_32.png"/>
14-
<None Remove="Resources\expand-all_32.png"/>
13+
<None Remove="Resources\collapse-all_32.png" />
14+
<None Remove="Resources\expand-all_32.png" />
1515
</ItemGroup>
1616

1717
<ItemGroup>
@@ -49,108 +49,108 @@
4949
<Content Include="appsettings.json">
5050
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
5151
</Content>
52-
<Content Include="lamp.ico"/>
52+
<Content Include="lamp.ico" />
5353
</ItemGroup>
5454

5555

5656
<ItemGroup>
57-
<Resource Include="Resources\add_parent_16.png"/>
58-
<Resource Include="Resources\collapse-all_32.png"/>
59-
<Resource Include="Resources\copy_fqn_16.png"/>
60-
<Resource Include="Resources\expand-all_32.png"/>
61-
<Resource Include="Resources\find_abstractions_16.png"/>
62-
<Resource Include="Resources\find_inheritance_tree_16.png"/>
63-
<Resource Include="Resources\find_in_tree_16.png"/>
64-
<Resource Include="Resources\find_specializations_16.png"/>
65-
<Resource Include="Resources\follow_incoming_calls_16.png"/>
66-
<Resource Include="Resources\funnel_32.png"/>
67-
<Resource Include="Resources\check.png"/>
68-
<Resource Include="Resources\analysis_32.png"/>
69-
<Resource Include="Resources\error.png"/>
70-
<Resource Include="Resources\flag.png"/>
71-
<Resource Include="Resources\guidepost_small.png"/>
72-
<Resource Include="Resources\help_32.png"/>
73-
<Resource Include="Resources\incoming_calls_16.png"/>
74-
<Resource Include="Resources\incoming_relationships_16.png"/>
75-
<Resource Include="Resources\legend_32.png"/>
76-
<Resource Include="Resources\filter_32.png"/>
77-
<Resource Include="Resources\outgoing_calls_16.png"/>
78-
<Resource Include="Resources\outgoing_relationships_16.png"/>
79-
<Resource Include="Resources\remove_without_children_16.png"/>
80-
<Resource Include="Resources\remove_with_children_16.png"/>
81-
<Resource Include="Resources\rendering.png"/>
82-
<Resource Include="Resources\search_32.png"/>
83-
<Resource Include="Resources\slider.png"/>
84-
<Resource Include="Resources\undo_32.png"/>
85-
<Resource Include="Resources\redo_32.png"/>
86-
<Resource Include="Resources\clear_32.png"/>
87-
<Resource Include="Resources\Collapse_16.png"/>
88-
<Resource Include="Resources\complexity_32.png"/>
89-
<Resource Include="Resources\cycle_32.png"/>
90-
<Resource Include="Resources\document-xml.png"/>
91-
<Resource Include="Resources\document_graph_32.png"/>
92-
<Resource Include="Resources\document-xml_32.png"/>
93-
<Resource Include="Resources\four-arrows.png"/>
94-
<Resource Include="Resources\four-arrows_32.png"/>
95-
<Resource Include="Resources\gear_32.png"/>
96-
<Resource Include="Resources\import_solution.png"/>
97-
<Resource Include="Resources\info_large.png"/>
98-
<Resource Include="Resources\lamp.png"/>
99-
<Resource Include="Resources\left-right.png"/>
100-
<Resource Include="Resources\left-right_small.png"/>
101-
<Resource Include="Resources\load_project.png"/>
102-
<Resource Include="Resources\png-file_32.png"/>
103-
<Resource Include="Resources\question.png"/>
104-
<Resource Include="Resources\question_small.png"/>
105-
<Resource Include="Resources\save_project.png"/>
106-
<Resource Include="Resources\spreadsheet_32.png"/>
107-
<Resource Include="Resources\svg-file_32.png"/>
108-
<Resource Include="Resources\switch.png"/>
109-
<Resource Include="Resources\trash-can.png"/>
110-
<Resource Include="Resources\trash-can_32.png"/>
111-
<Resource Include="Resources\workflow.png"/>
112-
<Resource Include="Resources\cycle.png"/>
113-
<Resource Include="Resources\unstructured-data_32.png"/>
114-
<Resource Include="Resources\Assembly_16.png"/>
115-
<Resource Include="Resources\Namespace_16.png"/>
116-
<Resource Include="Resources\Class_16.png"/>
117-
<Resource Include="Resources\Interface_16.png"/>
118-
<Resource Include="Resources\Struct_16.png"/>
119-
<Resource Include="Resources\Method_16.png"/>
120-
<Resource Include="Resources\Property_16.png"/>
121-
<Resource Include="Resources\Delegate_16.png"/>
122-
<Resource Include="Resources\Event_16.png"/>
123-
<Resource Include="Resources\Enum_16.png"/>
124-
<Resource Include="Resources\Field_16.png"/>
125-
<Resource Include="Resources\Record_16.png"/>
126-
<Resource Include="Resources\Other_16.png"/>
127-
<Resource Include="Resources\blue-info_16.png"/>
128-
<Resource Include="Resources\focus_32.png"/>
129-
<Resource Include="Resources\puzzle.png"/>
130-
<Resource Include="Resources\synchronize_32.png"/>
131-
<Resource Include="Resources\flag-empty_32.png"/>
132-
<None Remove="Resources\lamp.ico"/>
133-
<Resource Include="Resources\lamp.ico"/>
134-
<None Remove="Resources\restore_32.png"/>
135-
<Resource Include="Resources\restore_32.png"/>
136-
<None Remove="Resources\snapshot_32.png"/>
137-
<Resource Include="Resources\snapshot_32.png"/>
138-
<None Remove="Resources\add-parent_32.png"/>
139-
<Resource Include="Resources\add-parent_32.png"/>
57+
<Resource Include="Resources\add_parent_16.png" />
58+
<Resource Include="Resources\collapse-all_32.png" />
59+
<Resource Include="Resources\copy_fqn_16.png" />
60+
<Resource Include="Resources\expand-all_32.png" />
61+
<Resource Include="Resources\find_abstractions_16.png" />
62+
<Resource Include="Resources\find_inheritance_tree_16.png" />
63+
<Resource Include="Resources\find_in_tree_16.png" />
64+
<Resource Include="Resources\find_specializations_16.png" />
65+
<Resource Include="Resources\follow_incoming_calls_16.png" />
66+
<Resource Include="Resources\funnel_32.png" />
67+
<Resource Include="Resources\check.png" />
68+
<Resource Include="Resources\analysis_32.png" />
69+
<Resource Include="Resources\error.png" />
70+
<Resource Include="Resources\flag.png" />
71+
<Resource Include="Resources\guidepost_small.png" />
72+
<Resource Include="Resources\help_32.png" />
73+
<Resource Include="Resources\incoming_calls_16.png" />
74+
<Resource Include="Resources\incoming_relationships_16.png" />
75+
<Resource Include="Resources\legend_32.png" />
76+
<Resource Include="Resources\filter_32.png" />
77+
<Resource Include="Resources\outgoing_calls_16.png" />
78+
<Resource Include="Resources\outgoing_relationships_16.png" />
79+
<Resource Include="Resources\remove_without_children_16.png" />
80+
<Resource Include="Resources\remove_with_children_16.png" />
81+
<Resource Include="Resources\rendering.png" />
82+
<Resource Include="Resources\search_32.png" />
83+
<Resource Include="Resources\slider.png" />
84+
<Resource Include="Resources\undo_32.png" />
85+
<Resource Include="Resources\redo_32.png" />
86+
<Resource Include="Resources\clear_32.png" />
87+
<Resource Include="Resources\Collapse_16.png" />
88+
<Resource Include="Resources\complexity_32.png" />
89+
<Resource Include="Resources\cycle_32.png" />
90+
<Resource Include="Resources\document-xml.png" />
91+
<Resource Include="Resources\document_graph_32.png" />
92+
<Resource Include="Resources\document-xml_32.png" />
93+
<Resource Include="Resources\four-arrows.png" />
94+
<Resource Include="Resources\four-arrows_32.png" />
95+
<Resource Include="Resources\gear_32.png" />
96+
<Resource Include="Resources\import_solution.png" />
97+
<Resource Include="Resources\info_large.png" />
98+
<Resource Include="Resources\lamp.png" />
99+
<Resource Include="Resources\left-right.png" />
100+
<Resource Include="Resources\left-right_small.png" />
101+
<Resource Include="Resources\load_project.png" />
102+
<Resource Include="Resources\png-file_32.png" />
103+
<Resource Include="Resources\question.png" />
104+
<Resource Include="Resources\question_small.png" />
105+
<Resource Include="Resources\save_project.png" />
106+
<Resource Include="Resources\spreadsheet_32.png" />
107+
<Resource Include="Resources\svg-file_32.png" />
108+
<Resource Include="Resources\switch.png" />
109+
<Resource Include="Resources\trash-can.png" />
110+
<Resource Include="Resources\trash-can_32.png" />
111+
<Resource Include="Resources\workflow.png" />
112+
<Resource Include="Resources\cycle.png" />
113+
<Resource Include="Resources\unstructured-data_32.png" />
114+
<Resource Include="Resources\Assembly_16.png" />
115+
<Resource Include="Resources\Namespace_16.png" />
116+
<Resource Include="Resources\Class_16.png" />
117+
<Resource Include="Resources\Interface_16.png" />
118+
<Resource Include="Resources\Struct_16.png" />
119+
<Resource Include="Resources\Method_16.png" />
120+
<Resource Include="Resources\Property_16.png" />
121+
<Resource Include="Resources\Delegate_16.png" />
122+
<Resource Include="Resources\Event_16.png" />
123+
<Resource Include="Resources\Enum_16.png" />
124+
<Resource Include="Resources\Field_16.png" />
125+
<Resource Include="Resources\Record_16.png" />
126+
<Resource Include="Resources\Other_16.png" />
127+
<Resource Include="Resources\blue-info_16.png" />
128+
<Resource Include="Resources\focus_32.png" />
129+
<Resource Include="Resources\puzzle.png" />
130+
<Resource Include="Resources\synchronize_32.png" />
131+
<Resource Include="Resources\flag-empty_32.png" />
132+
<None Remove="Resources\lamp.ico" />
133+
<Resource Include="Resources\lamp.ico" />
134+
<None Remove="Resources\restore_32.png" />
135+
<Resource Include="Resources\restore_32.png" />
136+
<None Remove="Resources\snapshot_32.png" />
137+
<Resource Include="Resources\snapshot_32.png" />
138+
<None Remove="Resources\add-parent_32.png" />
139+
<Resource Include="Resources\add-parent_32.png" />
140140
</ItemGroup>
141141

142142

143143
<ItemGroup>
144144
<PackageReference Include="gong-wpf-dragdrop" Version="4.0.0" />
145-
<PackageReference Include="Microsoft.Extensions.Configuration" Version="10.0.1" />
146-
<PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="10.0.1" />
147-
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="10.0.1" />
145+
<PackageReference Include="Microsoft.Extensions.Configuration" Version="10.0.2" />
146+
<PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="10.0.2" />
147+
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="10.0.2" />
148148
<PackageReference Include="Microsoft.Xaml.Behaviors.Wpf" Version="1.1.135" />
149149
</ItemGroup>
150150

151151
<ItemGroup>
152-
<ProjectReference Include="..\CodeParser\CodeParser.csproj"/>
153-
<ProjectReference Include="..\CodeGraph\CodeGraph.csproj"/>
152+
<ProjectReference Include="..\CodeParser\CodeParser.csproj" />
153+
<ProjectReference Include="..\CodeGraph\CodeGraph.csproj" />
154154
</ItemGroup>
155155

156156
<ItemGroup>
@@ -195,4 +195,8 @@
195195
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
196196
</None>
197197
</ItemGroup>
198+
199+
<ItemGroup>
200+
<PackageReference Update="Microsoft.Build.Framework" Version="18.0.2" />
201+
</ItemGroup>
198202
</Project>

CodeGraph/CodeGraph.csproj

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,8 @@
77
<RootNamespace>CodeGraph</RootNamespace>
88
</PropertyGroup>
99

10+
<ItemGroup>
11+
<PackageReference Update="Microsoft.Build.Framework" Version="18.0.2" />
12+
</ItemGroup>
13+
1014
</Project>

CodeGraphAlgorithms/CodeGraphAlgorithms.csproj

Lines changed: 0 additions & 13 deletions
This file was deleted.

CodeParser/CodeParser.csproj

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,11 @@
2020
</ItemGroup>
2121

2222
<ItemGroup>
23-
<ProjectReference Include="..\CodeGraph\CodeGraph.csproj"/>
23+
<ProjectReference Include="..\CodeGraph\CodeGraph.csproj" />
24+
</ItemGroup>
25+
26+
<ItemGroup>
27+
<PackageReference Update="Microsoft.Build.Framework" Version="18.0.2" />
2428
</ItemGroup>
2529

2630
</Project>

CodeParser/Parser/Parser.cs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ public IParserDiagnostics Diagnostics
5454
_progress.SendProgress("Compiling project ...");
5555

5656
using var workspace = MSBuildWorkspace.Create();
57-
workspace.WorkspaceFailed += Workspace_WorkspaceFailed;
57+
workspace.RegisterWorkspaceFailedHandler(WorkspaceFailedHandler);
5858
var project = await workspace.OpenProjectAsync(projectPath);
5959

6060
// Create a solution from the single project
@@ -66,6 +66,12 @@ public IParserDiagnostics Diagnostics
6666
return await ParseSolutionInternal(solution);
6767
}
6868

69+
private void WorkspaceFailedHandler(WorkspaceDiagnosticEventArgs e)
70+
{
71+
_diagnostics.Add(e.Diagnostic);
72+
Trace.WriteLine(e.Diagnostic.Message);
73+
}
74+
6975
/// <summary>
7076
/// Parses a complete solution and builds a code graph.
7177
/// </summary>
@@ -77,7 +83,7 @@ public IParserDiagnostics Diagnostics
7783
_progress.SendProgress("Compiling solution ...");
7884

7985
using var workspace = MSBuildWorkspace.Create();
80-
workspace.WorkspaceFailed += Workspace_WorkspaceFailed;
86+
workspace.RegisterWorkspaceFailedHandler(WorkspaceFailedHandler);
8187
var solution = await workspace.OpenSolutionAsync(solutionPath);
8288

8389
sw.Stop();
@@ -121,12 +127,6 @@ public IParserDiagnostics Diagnostics
121127
}
122128

123129

124-
private void Workspace_WorkspaceFailed(object? sender, WorkspaceDiagnosticEventArgs e)
125-
{
126-
_diagnostics.Add(e.Diagnostic);
127-
Trace.WriteLine(e.Diagnostic.Message);
128-
}
129-
130130
/// <summary>
131131
/// If any assembly uses the global namespace we add the global namespace to all assemblies.
132132
/// For example a unit test assembly may have the autogenerated Main.

Tests/ApprovalTests/ModuleLevelApprovalTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ private static CodeElement GetAssembly(CodeElement element)
8686
}
8787

8888
Assert.That(assembly != null);
89-
return assembly;
89+
return assembly!;
9090
}
9191

9292
[Test]

0 commit comments

Comments
 (0)