kotest-assertions-core / io.kotest.matchers.doubles / beNaN

beNaN

fun beNaN(): Matcher<Double>

Matcher that matches Double.NaN

Verifies that a specific Double is the Not-a-Number constant Double.NaN

0.5 should beNaN()            // Assertion fails
Double.NaN should beNaN()     // Assertion passes

See Also

Double.shouldBeNaN

Double.shouldNotBeNaN