O'Reilly logo

Instant StyleCop Code Analysis How-to by Franck LEVEQUE

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Integrating StyleCop analysis results in Jenkins/Hudson (Intermediate)

In this recipe we will see how to build and display StyleCop errors in Jenkins/Hudson jobs. To do so, we will need to see how to configure the Jenkins job with a full analysis of the C# files in order to display the technical debt of the project. As we want it to diminish, we will also set in the job an automatic recording of the last number of violations. Finally, we will return an error if we add any violations when compared to the previous build.

Getting ready

For this recipe, you will need to have:

  • StyleCop 4.7 installed with the option MSBuild integration checked
  • A Subversion server
  • A working Jenkins server including:
    • The MSBuild plug in for Jenkins
    • The Violation plug in for ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required