Releases: catchorg/Catch2
Releases · catchorg/Catch2
v2.11.0
Improvements
- JUnit reporter output now contains more details in case of failure (#1347, #1719)
- Added SonarQube Test Data reporter (#1738)
- It is in a separate header, just like the TAP, Automake, and TeamCity reporters
rangegenerator now allows floating point numbers (#1776)- Reworked part of internals to increase throughput
Fixes
v2.10.2
Improvements
- Catch2 will now compile on platform where
INFINITYis double (#1782)
Fixes
- Warning suppressed during listener registration will no longer leak
Miscellaneous
- From this release forward released headers could be signed also by
- KeyID
81E7 0B71 7FFB 27AF DB45 F520 90BB FF12 0F9C 087B
- KeyID
v2.10.1
Improvements
- Catch2 now guards itself against
minandmaxmacros fromwindows.h(#1772) - Templated tests will now compile with ICC (#1748)
WithinULPmatcher now uses scientific notation for stringification (#1760)
Fixes
- Templated tests no longer trigger
-Wunused-templates(#1762) - Suppressed clang-analyzer false positive in context getter (#1230, #1735)
Miscellaneous
v2.10.0
Fixes
TEMPLATE_LIST_TEST_CASEnow properly handles non-copyable and non-movable types (#1729)- Fixed compilation error on Solaris caused by a system header defining macro
TT(#1722, #1723) REGISTER_ENUMwill now fail at compilation time if the registered enum is too large- Removed use of
std::is_same_vin C++17 mode (#1757) - Fixed parsing of escaped special characters when reading test specs from a file (#1767, #1769)
Improvements
- Trailing and leading whitespace in test/section specs are now ignored.
- Writing to Android debug log now uses
__android_log_writeinstead of__android_log_print - Android logging support can now be turned on/off at compile time (#1743)
- The toggle is
CATCH_CONFIG_ANDROID_LOGWRITE
- The toggle is
- Added a generator that returns elements of a range
- Use via
from_range(from, to)orfrom_range(container)
- Use via
- Added support for CRTs that do not provide
std::nextafter(#1739)- They must still provide global
nextafter{f,l,} - Enabled via
CATCH_CONFIG_GLOBAL_NEXTAFTER
- They must still provide global
- Special cased
Approx(inf)not to match non-infinite values- Very strictly speaking this might be a breaking change, but it should match user expectations better
- The output of benchmarking through the Console reporter when
--benchmark-no-analysisis set is now much simpler (#1768) - Added a matcher that can be used for checking an exceptions message (#1649, #1728)
- The matcher helper function is called
Message - The exception must publicly derive from
std::exception - The matching is done exactly, including case and whitespace
- The matcher helper function is called
- Added a matcher that can be used for checking relative equality of floating point numbers (#1746)
- Unlike
Approx, it considers both sides when determining the allowed margin - Special cases
NaNandINFINITYto match user expectations - The matcher helper function is called
WithinRel
- Unlike
- The ULP matcher now allows for any possible distance between the two numbers
- The random number generators now use Catch-global instance of RNG (#1734, #1736)
- This means that nested random number generators actually generate different numbers
Miscellaneous
- In-repo PNGs have been optimized to lower overhead of using Catch2 via git clone
- Catch2 now uses its own implementation of the URBG concept
- In the future we also plan to use our own implementation of the distributions from
<random>to provide cross-platform repeatability of random results
- In the future we also plan to use our own implementation of the distributions from
v2.9.2
Fixes
ChunkGeneratorcan now be used with chunks of size 0 (#1671)- Nested subsections are now run properly when specific section is run via the
-cargument (#1670, #1673) - Catch2 now consistently uses
_WIN32to detect Windows platform (#1676) TEMPLATE_LIST_TEST_CASEnow support non-default constructible type lists (#1697)- Fixed a crash in the XMLReporter when a benchmark throws exception during warmup (#1706)
- Fixed a possible infinite loop in CompactReporter (#1715)
- Fixed
-w NoTestsreturning 0 even when no tests were matched (#1449, #1683, #1684) - Fixed matcher compilation under Obj-C++ (#1661)
Improvements
RepeatGeneratorandFixedValuesGeneratornow fail to compile when used withbool(#1692)- Previously they would fail at runtime.
- Catch2 now supports Android's debug logging for its debug output (#1710)
- Catch2 now detects and configures itself for the RTX platform (#1693)
- You still need to pass
--benchmark-no-analysisif you are using benchmarking under RTX
- You still need to pass
- Removed a "storage class is not first" warning when compiling Catch2 with PGI compiler (#1717)
Miscellaneous
- Documentation now contains indication when a specific feature was introduced (#1695)
- These start with Catch2 v2.3.0, (a bit over a year ago).
docs/contributing.mdhas been updated to provide contributors guidance on how to add these to newly written documentation
- Various other documentation improvements
- ToC fixes
- Documented
--orderand--rng-seedcommand line options - Benchmarking documentation now clearly states that it requires opt-in
- Documented
CATCH_CONFIG_CPP17_OPTIONALandCATCH_CONFIG_CPP17_BYTEmacros - Properly documented built-in vector matchers
- Improved
*_THROWS_MATCHESdocumentation a bit
- CMake config file is now arch-independent even if
CMAKE_SIZEOF_VOID_Pis in CMake cache (#1660) CatchAddTestsnow properly escapes[and]in test names (#1634, #1698)- Reverted
CatchAddTestsadding tags as CTest labels (#1658)- The script broke when test names were too long
- Overwriting
LABELScaused trouble for users who set them manually - CMake does not let users append to
LABELSif the test name has spaces
v2.9.1
v2.9.0
This release replaces the old benchmarking support with a new one, based on donated Nonius code. It should be considered working, but the integration interface might change based on feedback we receive.
Improvements
- The experimental benchmarking support has been replaced by integrating Nonius code (#1616)
- This provides a much more featurefull micro-benchmarking support.
- Due to the compilation cost, it is disabled by default. See the documentation for details.
- As far as backwards compatibility is concerned, this feature is still considered experimental in that we might change the interface based on user feedback.
WithinULPmatcher now shows the acceptable range (#1581)- Template test cases now support type lists (#1627)
v2.8.0
Improvements
- Templated test cases no longer check whether the provided types are unique (#1628)
- This allows you to e.g. test over
uint32_t,uint64_t, andsize_twithout compilation failing
- This allows you to e.g. test over
- The precision of floating point stringification can be modified by user (#1612, #1614)
- We now provide
REGISTER_ENUMconvenience macro for generatingStringMakerspecializations for enums- See the "String conversion" documentation for details
- Added new set of macros for template test cases that enables the use of NTTPs (#1531, #1609)
- See "Test cases and sections" documentation for details
Fixes
UNSCOPED_INFOmacro now has a prefixed/disabled/prefixed+disabled versions (#1611)- Reporting errors at startup should no longer cause a segfault under certain circumstances (#1626)
Miscellaneous
v2.7.2
I now have a Patreon for Catch2
Improvements
- Added an approximate vector matcher (#1499)
Fixes
- Filters will no longer be shown if there were none
- Fixed compilation error when using Homebrew GCC on OS X (#1588, #1589)
- Fixed the console reporter not showing messages that start with a newline (#1455, #1470)
- Modified JUnit reporter's output so that rng seed and filters are reported according to the JUnit schema (#1598)
- Fixed some obscure warnings and static analysis passes
Miscellaneous
- Various improvements to
ParseAndAddCatchTests(#1559, #1601)- When a target is parsed, it receives
ParseAndAddCatchTests_TESTSproperty which summarizes found tests - Fixed problem with tests not being found if the
OptionalCatchTestLaunchervariables is used - Including the script will no longer forcefully modify
CMAKE_MINIMUM_REQUIRED_VERSION - CMake object libraries are ignored when parsing to avoid needless warnings
- When a target is parsed, it receives
CatchAddTestsnow adds test's tags to their CTest labels (#1600)- Added basic CPack support to our build
v2.7.1
Other
I now have a Patreon for my work on Catch2
Improvements
- Reporters now print out the filters applied to test cases (#1550, #1585)
- Added
GENERATE_COPYandGENERATE_REFmacros that can use variables inside the generator expression- Because of the significant danger of lifetime issues, the default
GENERATEmacro still does not allow variables
- Because of the significant danger of lifetime issues, the default
- The
mapgenerator helper now deduces the mapped return type (#1576)