Skip to content

Setup using clean jacoco and jacoco-report gh action.#73

Open
miroslavpojer wants to merge 5 commits intomasterfrom
feature/migrate-to-latest-version-of-jacoco-filter
Open

Setup using clean jacoco and jacoco-report gh action.#73
miroslavpojer wants to merge 5 commits intomasterfrom
feature/migrate-to-latest-version-of-jacoco-filter

Conversation

@miroslavpojer
Copy link
Collaborator

@miroslavpojer miroslavpojer commented Feb 13, 2026

Overview

  • Introduced jacoco method filtering.

Release Notes:

  • Replaced the project’s custom JaCoCo integration with an external JaCoCo method-filter plugin and updated CI report path; build tooling and reporting behavior adjusted accordingly.

Summary by CodeRabbit

  • Chores

    • Minor formatting/whitespace cleanups applied across many source files (no behavior changes).
  • Refactor

    • Replaced the project’s custom JaCoCo integration with an external JaCoCo method-filter plugin and updated CI report path; build tooling and reporting behavior adjusted accordingly.

@coderabbitai
Copy link

coderabbitai bot commented Feb 13, 2026

Walkthrough

Replaces in-repo JaCoCo SBT plugins with the external MoranaApps jacoco-method-filter plugin, updates build/plugin config and CI report path, and adds trailing newlines across many Scala source files (formatting-only).

Changes

Cohort / File(s) Summary
Trailing newline formatting
balta/src/main/scala/za/co/absa/db/balta/DBTestSuite.scala, balta/src/main/scala/za/co/absa/db/balta/classes/*, balta/src/main/scala/za/co/absa/db/balta/implicits/*, balta/src/main/scala/za/co/absa/db/balta/postgres/*, balta/src/main/scala/za/co/absa/db/balta/typeclasses/*, balta/src/main/scala/za/co/absa/db/mag/*
Added trailing newlines / blank line at EOF across many Scala files; purely formatting, no logic or public API changes.
Removed in-repo JaCoCo plugins
project/FilteredJacocoAgentPlugin.scala, project/JacocoBaseKeysPlugin.scala
Deleted two custom SBT plugins and their public autoImport keys/tasks/helpers/commands that implemented JaCoCo integration and optional JMF-based rewriting.
Build config and plugins update
build.sbt, project/plugins.sbt
Switched project to .enablePlugins(JacocoFilterPlugin) in build.sbt and added addSbtPlugin("io.github.moranaapps" % "jacoco-method-filter-sbt" % "2.0.1") to project/plugins.sbt.
CI workflow update
.github/workflows/jacoco_report.yml
Adjusted Jacoco report path used by GitHub Action from balta/target/**/jacoco/report/jacoco.xml to balta/target/**/jacoco-report/jacoco.xml to match new plugin output location.

Sequence Diagram(s)

mermaid
sequenceDiagram
participant Dev as Developer/CI
participant SBT as SBT build
participant Plugin as JacocoFilterPlugin (moranaapps)
participant Reporter as GitHub Action (jacoco-report)
Dev->>SBT: run tests / build
SBT->>Plugin: invoke jacoco method filter plugin (attach / filter)
Plugin->>SBT: produce coverage output (balta/target/**/jacoco-report/jacoco.xml)
Dev->>Reporter: upload coverage artifact / generate report
Reporter->>Plugin: read balta/target/**/jacoco-report/jacoco.xml and publish report

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related PRs

Suggested reviewers

  • salamonpavel
  • tmikula-dev
  • benedeki

Poem

🐇 I hopped through lines both short and neat,
Swapped plugin shoes and fixed the beat.
New filter hums while reports align,
Files got newlines — tidy by design.
A carrot clap for builds divine! 🥕

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes the main changes: migrating to use a clean jacoco setup with the jacoco-report GitHub action, which matches the primary modifications in build configuration and plugin setup.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Merge Conflict Detection ✅ Passed ✅ No merge conflicts detected when merging into master
Description check ✅ Passed The PR description includes the required Overview and Release Notes sections with substantive content about introducing JaCoCo method filtering.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feature/migrate-to-latest-version-of-jacoco-filter

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link

github-actions bot commented Feb 13, 2026

JaCoCo Coverage Report

Metric (instruction) Coverage Threshold Status
Overall 50.66% 80.0%
Changed Files 50.66% 80.0%
Report Coverage (O/Ch) Threshold (O/Ch) Status (O/Ch)
Report: balta - scala:2.12.18 50.66% / 51.69% 80.0% / 80.0% ❌/❌
File Path Coverage Threshold Status
AsIsNaming.scala 54.17% 0.0%
ConnectionInfo.scala 100.0% 0.0%
DBConnection.scala 0.0% 0.0%
DBFunction.scala 57.02% 0.0%
DBQuerySupport.scala 100.0% 0.0%
DBTable.scala 89.9% 0.0%
DBTestSuite.scala 14.41% 0.0%
ExplicitNamingRequired.scala 66.67% 0.0%
LettersCase.scala 100.0% 0.0%
MapBasedNaming.scala 67.44% 0.0%
MapImplicits.scala 12.12% 0.0%
NamingConvention.scala 81.48% 0.0%
NamingException.scala 45.0% 0.0%
OptionImplicits.scala 14.86% 0.0%
Params.scala 43.98% 0.0%
Postgres.scala 27.68% 0.0%
PostgresQueryParamValue.scala 0.0% 0.0%
QueryParamType.scala 25.32% 0.0%
QueryParamValue.scala 53.12% 0.0%
QueryResult.scala 21.55% 0.0%
QueryResultRow.scala 90.77% 0.0%
QueryResultRowImplicits.scala 54.98% 0.0%
SimpleJsonString.scala 26.47% 0.0%
SnakeCaseNaming.scala 93.55% 0.0%

@miroslavpojer miroslavpojer marked this pull request as ready for review February 14, 2026 21:03
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@project/plugins.sbt`:
- Around line 2-3: The plugin artifact declared with addSbtPlugin uses a
non-existent ID ("io.github.moranaapps" % "jacoco-method-filter-sbt" % "2.0.0");
change the artifactId to the correct one that includes the Scala/Scala-compiler
suffix (e.g., "jacoco-method-filter-sbt_2.12_1.0") so the addSbtPlugin call
references "io.github.moranaapps" % "jacoco-method-filter-sbt_2.12_1.0" %
"2.0.0" (or the appropriate Scala suffix for your build) to match Maven Central.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant