实践maven-surefire-report-plugin

Maven Surefire Report Plugin parses the generated TEST-*.xml files under ${basedir}/target/surefire-reports and renders them using DOXIA, which creates the web interface version of the test results.

Goals

The Surefire Report Plugin only has one goal (the other is a workaround):

使用

Generate the Report in a Standalone Fashion

mvn surefire-report:report

Generate the Report as Part of Project Reports

1
2
3
4
5
6
7
8
<reporting>
    <plugins>
        <plugin>
			<groupId>org.apache.maven.plugins</groupId>
			<artifactId>maven-surefire-report-plugin</artifactId>
		</plugin>
    </plugins>
</reporting>

mvn site