Skip to content

[INFRA] Wire RoslynAnalyzer into CLI analyze pipeline#39

Merged
EricCogen merged 2 commits intomainfrom
feature/static-analysis-strategy
Apr 11, 2026
Merged

[INFRA] Wire RoslynAnalyzer into CLI analyze pipeline#39
EricCogen merged 2 commits intomainfrom
feature/static-analysis-strategy

Conversation

@EricCogen
Copy link
Copy Markdown
Owner

Integrates the Roslyn static analysis runner into the CLI analyze command pipeline for richer code-level insights.

EricCogen and others added 2 commits April 10, 2026 23:23
Static analysis was integrated in tests but the CLI always passed null
for the staticAnalysis argument, meaning 6 rules (GCI0006, GCI0007,
GCI0009, GCI0012, GCI0015, GCI0024) never surfaced their Roslyn-backed
findings in real runs.

Changes:
- Add StaticAnalysisRunner: runs RoslynAnalyzer over changed .cs files
  found on disk, aggregates diagnostics across all files in the diff
- AnalyzeCommand: call StaticAnalysisRunner.RunAsync after parsing diff;
  pass result to orchestrator.RunAsync (null for --diff file mode)
- Static analysis is automatically skipped when: no repo path available,
  no .cs files changed, or changed files not present on disk
- Add 4 tests: null repo path, no .cs files, missing file, valid file

Fixes: audit finding 'static analysis pipeline half-integrated'

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings April 11, 2026 16:39
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review any files in this pull request.

@EricCogen EricCogen merged commit 5ca8f5d into main Apr 11, 2026
6 checks passed
@EricCogen EricCogen deleted the feature/static-analysis-strategy branch April 11, 2026 16:39
EricCogen added a commit that referenced this pull request Apr 18, 2026
[INFRA] Wire RoslynAnalyzer into CLI analyze pipeline
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants