Closed ddsjoberg closed 2 months ago
I think it is not possible to avoid using snapshots for errors. With expect_error
, you can grep the error message or just expect an error. If it is an error from another package, I argue we do not care too much about its form as far as it is happening. I would use only expect_error
When we process selectors we have an error message that wraps the
dplyr::select()
error message. But we don't want a change in another package's error message to "break" cards (and more likely cardx).In this example from cards, we have different messaging from dplyr v1.1.4 to v1.1.3. (The word 'subset' was changed to 'select'.)
How best to test messaging, but also not rely on small messaging changes in another package? 🤔