Sonar runner + ReSharper getting message "ReSharper plugin is running in deprecated mode" - sonarqube

Configuration:
Sonar: V. 5.1.1.
C#-PlugIn: V. 4.0
ReSharper-PlugIn: V. 2.0
ReSharper-InspectCode: V. 9.1.1
I'm getting the message "ReSharper plugin is running in deprecated mode" even though I have configured it as recommended here.
Any suggestions what I am doing wrong here?

Short answer The mode where R# is executed by the SonarQube analyzer is going to be deprecated starting from next week.
Long [and boring] answer
The re-use reports mode will replace it, where you invoke inspectcode.exe yourself and provide the path to its report to the SonarQube analyzer.
The R# 2.0 plugin has been released to work with the MSBuild SonarQube Runner 1.0 which will be released next week.
The MSBuild SonarQube Runner will replace the Visual Studio Boostrapper plugin.
Now, the re-use reports mode of the R# 2.0 plugin only works with the MSBuild SonarQube Runner, and cannot be used with the Visual Studio Bootstrapper. This explains why we have to wait until the MSBuild SonarQube Runner is released before being able to officially deprecate the current mode.

Related

sonarqube:SonarQube Scanner 2.3 for Visual Studio 2017 Builds

one of our feature teams who is using SonarQube since long and they are now getting issues when they upgrade to VS 2017,To support SonarQube for scanning in VSTS build, we need the task updated with SonarQube 2.3 or higher to support along with VS 2017 for code analysis. May I know is there any work going on this when can we get the support for VS 2017?
Regarding SonarQube extension in VSTS, you can install SonarQube 3.0.2 version. (You need to update SonarQube extension if old version has already been installed in manage/admin extension page of you VSTS. https://XXX.visualstudio.com/_admin/_extensions)
After that, you can change 3.* version of SonarQube Scanner for MSBuild task in build or release.

Where can I find the "Customize On/Off" option?

In our Sonar Build Environment we use SonarQube Server Version 5.6.6 (64-Bit) and our analysis runs on a Sonar Client Build Operating System with Ubuntu 14.04.5 LTS (64-Bit).
Recently I have upgraded SonarQube from 5.1 to 5.6.6 (LTS). But under "Project Code" the "Customize ON|OFF" option is now missing.
Currently I can see only these options:
Lines of Code
Bugs
Vulnerabilities
Code Smells
Coverage
Duplications
In SonarQube version 5.1 I was using the "Customize ON|OFF" option to customize and add required columns.
How can I enable this feature back in SonarQube 5.6.6?
The feature does not exist any longer (it has been dropped when rewriting the Project space), and there's currently no plan to reintroduce it.

NUnit tests not list in Test Explorer with Nunit Test Adapter is installed

I am using vs 2013 pro.
I've installed NUnit and NUnit Test Adapter for VS2012, 2013, 2015.
I find there is no tests show up in Test Explorer. I rebuilt the solution, I restarted the computer, no help. I set platform targets for the main project and the test project to use any CPU, no help, set to x86, no help too.
Please help me. Thank you.
I had similar problem after installed NUnit.3.2.1.msi and NUnit3 TestAdapter as extension in VisualStudio 2015. In case it helps you to see the tests at least in one way, here is what I did: Although there was no tests visible in Test Explorer, I
1) pushed Run All,
2) saw an error text in the
status bar, in the bottom of Visual Studio window.
3) checked - as it instructed - the Output pane for Tests (Where is the 'tests output pane'?). In my case, it complained about exception in discovering tests, not supporting the portable version of NUnit and suggested using a platform specific runner.
4) tried out a solution to solve my error: I uninstalled the NUnit msi, in case it was the portable version not supported.
In VisualStudio, with my project open, I retrieved via NuGet Packgage Manager the NUnit 3.2.1 (April 19, 2016), NUnit Runners 3.2.1 (April 19, 2016), and NUnitTestAdapter 2.0 (April 2,2015). I think retrieving the NUnit Runners was the cure.
Additionally, I also removed from References Microsofts test library which had appeared there during trials. However, I don't believe it had any effect.
Your error description may be different, and may require a different solution.
I had same problem in VS2015. I solved it by downgrading NUnit to version 2.6.4. Latest 3.5.0 version appeared to be incompatible with latest NUnitTestAdapter 2.0.0. Seems it refers only to VS 2015, earlier version should be fine.

No code coverage for .NET Projects when MSBuild SonarQube Runner is used

We are using sonarqube 5.1.1 version and faced issues while analyzing .NET projects using sonar-runner.
As the recent update says, sonar-runner does not support .NET projects anymore, we have installed MSBuild.SonarQube.Runner-1.0 to analyze the same.
We are able to create dashboards for the .NET projects now but unit test cases and unit test coverage is missing.
Could you kindly help us here?
Please note that we have enterprise license and all the existing .NET projects in production environment use Visual studio 2010.
I have upgraded the dev instance to check the feasibility.

troubles with getting c# plugin 3.0 and resharper to work properly

we have upgraded to SonarQube 4.3 and C# plugin 3.0 but we are struggling to get the integration with resharper working.
Which version of the Reshaprer plugin shall be available for SonarQube 4.3?
In update center I find version 1.0 but when I look at the reshaper plugin documentation there shall be a version 1.1 available.
Can I upgrade to the resharper plugin to version 1.1 in any other way? I have tried to put the 1.1 jar file in the plugin directory but then SonarQube refuse to start due to missing dependencies.
The reason for wanting version 1.1 is that we need to use our own dotsettings file and this seems to not be available in version 1.0. We also can´t get the reuseReport mode to work at all with the current installed version. Even if we use “sonar.resharper.mode=skip” resharper is trigged in the analysis.
The situation is quite messy, there indeed was a ".NET ReSharper" plugin available in version 1.0 and 1.1. This plugin is only compatible with the .NET ecosystem 2.1.
C# 3.0 is only compatible with a "ReSharper" plugin, which only exists in version 1.0.
Please refer to the following documentation: http://docs.sonarqube.org/display/SONAR/ReSharper+Plugin
Indeed the ReSharper 1.0 plugin does not support reuseReport mode (and it is not planned to add it currently).
However, there are plans to be able to import/export DotSettings files from/to SonarQube quality profiles: https://jira.codehaus.org/browse/SONARPLUGINS-3738
Have also a look at the example project: https://github.com/SonarSource/sonar-examples/tree/master/projects/languages/csharp
Final note: The .NET ecosystem 2.1 is not compatible with SonarQube 4.3.

Resources