contrueCT opened a new pull request, #3161:
URL: https://github.com/apache/hugegraph/pull/3161
## Purpose of the PR
- close #3160
PD and Store CI run several Maven test profiles in separate invocations, but
each invocation previously replaced JaCoCo execution data and generated a
partial report. PD also ran `mvn clean package` after two coverage-producing
test profiles, deleting their data before upload. As a result, Codecov could
receive only the last profile's coverage or an imprecisely selected report.
The existing JaCoCo 0.8.4 configuration also cannot instrument Java 17 class
files, which blocks the project's planned Java 17 migration.
## Main Changes
- Move the PD clean/package step before all coverage-producing test profiles.
- Upgrade PD and Store JaCoCo plugins from 0.8.4 to 0.8.8 and append
execution
data across Maven invocations.
- Assign a deterministic JaCoCo session ID to every PD/Store test profile,
then
verify that the final report contains the complete expected session set.
- Generate one aggregate XML report during `verify` and upload that exact
file
to Codecov.
- Include `hg-store-rocksdb` as a direct report-aggregate dependency so its
coverage is present in the Store report.
- Add a validator and contract tests for missing reports, uncovered reports,
missing suites, missing modules, Maven lifecycle bindings, and workflow
paths.
## Verifying these changes
- [ ] Trivial rework / code cleanup without any test coverage. (No Need)
- [ ] Already covered by existing tests, such as *(please modify tests
here)*.
- [x] Need tests and can be verified as follows:
-
`hugegraph-server/hugegraph-dist/src/assembly/travis/test-check-jacoco-report.sh`
- Parse `.github/workflows/pd-store-ci.yml` with PyYAML and all changed
POMs
with `xmllint`.
- `mvn -q apache-rat:check -N -ntp`
- `mvn -q editorconfig:check -N -ntp`
- `mvn verify -pl hugegraph-pd/hg-pd-test -am -P jacoco -DskipTests -ntp`
- `mvn verify -pl hugegraph-store/hg-store-test -am -P jacoco
-DskipTests -ntp`
- Java 17 smoke: JaCoCo 0.8.4 rejects class-file major version 61, while
0.8.8 instruments the same class and writes execution data
successfully.
The complete ten-profile PD/Store workflow and the external Codecov upload
are
left to GitHub Actions because the local environment uses JDK 17 while this
workflow currently installs JDK 11.
## Does this PR potentially affect the following parts?
- [ ] Dependencies ([add/update
license](https://hugegraph.apache.org/docs/contribution-guidelines/contribute/#321-check-licenses)
info &
[regenerate_known_dependencies.sh](../install-dist/scripts/dependency/regenerate_known_dependencies.sh))
- [x] Modify configurations
- [ ] The public API
- [x] Other affects (PD/Store CI coverage collection and upload)
- [ ] Nope
## Documentation Status
- [ ] `Doc - TODO`
- [ ] `Doc - Done`
- [x] `Doc - No Need`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]