2

I am trying to use Sonar with my .NET project (I have installed the c# plugin), but When I launch sonar-runner with this .properties file :

# identifiants du projet sonar.projectKey=key.myproject sonar.projectName=myproject sonar.projectVersion=1.0 # fichier .sln sonar.dotnet.visualstudio.solution.file="d:\dossier-source\myproject.sln" # répertoires de sources sources="d:\dossier-source" # Tests tests="d:\dossier-source\myproject.Tests" # langage sonar.language=cs 

I have this exception :

Exception in thread "main" org.sonar.batch.bootstrapper.BootstrapException: org. picocontainer.PicoLifecycleException: PicoLifecycleException: method 'public fin al void org.sonar.api.batch.bootstrap.ProjectBuilder.start()', instance 'org.son ar.plugins.csharp.core.VisualStudioProjectBuilder@11ecab56, java.lang.RuntimeExc eption: wrapper

1 Answer 1

2

You should put this properties file in the same folder as your SLN file ("d:\dossier-source"), and with the following properties only:

sonar.projectKey=key.myproject sonar.projectName=myproject sonar.projectVersion=1.0 sources=. sonar.language=cs 

And then run "sonar-runner" from "d:\dossier-source".

This should work.

Sign up to request clarification or add additional context in comments.

6 Comments

Thank you, I have always an exception caused by Gallio. I have to install Gallio ? In final, I would run Sonar with TFS.
Yes, you have to install Gallio, all this is explained on the documentation page: docs.codehaus.org/display/SONAR/…
I have an exception "Gallio execution failed" Caused by: org.sonar.dotnet.tools.gallio.GallioException: No test assembly was f ound. Please check your project's Gallio plugin configuration. I have added tests=myproject.Tests but nothing
The property "tests=" is useless: the C# plugins look into your SLN file to find out which projects are test projects, based on the "sonar.donet.visualstudio.testProjectPattern" property which defauls to "*.Tests".
Thanks for your response, my test project name is myproject.Tests :-/ but doesn't work
|

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.