Skip to content
CAI
Software that uses CAICheck a score

scoverage/scalac-scoverage-plugin

66.8

Adequate · 20 September 2026

3.3k

lines of production code

Scala

primary language

1

measurement over time

CAI band scale
CAI lens gauges

What this system is

This system is a code coverage tool for the Scala ecosystem, providing instrumentation and reporting capabilities across JVM, Scala.js, and Scala Native platforms. It collects execution metrics via a compiler plugin and runtime, supporting incremental coverage updates and multi-module projects with thread-safe data handling. The system generates detailed coverage reports in HTML, XML, and Cobertura formats, utilizing a structured domain model to visualize statement and branch coverage.

How it got here

2010 — Initial project scaffolding and scct refactoring

9 changes.

This period established the foundational structure of the scalac-scoverage-plugin repository, including licensing, documentation, and build configuration. It simultaneously involved a significant refactoring of the legacy scct coverage tool, removing outdated build definitions, HTML reporting assets, and obsolete tests while rewriting the instrumentation logic to support newer Scala versions.

2012–2022 — multi-platform and incremental coverage support

12 changes.

This period focused on expanding scoverage's platform support to include Scala.js with JSDOM and Scala Native, alongside significant architectural refactoring to enable incremental coverage. The work introduced a new modular domain model, a dedicated reporter module for various output formats, and thread-safe runtime improvements to handle multi-module and concurrent execution contexts.

Features

Add JavaScript runtime support for file operations and UUID generation

The JavaScript runtime now includes a complete file-system abstraction layer that emulates the Java \java.io.File\ API, enabling scoverage to read, write, and list files in JS environments. This implementation automatically detects the execution context—supporting Node.js, JSDOM, PhantomJS, and Rhino—and uses the appropriate backend for each. Additionally, the platform module now provides a custom \insecureRandomUUID\ implementation to generate version-4 UUIDs without relying on external Java security libraries.

runtime/js · high confidence

Add native platform support for scoverage

Introduces a new \Platform.scala\ implementation for the native runtime, providing necessary type aliases for file handling and a custom \insecureRandomUUID\ method to ensure compatibility with the Scala Native environment.

runtime/native · high confidence

Added test-release script for validating multi-platform artifacts

A new \bin/test-release.sh\ script has been added to verify the availability of Scoverage artifacts across Scala 2.12, 2.13, and 3, including JVM, Scala.js (sjs1), and Native (native0.4) platforms. The script uses Coursier to fetch specific plugin, runtime, domain, reporter, and serializer versions for these targets, ensuring that cross-published modules are correctly accessible before a release.

bin · high confidence

Initial project scaffolding and configuration

This change introduces the foundational structure for the scalac-scoverage-plugin repository. It adds essential configuration files including \.scalafmt.conf\ (version 3.11.5) and \.scalafix.conf\ to enforce code formatting and import organization, alongside a \.git-blame-ignore-revs\ file to streamline commit history review. The repository is now licensed under Apache 2.0, includes a Code of Conduct and Contributing guidelines, and provides a comprehensive README detailing statement and branch coverage features, usage with build tools like sbt and Maven, and exclusion strategies. Additionally, it documents the removal of Scala 2.10 support due to AST range-positioning issues with macros and updates the \.gitignore\ to cover modern IDE and build artifacts.

(repo-wide) · high confidence

New plain-text coverage data serializer and deserializer

The serializer module now provides a new \Serializer\ object that reads and writes coverage data to a structured plain-text format. This implementation handles serialization of \Coverage\ objects into a human-readable file format (including headers and statement details) and deserializes them back, ensuring source paths are resolved relative to a specified root. Tests confirm that coverage data can be round-tripped through this plain-text representation.

serializer · high confidence

New scoverage reporter module with HTML, XML, and Cobertura output support

The reporter module now provides a complete set of code coverage report writers. Users can generate HTML reports with syntax highlighting and package navigation, standard scoverage XML reports (including debug variants), Cobertura-compatible XML reports with relative source paths, and aggregated coverage data for multi-module projects. The implementation includes utilities for file I/O, encoding handling, and path resolution to ensure reports are generated correctly across different environments.

reporter/src/main · high confidence

Removals

Removal of ScctProject trait from sbt-scct plugin

The \ScctProject\ trait, which previously provided the core integration for code coverage within sbt projects, has been removed from the \sbt-scct\ plugin. This deletion eliminates the built-in mechanism for instrumenting compilation and running coverage tests via the \ScctProject\ mixin, effectively stripping the plugin of its primary functionality in this location.

sbt-scct · high confidence

Removal of legacy HTML coverage report generation

The HTML-based coverage reporting functionality has been removed from the scct report module. This change deletes the \CoverageData\ model, the \HtmlReportWriter\ utility, the \HtmlReporter\ orchestrator, the \SourceFileHtmlReporter\ for rendering source code with coverage highlighting, and the \SourceLoader\ for reading source files. Users will no longer be able to generate HTML coverage reports using this component.

scct/src/main/scala/reaktor/scct/report · high confidence

Removal of legacy HTML reporting assets

The legacy HTML reporting assets, including the JavaScript logic for package list interactions, the CSS styling, and the HTML template, have been removed from the project. This change eliminates the old reporting mechanism that relied on these specific static resources.

scct/src/main/resources · high confidence

Behavioural changes

Improved thread-safety and multi-module support for coverage data collection

The runtime now uses a platform-agnostic abstraction for file operations and thread-safe maps, ensuring that the \Invoker.invoked\ method correctly handles concurrent access from multiple threads without corrupting measurement files. Additionally, the implementation supports multi-module projects by allowing measurement data to be written to and read from separate directories, with each thread writing to its own file to reduce contention.

