Kirill Zhukov
05/01/2024, 5:09 PMKirill Zhukov
05/01/2024, 5:10 PMKirill Zhukov
05/01/2024, 5:11 PMrequestMessage.shouldBeEqual
based on an implementation change, but the stacktrace doesn't include the actual call where the assertion failed, why?Kirill Zhukov
05/01/2024, 5:11 PMCLOVIS
05/01/2024, 8:03 PMKirill Zhukov
05/01/2024, 8:53 PMrequestMessage.shouldBeEqual("...")
Is the failing assertion, requestMessage
is a String.
Or are you saying that's just how all kotest failure look like because test
are using coroutines?sam
05/02/2024, 4:10 AMKlitos Kyriacou
05/02/2024, 8:32 AMtoString()
method that turns HttpMethod(value=POST)
into just "POST"
. That seems to be the only difference. By the way, what is shouldBeEqual
? It doesn't seem to be part of Kotest.Kirill Zhukov
05/02/2024, 4:38 PMshouldBeEqual
is a kotest matcherKirill Zhukov
05/02/2024, 4:39 PMrequestMessage
is a String
, so I'm basically doing someString.shouldBeEqual(otherString)
Klitos Kyriacou
05/02/2024, 4:55 PMshouldBeEqualComparingTo
) and I've always tested for equality using the shorter name shouldBe
. Also, it sounds ungrammatical: "a shouldBeEqual b" doesn't sound like proper English; it should be either "a shouldEqual b" or "a shouldBeEqualTo b".sam
05/03/2024, 5:25 AMsam
05/03/2024, 5:25 AMKirill Zhukov
05/03/2024, 5:25 PMCLOVIS
05/03/2024, 5:29 PMtry {
...
} catch (e: Exception) {
throw RuntimeException("Spied exception", e)
}
it'll ensure that at least that specific place appears in the stacktrace.CLOVIS
05/03/2024, 5:29 PM-ea
though, it shouldn't be too hard