Don Vince
Don Vince

Reputation: 1330

Measuring Testability of C# code

Having come across a link on stack overflow, I have found the writings of Miško Hevery very engaging reading. So good that I am seeing a new approach to what I previously thought I was doing quite well.

He talks mainly about Dependency Injection, Automated Unit Testing and Good Design.

A number of the good practices he advocates are things that can be programatically detected. And so there is a program to detect them Google Testability Explorer.

My questions is:

Upvotes: 7

Views: 1004

Answers (3)

Bryan Watts
Bryan Watts

Reputation: 45445

Pex is an interesting entry. It has the potential to take testing to a new level, especially when combined with Code Contracts.

Upvotes: 3

Bruno Shine
Bruno Shine

Reputation: 1031

You can also use FXCop.

FxCop is an application that analyzes managed code assemblies (code that targets the .NET Framework common language runtime) and reports information about the assemblies, such as possible design, localization, performance, and security improvements. Many of the issues concern violations of the programming and design rules set forth in the Design Guidelines for Class Library Developers, which are the Microsoft guidelines for writing robust and easily maintainable code by using the .NET Framework.

Hope it helps, Bruno Figueiredo

Upvotes: 0

kͩeͣmͮpͥ ͩ
kͩeͣmͮpͥ ͩ

Reputation: 7846

It doesn't provide the information in quite the same way as the Google Testability Explorer, but NDepend (non-free) provides a lot of code analysis for .Net assemblies.

Upvotes: 2

Related Questions