Skip to content

Commit

Permalink
Update ShortCircuitingFailure.scala
Browse files Browse the repository at this point in the history
  • Loading branch information
Bruce Eckel committed Jul 22, 2024
1 parent 81334bb commit 652f18c
Showing 1 changed file with 21 additions and 21 deletions.
42 changes: 21 additions & 21 deletions src/test/scala/experiments/ShortCircuitingFailure.scala
Original file line number Diff line number Diff line change
Expand Up @@ -35,24 +35,24 @@ object ShortCircuitingFailure1 extends ZIOAppDefault:

//----------------------------------------------

import zio.test.*

object ShortCircuitingFailure2 extends ZIOSpecDefault:
def spec =
suite("Suite of Tests")(
test("one"):
defer:
val result = shortCircuiting(1).flip.run
assertTrue(result == "Failed at 1")
,
test("two"):
defer:
val result = shortCircuiting(2).flip.run
assertTrue(result == "Failed at 2")
,
test("three"):
defer:
val result = shortCircuiting(3).run
assertTrue(result == "Passed all steps")
,
) @@ TestAspect.sequential
//import zio.test.*
//
//object ShortCircuitingFailure2 extends ZIOSpecDefault:
// def spec =
// suite("Suite of Tests")(
// test("one"):
// defer:
// val result = shortCircuiting(1).flip.run
// assertTrue(result == "Failed at 1")
// ,
// test("two"):
// defer:
// val result = shortCircuiting(2).flip.run
// assertTrue(result == "Failed at 2")
// ,
// test("three"):
// defer:
// val result = shortCircuiting(3).run
// assertTrue(result == "Passed all steps")
// ,
// ) @@ TestAspect.sequential

0 comments on commit 652f18c

Please sign in to comment.