specs2

Software Specifications for Scala

OTHER License

Stars
734
Committers
88

Bot releases are visible (Hide)

specs2 - Maintenance release

Published by etorreborre over 2 years ago

  • fix: do not show a timeout exception as skipped
  • fix: #1067 remove a bad trailing comma to fix the community build
  • fix: #1069 fix the navigation of json strings with matchers
  • fix: fixed some infinitely recursive extension methods (~ and ~/ in mutable specs) and ns.updateHead in org.specs2.html.Htmlx
specs2 - Cross versions - new strategy

Published by etorreborre over 2 years ago

This release changes a bit the strategy for using specs2 versions across Scala versions (from what is described here).

There is now:

  1. a full version of specs2, 4.15.0, for Scala2 (2.12 and 2.13) with all the usual features, developed from the specs2-4.x-maintenance branch

  2. a version of specs2, 4.15.0, for Scala3 based on limited features (read about the limitations here) but mostly compatible with the specs2 source code used with Scala 2. That version comes from the specs2-cross branch.

  3. a full version of specs2, 5.0.0, for Scala3 (developed on the main branch). That version is not backward compatible with other 4.x versions

The idea is that:

  • if you want to stay on Scala2 with no intent yet of migrating to Scala3, you can use a version >= 4.15 && < 5

  • if you want to cross-compile for Scala2 and Scala3, you can use a version >= 4.15 && < 5, but you might have to do some small changes to your source code (or have less features like auto-examples)

  • if you want to only use Scala 3 you can use versions >= 5

This is a delicate setup but I hope it will help you migrate gradually to Scala 3. Please don't hesitate to ask questions if you have any issue migrating your code.

Note: you can ignore the 4.13.1-cross artefact

specs2 - specs2 version cross compiled for Scala 2.12, 2.13 and 3.1

Published by etorreborre over 2 years ago

This version of specs2 provides an interim support for Scala 2.12, 2.13 and 3.1.

In order to be compatible with all Scala versions some features had to be removed (like macro-based features) and you might have to adapt your code. For example:

  • auto examples don't work anymore with immutable specifications
  • expectations must be expressed as value must matcher or value must not(matcher), and avoid expressions like a must not be something. This is in line with the new specs2 5.x version
  • type inference with some matchers (like beLike or contain) might require some type annotations
  • implicit resolution can have some slight differences in behaviour (and produce different failure messages for matchers for example)
  • specs2-mock has been removed (you need to use ScalaMock instead)
  • the around function (and corresponding trait) which is using the now deprecated DelayedInit feature is not working anymore

This version is provided as a best effort for bridging the gap between Scala 2 and Scala 3 but it is recommended that you switch to a specs2 5.x version (only available for Scala 3) if you can because this will be the actively maintained version.

Thanks for reporting any issue with this version, I will try to address it if it is blocking your migration process.

specs2 - Maintenance release

Published by etorreborre almost 3 years ago

Fixed #1048 (threads leak) which was a regression introduced by #1027 ("threadsNb has no effect")

specs2 - Fixed the indentation in the user guide

Published by etorreborre about 3 years ago

This was broken because of scalafmt

specs2 - Maintenance release

Published by etorreborre about 3 years ago

  • Made ExecutionEnv consistent across JVM and JS (thanks to @armanbilge)
  • put more modules under JS compilation
specs2 - Added back the Before/After All traits

Published by etorreborre about 3 years ago

for better backward compatibility

specs2 - Fixes a regression with PendingUntilFixed (see #987)

Published by etorreborre about 3 years ago

specs2 - Integration of the MacrotaskExecutor for ScalaJS

Published by etorreborre about 3 years ago

This version uses a new ExecutionContext which makes timeouts works with ScalaJS. For more details have a look at this ScalaJS issue.

specs2 - Fix for #984

Published by etorreborre about 3 years ago

This release fixes an oddity with the implicits used for the >> operator which seemed to be creating a closure capturing a variable once and never re-evaluating it.

specs2 - Blocker fix

Published by etorreborre about 3 years ago

The previous version (4.12.7) introduced a regression seemingly due to a compiler bug when emitting implicits code.

specs2 - Maintenance release

Published by etorreborre about 3 years ago

Fixed #981 where an exception thrown outside of an Execution could fail the whole specification instantiation.

specs2 - Revert scala-parsers-combinators to 1.1.2

Published by etorreborre about 3 years ago

For better compatibility. Fixes https://github.com/etorreborre/specs2/issues/980

specs2 - Junit5 version

Published by etorreborre about 3 years ago

Now with executing tests :-)

specs2 - Revert scala-xml to 1.3.0

Published by etorreborre about 3 years ago

After a bit of back and forth, we decided that it was better to keep scala-xml-1.x for the specs2-4.x series and scala-xml-2.x for the specs2-5.x series. Sorry about the possible confusing from reading those consecutive releases!

specs2 - specs2 5.0.0 RC3

Published by etorreborre about 3 years ago

Made adjustments to diffs and failure messages

specs2 - Maintenance release

Published by etorreborre about 3 years ago

Upgraded scala-xml to 2.0.1 and moved the XmlMatchers to the specs2-xml module (instead of specs2-matcher-extra) to avoid conflicts with the scala-compiler library.

Note: the jars released under the version 4.12.4-ec-js must not be used, they were published as a proof of concept to test a ScalaJs related issue.

specs2 - specs2 5.0.0 RC2

Published by etorreborre about 3 years ago

This release adds generic diffs for case classes:

// setup
case class Foo(x: String, y: Int)
val foo1 = Foo("a", 1)
val foo2 = Foo("b", 2)

// test
foo1 === foo2

// result
Foo(x: 'a' != 'b'
       y: 1 != 2)
specs2 - Release Candidate for specs2 5.0.0 on Scala3!

Published by etorreborre about 3 years ago

This blog post describes the context for this new release. Some more or less experimental features are gone, some functionalities (mocks, cats, scalaz) have moved to other libraries and some features still need to be implemented before the final version

specs2 - Maintenance release

Published by etorreborre over 3 years ago

This release updates a few dependencies and properly escapes the ex option when it is not a regular expression.