Skip to content

Releases: scalameta/munit

v1.0.0-M9

14 Sep 14:31
Compare
Choose a tag to compare

Notable Changes

  • Fix Async tests on Scala Native #693
  • Fail test suites on fatal exceptions #669

All Changes

New Contributors

Full Changelog: v1.0.0-M8...v1.0.0-M9

v1.0.0-M8

09 Jun 12:50
854b849
Compare
Choose a tag to compare

Notable Changes

  • Handle a StackOverflowError in addition to NonFatal errors in #648
  • Use js-native folder by sbt-crossproject in #646
  • Make Printer more easily configurable in #640
  • Fix assume(false) handling in #629

All Changes

New Contributors

Full Changelog: v1.0.0-M7...v1.0.0-M8

v1.0.0-M7

18 Nov 02:10
33ab4e8
Compare
Choose a tag to compare

Notable Changes

  • Better messaging for reproducing failures in scalacheck #564
  • Improved handling ignored tests in Gradle #601
  • Fixed non-termination in scala-cli #606

All Changes

New Contributors

Full Changelog: v1.0.0-M6...v1.0.0-M7

v1.0.0-M6

11 Nov 11:43
3da0417
Compare
Choose a tag to compare

What's Changed

Full Changelog: v1.0.0-M5...v1.0.0-M6

v1.0.0-M5

11 Nov 11:41
64fee65
Compare
Choose a tag to compare

What's Changed

Full Changelog: v1.0.0-M4...v1.0.0-M5

v1.0.0-M4

11 Nov 11:40
bd86dfa
Compare
Choose a tag to compare

What's Changed

Full Changelog: v1.0.0-M3...v1.0.0-M4

v1.0.0-M3

11 Nov 11:40
4fae043
Compare
Choose a tag to compare

What's Changed

  • feat: take into account TaskDefs with only TestSelectors. by @kpodsiad in #501

Full Changelog: v1.0.0-M2...v1.0.0-M3

v1.0.0-M2

11 Nov 11:39
aa30ff9
Compare
Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v1.0.0-M1...v1.0.0-M2

MUnit v1.0.0-M1

16 Oct 10:39
bb1759a
Compare
Choose a tag to compare

First milestone towards MUnit v1.0

This is the first milestone towards releasing MUnit v1.0. The goal of MUnit v1.0 is to fix a few long-standing quirks of the MUnit API that require breaking changes. Check out https://github.com/scalameta/munit/milestone/1 for an overview on what issues are blocking a stable v1.0.0 release (non-milestone).

Fixtures can now be implemented as a toplevel class

Previously, it was only possible to implement Fixture[T] with inner classes inside FunSuite. Now, it's possible to implement fixtures with toplevel classes outside of FunSuite.

Fixture lifecycle methods can now return Future[Unit]

Previously, Fixture[T] only support synchronous lifecycle methods (beforeAll, beforeEach, afterEach and afterAll). On the JVM it was possible to use blocking I/O to work around this limitation if you had async fixtures but that was not possible in Scala.js. Now, there is a new munit.FutureFixture[T], which supports returning Future[Unit] from the lifecycle methods. It's also possible to implement fixtures with a custom effect type (like Cats Resource), see https://scalameta.org/munit/docs/fixtures.html#asynchronous-fixtures-with-custom-effect-type.

⚠️ Breaking changes

This release contains binary breaking changes that require 3rdparty integrations (cats-effect, testcontainers) to recompile their source code. We tried to preserve source compatibility as much as possible by using type aliases.

  • munit.GenericTest[T] has been replaced with munit.Test. There is a deprecated munit.GenericTest type alias in the package object to preserve source compatibility.
  • munit.GenericBeforeEach[T] has been replaced with munit.BeforeEach. There is a deprecated munit.GenericBeforeEach type alias in the package object to preserve source compatibility.
  • munit.GenericAfterEach[T] has been replaced with munit.AfterEach. There is a deprecated munit.GenericAfterEach type alias in the package object to preserve source compatibility.
  • munit.FunSuite.Fixture is no longer an inner class, it's now a toplevel munit.Fixture class. There is a munit.FunSuite.Fixture type alias for source compatibility. This alias is not deprecated since it's convenient to not have to explicitly import munit.Fixture inside the body of a FunSuite class.
  • munit.FunSuite is now an empty abstract class that extends a new trait munit.BaseFunSuite, which includes all the
  • The method munit.Test.withBodyMap() no longer has a type parameter. It's OK to just remove the type parameter, it's no longer used.
  • The FunSuite.{afterEach,afterAll} methods are now evaluated before custom fixtures instead of after custom fixtures. The ordering for beforeAll and beforeEach is unchanged. The diff below demonstrates an example, assuming you have a fixture named myFixture and a test suite named MySuite. In other words, FunSuite.{before*,after*} methods are now evaluated as a regular Fixture[T] that's always the first element of munitFixtures: Seq[Fixture[_]].
-- old order
++ new order
  MySuite.beforeAll()
  myFixture.beforeAll()
  MySuite.beforeEach(test-1)
  myFixture.beforeEach(test-1)
+ MySuite.afterEach(test-1)
  myFixture.afterEach(test-1)
- MySuite.afterEach(test-1)
+ MySuite.afterAll()
  myFixture.afterAll()
- MySuite.afterAll()

⚠️ Expect a few more milestone releases with a few more binary breaking changes

We're planning a few minor breaking changes before releasing a stable v1.0.0. Please keep this in mind if you're the maintainer of a 3rdparty integration. We will try to not stay in this milestone for too long.

Merged pull requests

New Contributors

Full Changelog: v0.7.29...v1.0.0-M1

MUnit v0.7.29

31 Aug 18:49
92f3ad9
Compare
Choose a tag to compare

Fix regression that caused console test reports to get lost

The previous release v0.7.28 introduced a regression where console test reports would occasionally get lost, see #408. This regression should be fixed in this release.

Pull Requests