disneystreaming/weaver-test

Triple equals does not work with Scala 3

Closed this issue · 4 comments

The following compiles in Scala 2.13:

import cats.syntax.all._
expect(0 === 0)

The equivalent of it does not compile in Scala 3:

import cats.syntax.all.given
expect(0 === 0)
// Found:    cats.syntax.EqOps[Int]
// Required: (implicit evidence$2: cats.kernel.Eq[Int]): cats.syntax.EqOps[Int]

Here's a reproducible example in Scala 2.13 and 3.0.0. This is based off weaver-test v0.73.

Ironically, I've just hit this problem in another project :)

Seems like it's a problem in expecty (hopefully not in Scala3)

https://scastie.scala-lang.org/oS3IvTm8RLCaFxII64wkbw

I've reported it on Expecty and will look at fixing it

Closing the issue since it's a problem with expecty and not weaver-test. Looking forward to the fix!

@qwbarch

Weaver 0.6.4 / 0.7.4 is out with the fix - putting your reproduction into Scastie with this version seems to compile fine: https://scastie.scala-lang.org/ETU7sQvXSZGjfkf3gbwyyw

Let me know if 0.7.4 fixes it for you :)

0.7.4 fixes it, thanks so much! 🎉