Skip to content

Commit

Permalink
Explicit generators to help JS property test suite.
Browse files Browse the repository at this point in the history
  • Loading branch information
Mikael Vejdemo-Johansson committed Nov 22, 2023
1 parent 246427d commit 7fc7c4e
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/commonTest/kotlin/org/appliedtopology/tda4j/SetSpec.kt
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ import io.kotest.matchers.booleans.shouldBeFalse
import io.kotest.matchers.booleans.shouldBeTrue
import io.kotest.matchers.collections.shouldBeSorted
import io.kotest.matchers.collections.shouldContainExactly
import io.kotest.property.Arb
import io.kotest.property.arbitrary.int
import io.kotest.property.arbitrary.list
import io.kotest.property.assume
import io.kotest.property.checkAll

Expand All @@ -28,7 +31,7 @@ class SetSpec : StringSpec({
}

"MutableSortedSet capabilities" {
checkAll<List<Int>> {
checkAll(Arb.list(Arb.int(-1024, 1024), 0..500)) {
val set = MutableSortedSet<Int>(it.size)
withClue("MutableSortedSet has everything we insert") {
set.addAll(it)
Expand Down

0 comments on commit 7fc7c4e

Please sign in to comment.