I've run into the first situation where I would like to write a test that only checks some aspect of an argument (that it's in a certain range, for example) and not for equality with a certain value. It would be great if we could start thinking about how to specify matchers.
Maybe something like:
// specifies a matcher for each argument
`EXPECT_CALL(mock, some_func).with_arg_matchers(matcher0, matcher1)
We could implement something like a "don't care" matcher (equivalent to GMock's "_"), but the syntax will be very verbose (unless we trade off compile time safety), due to the lack of parameter inference/function overloading.
I've run into the first situation where I would like to write a test that only checks some aspect of an argument (that it's in a certain range, for example) and not for equality with a certain value. It would be great if we could start thinking about how to specify matchers.
Maybe something like:
We could implement something like a "don't care" matcher (equivalent to GMock's "_"), but the syntax will be very verbose (unless we trade off compile time safety), due to the lack of parameter inference/function overloading.