Open Emoun opened 3 years ago
The trybuild
crate has just rejected a feature request that is essential for duplicate
(dtolnay/trybuild#108), making it all the more useful if macrotest
could provide a more fully featured alternative to trybuild
.
@Emoun, on it
Hi,
I want to ask whether you would consider implementing what
trybuild
essentially does, I.e. allowing us to check that a compilation fails with a given error message?The reason I ask is that I'm in need of the functionality that
trybuild
provides, however it is missing essential features thatmacrotest
has. Most essential is the fact that it doesn't seem to panic upon wrong test results, which is a deal-breaker for me. Also, features that have been implemented inmacrotest
are also missing (#41,#43). Additionally, it seems silly to me that I would need to use two different crates for two functions that are so similar.Essentially what I would need is
expand_fail
versions ofexpand
andexpand_without_refresh
, that expects the expansion to fail and then checks the error message is as expected. If the expansion doesn't fail, or the error message is wrong, the test is a failure.