SSh
03/01/2024, 2:29 PMeachKeyMatches
and eachValueMatches
simultaneously)
I need something like eachKeyValueMatches
but it doesn't exist
Example
enum Keys {
One = "One",
Two = "Two",
}
interface Value {
min: number
max: number
}
type R = Record<Keys, Value>
const record: R = {
[Keys.One]:
{
min: 1,
max: 2
}
}
it("check record", async () => {
messagePact
.expectsToReceive("record")
.withContent({
// What need to write here to check type R ?
})
})
Matt (pactflow.io / pact-js / pact-go)
rholshausen
03/05/2024, 10:19 PMMatt (pactflow.io / pact-js / pact-go)
rholshausen
03/05/2024, 11:56 PMrholshausen
03/05/2024, 11:57 PMMatt (pactflow.io / pact-js / pact-go)
Matt (pactflow.io / pact-js / pact-go)