@org.apache.maven.plugins.annotations.Mojo(name: verify, defaultPhase: LifecyclePhase.VERIFY, requiresDependencyResolution: ResolutionScope.TEST, requiresProject: true, threadSafe: true) class VerifyMojo extends BaseViolationCheckMojo
Fail the build if any SpotBugs violations can be found in a preexisting spotBugs.xml
file.
Note that unlike the check
goal, this goal only reads existing XML reports, without actually performing SpotBugs analysis.
This way, it is possible to split the analysis and verification into lifecycle phases of one's choosing.
One use case for that is running multiple code analyzers at once and only failing the build at a later stage, so that all of them have a chance to run.
To see more documentation about SpotBugs' options, please see the SpotBugs Manual..
Properties inherited from class | Properties |
---|---|
class BaseViolationCheckMojo |
artifactResolver, classFilesDirectory, debug, effort, excludeBugsFile, excludeFilterFile, failOnError, failThreshold, fork, includeFilterFile, includeTests, jvmArgs, maxAllowedViolations, maxHeap, maxRank, nested, omitVisitors, onlyAnalyze, outputDirectory, outputEncoding, pluginArtifacts, pluginList, quiet, relaxed, resourceManager, session, siteRenderer, siteTool, skip, sourceEncoding, spotbugsXmlOutputDirectory, spotbugsXmlOutputFilename, testClassFilesDirectory, threshold, timeout, trace, visitors, xmlOutput, xmlOutputDirectory, xrefLocation, xrefTestLocation |
Constructor and description |
---|
VerifyMojo() |
Methods inherited from class | Name |
---|---|
class BaseViolationCheckMojo |
doSourceFilesExist, execute, printBugs |
spotbugs-maven-plugin Groovy Documentation