2 ms·
One advantage of Catch is that you can use native C++ expressions in your assertions, so instead of AssertThat(guitar->sound(), Equals(sounds::clean)); you
by tveita 12y ago
One advantage of Catch is that you can use native C++ expressions in your assertions, so instead of
AssertThat(guitar->sound(), Equals(sounds::clean));
you can write
CHECK(guitar->sound() == sounds::clean);
And you'll still get sensible output when it fails, showing the expression and the result of guitar->sound().
- banachtarski 12y agoThis isn't so much an advantage as a preference. See https://github.com/joakimkarlsson/snowhouse#assertions https://github.com/joakimkarlsson/snowhouse#assertions