0

I am new to maven. So finding it difficult to cope it with. I have two questions:

  1. Is there any way to add new contents in the maven surefire report plugin like new table etc. I want to customize the reports according to my need.
  2. I am using buildnumber plugin to get the unique run id for each run but this id is not getting reflected in the reports. Is buildnumber plugin only works with subversion?

The pom is;

<build>
<finalName>${project.artifactId}-${project.version}-r${buildNumber}</finalName>
  <plugins>
    <plugin>
     <groupId>org.codehaus.mojo</groupId>
        <artifactId>buildnumber-maven-plugin</artifactId>
        <version>1.0-beta-3</version>
        <executions>
          <execution>
            <phase>validate</phase>
            <goals>
              <goal>create</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <doCheck>true</doCheck>
          <doUpdate>false</doUpdate>
          <format>${project.version}.{0,number}</format>
          <items>
           <item>buildNumber</item>
          </items>
        </configuration>
      </plugin>
  </plugins>
</build>

I have one more query:

3-> If i make batch file or an exe file of the complete test suites can i run it on many JVM simultaneously for example with an eclipse i am running one JVM. But if am not using eclipse and just running the testsuite batch file directly can JRE instantiate many JVM instances. And if it is possible, do i need to associate each test suite with .m2 repository.

4

1 回答 1

1

回答你的第一个问题:不幸的是,没有。您可以按原样使用它们,或者您需要编写自己的 maven-surefire-report-plugin。但问题是您究竟想要定制什么。第二个问题: build-number-plugin 用于创建通常在创建 MANIFEST.MF 文件等期间使用的内部版本号。此外,buildNumber 插件也适用于 Git、Hg 等。但问题是你喜欢什么在这种情况下实现。Maven 中最重要的信息是 groupId、artifactId 和版本。

更新:顺便说一句。更新 buildnumber-plugin 版本 (1.0)。

更新:看看这里:http ://maven.apache.org/plugins/maven-surefire-report-plugin/usage.html

于 2012-03-17T14:10:33.260 回答