custom rule created from a template doesn't work

27 views
Skip to first unread message

amit.wa...@gmail.com

unread,
Mar 13, 2018, 9:24:39 AM3/13/18
to SonarQube
Hi,
I created a custom rule from template 2253. The new custom rule is activated in the quality profile getting used.

However, after running the analysis, there are no code smells reported by the custom rule. I know the code against which I am running the analysis has the issue..

Only catch is my rule is set on an interface and not a class. Would this make a difference?

Michael Gumowski

unread,
Jun 7, 2018, 11:55:07 AM6/7/18
to amit.wa...@gmail.com, SonarQube
Hello Amit,

Maybe there is an issue with the configuration of your rule. 

From what I understand, you want to raise issues on all method invocations from a given method of an interface,but I'm not sure to follow. It would help if you could come up with an example reproducing the issue with a simple case (an interface with some methods, a few classes, some extra method invocations where you expect issues), and a rule configuration mimicking what you want for your real-production rule.

It would also help if you could provide your version of the SonarJava analyzer.

Thanks,
Michael


--
You received this message because you are subscribed to the Google Groups "SonarQube" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sonarqube+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sonarqube/ed097ff7-dbec-409f-a392-e460513920f3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Michael Gumowski | SonarSource
Software Developer, Language Team
https://www.sonarsource.com
Reply all
Reply to author
Forward
0 new messages