Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to start using ndepend?

I recently downloaded ndepend and ran an analysis on an open source project I participate in.

I did not now where to look next - a bit of visual and information overload and it turned out I don't even know where to start.

Can anyone suggest starting points?

  • What information should I look for first?
  • What points out problems in the code (in a BIG way)?
  • What would the low hanging fruit that can immediately seen?
like image 861
Oded Avatar asked Sep 04 '08 19:09

Oded


2 Answers

Scott Hanselman / Stuart Celarier / Patrick Cauldwell's poster with ndepend metrics has some useful information on it. Rather than trying to break down all the heuristics being used I'd focus on only a few at a time starting with "zone of pain / zone of uselessness" and cyclomatic complexity.

There is also a podcast which covers some of the basics of the tool.

Between that and running nDepend on a few different projects you may be able to start gathering useful data that you can make into insights.

like image 114
t3rse Avatar answered Sep 20 '22 17:09

t3rse


When starting with NDepend, the most important thing is to understand what Code Rule over LINQ (CQLinq) can bring to your shop by letting you define queries on your code and rules. Here you'll find a summary and source code of all 200 default code rules.

The second most important thing to look at is dependencies, with both the dependency graph view, that works hand-in-hand with the dependency matrix view. Once you master these 2 views, you'll be able to pinpoint where the code is well layered or not, and where developers made mistake.

Then it'll be time to learn more in-depth feature, such as the possibility to compare 2 versions of your code base, the various code metrics and why they are useful, enforcing statically purity and immutability, controlling automatically test coverage...

like image 40
Patrick from NDepend team Avatar answered Sep 22 '22 17:09

Patrick from NDepend team