From Code Reviews to Code Rules
summary
Claim: automating the easy, visual conventions frees code review time for architecture and performance. Implementation uses standard .NET tools, unit tests that verify EF migration designer files and image sizes, custom Roslyn analyzers (and code fixers) that flag DateTime.Now and Mediator.Send-in-handler patterns, plus net format and CI pipeline checks. Demo shows net format auto-fixing braces, a unit test failing when a designer file is deleted, analyzers surfacing bad API use, and a GitHub Action that fails a PR when a migration file is removed.
AI-written summary · about
chapters (17)
- 0:00Intro Update Conference Krakow
- 0:35Session start
- 1:59What rules and guidelines?
- 3:36Why do we need rules?
- 5:52How do we share this "knowledge"
- 7:00Problems with documentation
- 8:33How do we enforce the rules?
- 10:37Impact
- 12:25Make rules great again
- 13:19Code style
- 14:07Leveraging unit tests
- 16:14Architecture tests
- 17:14Code analyzers
- 19:07Code fixers
- 20:42Pipelines / actions
- 22:30Demo
- 45:03Closing thoughts
related talks
53mCode Foresting: Automating Architecture Governance for .NET Teams
53mEnforce Coding Standards in .NET: Overcome Broken Window Syndrome
50mAnalyzing Code in .NET
50mAutomate Yourself Out Of a Job With Roslyn
33mCode Review for Test Automation
35mIaC Automated Assurance
11mUplifting the Art of Code Review from Testing Perspective
32mFive Lines of Code