runtime/jvm, runtime/shared · high confidence

New domain model for coverage data and metrics

The domain module now introduces a structured domain model for coverage data, including core classes like Statement, Location, and Coverage, along with builders for organizing data by method, class, package, and file. It also adds a CodeGrid component that generates HTML-highlighted source code views with color-coded coverage status (invoked, not invoked, no data) and defines constants for file naming and data formats. This refactoring establishes the foundational data structures and reporting capabilities for incremental coverage support.

domain · high confidence

Refactor coverage plugin into modular components with incremental support

The scoverage plugin has been restructured to decouple measurement and data directories, allowing measurement files to be written to a separate location from the final coverage report. This change introduces incremental coverage support by merging previous coverage data with current instrumentation results, ensuring that coverage statistics persist across compilation cycles. The plugin's internal logic is now organized into distinct modules for filtering, merging, and location tracking, improving maintainability and enabling more precise control over which classes, files, and symbols are included in coverage reports.

plugin/src/main · high confidence

Removal of legacy ScctBuild build definition

The legacy ScctBuild.scala file, which defined the Scct project and its sbt plugin dependencies (including JUnit, ScalaTest, Mockito, ScalaCheck, and Specs) for Scala 2.7.7, has been removed from the project structure. This change reflects a shift away from the older build configuration, likely to accommodate the transition to Scala 2.8 and separate project concerns as indicated by the commit history.

project/build · medium confidence

Removal of legacy sbt-idea-plugin and project structure

The legacy sbt plugin definition file (project/plugins/Plugins.scala) has been removed, eliminating the dependency on the sbt-idea-plugin (version 0.1-SNAPSHOT) and the associated GH-pages repository configuration. This change simplifies the build configuration by discarding the older plugin management approach.

project/plugins · high confidence

Rewritten Scala code coverage instrumentation plugin

The scct coverage tool has been significantly refactored to improve constructor instrumentation accuracy and support newer Scala versions (2.8 and 2.9). The old file-based binary serialization (MetadataPickler/IO) was removed in favor of loading coverage data from the classpath and using relative file paths for reports. The instrumentation plugin itself was rewritten to better handle curried constructors, lazy definitions, and generated code, ensuring more reliable coverage data collection during test execution.

scct/src/main/scala/reaktor/scct · high confidence

Test coverage

Added JSDOM test coverage for multi-module invoker; Added tests for reporter components; Expanded test coverage for scoverage plugin instrumentation and filtering; Removed legacy Scala code coverage instrumentation tests; Removed obsolete unit tests for coverage data and HTML reporting.

Dependencies

Add jsdom dependency for Scala.js JSDOM test environment

The project now includes a Node.js dependency on jsdom (version 30.0.1) via package.json and package-lock.json. This supports the new \runtimeJSDOMTest\ subproject defined in build.sbt, which configures the Scala.js test runner to use \JSDOMNodeJSEnv\ for executing tests in a JSDOM-based environment.

(dependencies) · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Baseline

  • First survey — no prior run to compare against. CAI 67.

Lenses

  • Code Health 93
  • Architecture 100
  • Maturity 49
  • Readiness 74
  • Security 83
  • Domain Modelling 100

Changes since last survey

  • 300 commits — 283 feature/other, 17 fixes

By area

  • (root) — 144 commits
  • project/plugins.sbt — 75 commits
  • .github/workflows — 24 commits
  • project/build.properties — 22 commits
  • plugin/src — 12 commits
  • scalac-scoverage-plugin/src — 11 commits
  • reporter/src — 5 commits
  • bin/test-release.sh — 3 commits
  • .github/dependabot.yml — 2 commits
  • .github/ISSUE_TEMPLATE — 1 commit
  • scalac-scoverage-runtime/js — 1 commit

Notable commits

  • fix: Bug Fix: sbt-coveralls: Issue 199: Use relative paths in cobertura.xml file (#497)
  • fix: Enabled CI on Windows and applied some fixes (#375)
  • fix: Fix Cobertura unit test (#510)
  • fix: Fix link for scala 2.12.14 (#349)
  • fix: Fix release script now that runtime isn't fully cross published (#330)
  • fix: Fix warning (#785)
  • fix: Fixed #183: JSDOMNodeJSEnv is handled incorrectly (Scalajs support issue) (#212)
  • fix: Publish native runtime, fix JSDOM CI setup... (#471)
  • fix: Re-enable PluginCoverageScalaJsTest, fix dangling UndefinedParam bug (#464)
  • fix: Various fixes for config and encoding. (#400)
  • fix: bugfix: scoverage does not instrument pat-mat assignment properly (#731)
  • fix: fix: Some more small fixes on relative paths in the writers (#403)
  • fix: fix: ensure packages are excluded correctly and add tests (#414)
  • fix: fix: ensure passed in encoding is being used and make some things private (#418)
  • fix: fix: ignore lazy definition generated from by-name implicits (#536)
  • fix: fix: setup-java name correction (#407)
  • fix: fix: stick to scala-xml 1.x for 2.12 to align with the compiler. (#411)
  • change: Add 2.13.6 into ci matrix (#342)
  • change: Add Java 17 to the matrix and align javas (#398)
  • change: Add V2 into branch conditions to ensure it builds on merge (#391)
  • …and 280 more

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

scoverage/scalac-scoverage-plugin was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 20 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit b5935ab7f45db487a5dcf53d9dacb3c02db53e3c — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-b51f968c9b10.