提交 54967c31 编写于 作者: V vongosling

Polish coveralls,jacoco,sonar and travis-ci integration

上级 cc069a13
...@@ -4,20 +4,18 @@ notifications: ...@@ -4,20 +4,18 @@ notifications:
- dev@rocketmq.incubator.apache.org - dev@rocketmq.incubator.apache.org
on_success: change on_success: change
on_failure: always on_failure: always
language: java
matrix: matrix:
include: include:
# On OSX, run with default JDK only. # On OSX, run with default JDK only.
- language: java
- os: osx - os: osx
# On Linux, run with specific JDKs only. # On Linux, run with specific JDKs only.
- language: java
- os: linux - os: linux
env: CUSTOM_JDK="oraclejdk8" env: CUSTOM_JDK="oraclejdk8"
- language: java
- os: linux - os: linux
env: CUSTOM_JDK="oraclejdk7" env: CUSTOM_JDK="oraclejdk7"
- language: java
- os: linux - os: linux
env: CUSTOM_JDK="openjdk7" env: CUSTOM_JDK="openjdk7"
...@@ -26,7 +24,7 @@ before_install: ...@@ -26,7 +24,7 @@ before_install:
- cat ~/.mavenrc - cat ~/.mavenrc
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then export JAVA_HOME=$(/usr/libexec/java_home); fi - if [ "$TRAVIS_OS_NAME" == "osx" ]; then export JAVA_HOME=$(/usr/libexec/java_home); fi
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then jdk_switcher use "$CUSTOM_JDK"; fi - if [ "$TRAVIS_OS_NAME" == "linux" ]; then jdk_switcher use "$CUSTOM_JDK"; fi
#
#os: #os:
# - linux # - linux
# - osx # - osx
...@@ -36,9 +34,8 @@ before_install: ...@@ -36,9 +34,8 @@ before_install:
# - openjdk7 # - openjdk7
#script: script:
# - travis_retry mvn --batch-mode clean apache-rat:check - travis_retry mvn -B clean apache-rat:check package jacoo:report coveralls:report
# - travis_wait 60 mvn --batch-mode clean package findbugs:check
after_success: after_success:
- mvn clean apache-rat:check cobertura:cobertura coveralls:report - mvn sonar:sonar
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
<artifactId>rocketmq-all</artifactId> <artifactId>rocketmq-all</artifactId>
<version>4.0.0-SNAPSHOT</version> <version>4.0.0-SNAPSHOT</version>
<packaging>pom</packaging> <packaging>pom</packaging>
<name>Apache RocketMQ git s${project.version}</name> <name>Apache RocketMQ ${project.version}</name>
<url>http://rocketmq.incubator.apache.org/</url> <url>http://rocketmq.incubator.apache.org/</url>
<prerequisites> <prerequisites>
...@@ -152,6 +152,8 @@ ...@@ -152,6 +152,8 @@
<properties> <properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<!--maven properties --> <!--maven properties -->
<maven.test.skip>false</maven.test.skip> <maven.test.skip>false</maven.test.skip>
<maven.javadoc.skip>true</maven.javadoc.skip> <maven.javadoc.skip>true</maven.javadoc.skip>
...@@ -159,6 +161,14 @@ ...@@ -159,6 +161,14 @@
<maven.compiler.source>1.7</maven.compiler.source> <maven.compiler.source>1.7</maven.compiler.source>
<maven.compiler.target>1.7</maven.compiler.target> <maven.compiler.target>1.7</maven.compiler.target>
<!-- BEFORE SonarQube 4.4.0 - the destination file for the code coverage report has to be set to the same value
in the parent pom and in each module pom. Then JaCoCo will add up information in
the same report, so that, it will give the cross-module code coverage. -->
<sonar.java.coveragePlugin>jacoco</sonar.java.coveragePlugin>
<sonar.dynamicAnalysis>reuseReports</sonar.dynamicAnalysis>
<sonar.jacoco.reportPath>${project.basedir}/../target/jacoco.exec</sonar.jacoco.reportPath>
<sonar.jacoco.itReportPath>${project.basedir}/../target/jacoco-it.exec</sonar.jacoco.itReportPath>
<sonar.language>java</sonar.language>
<!-- URL of the ASF SonarQube server --> <!-- URL of the ASF SonarQube server -->
<sonar.host.url>https://builds.apache.org/analysis</sonar.host.url> <sonar.host.url>https://builds.apache.org/analysis</sonar.host.url>
<!-- Exclude all generated code --> <!-- Exclude all generated code -->
...@@ -329,14 +339,33 @@ ...@@ -329,14 +339,33 @@
<version>4.3.0</version> <version>4.3.0</version>
</plugin> </plugin>
<plugin> <plugin>
<groupId>org.codehaus.mojo</groupId> <groupId>org.jacoco</groupId>
<artifactId>cobertura-maven-plugin</artifactId> <artifactId>jacoco-maven-plugin</artifactId>
<version>2.7</version> <version>0.7.6.201602180812</version>
<configuration> <configuration>
<format>xml</format> <append>true</append>
<!-- aggregated reports for multi-module projects -->
<aggregate>true</aggregate>
</configuration> </configuration>
<executions>
<execution>
<id>agent-for-ut</id>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<execution>
<id>agent-for-it</id>
<goals>
<goal>prepare-agent-integration</goal>
</goals>
</execution>
<execution>
<id>report</id>
<phase>prepare-package</phase>
<goals>
<goal>report</goal>
</goals>
</execution>
</executions>
</plugin> </plugin>
<plugin> <plugin>
<groupId>org.codehaus.mojo</groupId> <groupId>org.codehaus.mojo</groupId>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册