Skip to content

Commit

Permalink
Make UtilitiesTest work under scala 3 expect implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
dimitarg committed Oct 30, 2024
1 parent 3d7a76b commit 9690e1b
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/test/scala/weaver/pure/UtilitiesTest.scala
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,14 @@ import util._
object UtilitiesTest extends Suite {

override def suitesStream: Stream[IO, Test] = Stream(
pureTest("outcomeToString") {
pureTest("outcomeToString contains source location and assertion failure body") {

val test = Test("some test", expect(1 === 2))
val asString = outcomeToString(toTestOutcome(test))
val testOutcome = toTestOutcome(test)
val asString = outcomeToString(testOutcome)

expect(asString.contains("UtilitiesTest.scala")) and
expect(asString.contains("expect(1 === 2)"))
expect(asString.contains("1 === 2"))

}
)
Expand Down

0 comments on commit 9690e1b

Please sign in to comment.