Skip to content

lefou/mill-jacoco

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

73 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mill-jacoco - Coverage Reporting for Mill

Mill plugin to collect test coverage data with JaCoCo and generate reports.

Quickstart

You need at least Mill 0.9.7 to use mill-jacoco.

To enable coverage data generation with JaCoCo, you need to add the JacocoTestModule to your tests.

import mill._
import mill.scalalib._
import mill.define._

// Load the plugin from Maven Central via ivy/coursier
import $ivy.`de.tototec::de.tobiasroeser.mill.jacoco::0.0.4`
import de.tobiasroeser.mill.jacoco.JacocoTestModule

object main extends JavaModule {
  object test extends super.Tests with JacocoTestModule
}

To generate JaCoCo reports, run:

mill de.tobiasroeser.mill.jacoco.Jacoco/jacocoReportFull

Download

You can download binary releases from Maven Central.

Please make sure to use the correct mill platform suffix matching your used mill version.

License

This project is published under the Apache License, Version 2.0.

About

mill

Mill is a Scala-based open source build tool. In my opinion the best build tool for the JVM. It is fast, reliable and easy to understand.

me

I’m a professional software developer and love to write and use open source software. I’m actively developing and maintaining mill as well as several mill plugins.

If you like my work, please star it on GitHub. You can also support me via GitHub Sponsors.

Contributing

If you found a bug or have a feature request, please open a new issue on GitHub. I also accept pull requests on GitHub.

Releases / Changelog

0.0.4 - 2024-02-06

  • Better detect Mill test modules to exclude their files / classes from coverage reports. Requires at least Mill 0.11.7.

0.0.3 - 2023-06-24

  • Support for Mill 0.11

  • Dependency updates

0.0.2 - 2022-04-12

  • Support for Mill 0.10

0.0.1 - 2021-10-16

  • Initial Release