---------- Forwarded message ----------
From: Chamara Philips <chama...@wso2.com>
Date: Fri, Nov 20, 2015 at 8:15 AM
Subject: Re: [Dev] [Automation][DS] Build is not getting fail since the
find-bug finds bugs in the code
To: Rajeenthini Satkunam <rajeenth...@wso2.com>


Hi Rajeenthini,

It is not necessary to set failOnError to true, as it is default. Can you
please try removing the "failOnError" property. Also you have missed the
version. Following plugin declaration worked for me to run it successfully
without integrating tests. I think adding "includeTests" should work fine
with tests.

<build>
    <plugins>
        <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>findbugs-maven-plugin</artifactId>
            <version>2.5.2</version>
            <configuration>

                <effort>Max</effort>

                <threshold>Low</threshold>

                <xmlOutput>true</xmlOutput>


<findbugsXmlOutputDirectory>${project.build.directory}/findbugs</findbugsXmlOutputDirectory>
            </configuration>
            <executions>
                <execution>
                    <id>analyze-compile</id>
                    <phase>compile</phase>
                    <goals>
                        <goal>check</goal>
                    </goals>
                </execution>
            </executions>
        </plugin>
    </plugins>
</build>

Thanks.

On Thu, Nov 19, 2015 at 2:54 PM, Rajeenthini Satkunam <rajeenth...@wso2.com>
wrote:

> Hi all,
>
> I would like to integrate find-bug plugin with a maven build of product DS
> Integration test module(Dashboard Server).So I have added the plugin maven
> find-bug under plugins in POM of integration module of product DS.
> Here is the code I have added in POM.
>
> <plugin>
>     <groupId>org.codehaus.mojo</groupId>
>     <artifactId>findbugs-maven-plugin</artifactId>
>     <configuration>
>         <effort>Max</effort>
>         <threshold>Low</threshold>
>         <xmlOutput>true</xmlOutput>
>         
> <findbugsXmlOutputDirectory>${project.build.directory}/findbugs</findbugsXmlOutputDirectory>
>         <includeTests>true</includeTests>
>         <failOnError>true</failOnError>
>     </configuration>
>     <executions>
>         <execution>
>             <id>analyze-compile</id>
>             <phase>verify</phase>
>             <goals>
>                 <goal>check</goal>
>             </goals>
>         </execution>
>     </executions>
> </plugin>
>
> But the build is not getting fail even I got some bugs through find-bug
> tool.I can produce the findbugsXml.xml file under directory findBug.Can
> anyone tell that do I need to add any other configurations to run this tool
> for test sources rather than adding this plugin to POM?
>
> I have asked this from StackOverFlow as well you can find the question
> here[1].
> [1] -
> http://stackoverflow.com/questions/33796044/how-can-i-integrate-find-bug-maven-plugin-to-integration-test-module
>
> references
>
> [2] - http://gleclaire.github.io/findbugs-maven-plugin/
> [3] -
> http://stackoverflow.com/questions/33234692/maven-findbugs-plugin-how-to-run-findbug-on-the-test-classes
> --
>
> *Thank You.*
>
> *Rajeenthini Satkunam*
>
> *Associate Software Engineer | WSO2*
>
>
> *E:rajeenth...@wso2.com <rajeenth...@wso2.com>*
>
> *M :+94770832823 <%2B94770832823>   *
>
>
> _______________________________________________
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
Hareendra Chamara P h i l i p s
*Software  Engineer*
Mobile : +94 (0) 767 184161 <%2B94%20%280%29%20773%20451194>
chama...@wso2.com <thili...@wso2.com>




-- 
Hareendra Chamara P h i l i p s
*Software  Engineer*
Mobile : +94 (0) 767 184161 <%2B94%20%280%29%20773%20451194>
chama...@wso2.com <thili...@wso2.com>
_______________________________________________
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to