Skip to content

Commit

Permalink
Fix test impl atomic on JS (#2455)
Browse files Browse the repository at this point in the history
  • Loading branch information
nomisRev authored Jul 26, 2021
1 parent 3a5ad95 commit d0198d1
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,12 @@ class AtomicTest : ArrowFxSpec(
}

"access - setter should fail if value is modified before setter is called" {
checkAll(Arb.int(), Arb.int(), Arb.int()) { x, y, z ->
checkAll(Arb.int(), Arb.int()) { x, z ->
val ref = Atomic(x)
val (_, setter) = ref.access()
ref.set(y)
ref.update { it + 1 }
setter(z) shouldBe false
ref.get() shouldBe y
ref.get() shouldBe x + 1
}
}

Expand Down

0 comments on commit d0198d1

Please sign in to comment.