Skip to content

Commit 5f092e5

Browse files
test: fix multi module coverage (#14)
Signed-off-by: goflutterjava <[email protected]>
1 parent 775c393 commit 5f092e5

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

pom.xml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
<maven.compiler.target>17</maven.compiler.target>
2323
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
2424
<src.dir>src/main/java</src.dir>
25+
<jacoco.overall.exec>${maven.multiModuleProjectDirectory}/target/jacoco/jacoco.exec</jacoco.overall.exec>
2526
<!-- dependency -->
2627
<http-facade.version>0.2.0</http-facade.version>
2728
<huaweicloud-sdk.version>3.1.117</huaweicloud-sdk.version>
@@ -82,16 +83,23 @@
8283
<groupId>org.jacoco</groupId>
8384
<artifactId>jacoco-maven-plugin</artifactId>
8485
<version>${jacoco-maven-plugin.version}</version>
86+
<configuration>
87+
<destFile>${jacoco.overall.exec}</destFile>
88+
<dataFile>${jacoco.overall.exec}</dataFile>
89+
</configuration>
8590
<executions>
8691
<execution>
8792
<id>prepare-agent</id>
93+
<configuration>
94+
<append>true</append>
95+
</configuration>
8896
<goals>
8997
<goal>prepare-agent</goal>
9098
</goals>
9199
</execution>
92100
<execution>
93101
<id>report</id>
94-
<phase>test</phase>
102+
<phase>validate</phase>
95103
<goals>
96104
<goal>report</goal>
97105
</goals>

0 commit comments

Comments
 (0)