var x: String? = "hello"
x shouldNotBe null
x!!.substring(2) shouldBe "he" // !! should not be necessary, since previous assertion checks that it is not null
m
Mervyn McCreight
11/04/2021, 10:02 AM
I think there is a
x.shouldNotBeNull()
in place that does what you are searching for 🙂
e
Emil Kantis
11/04/2021, 10:05 AM
Ahh.. of course.. for some reason I looked for it with a space after