Martin Hořeňovský
94121a5f6d
Add a basic documentation for generators
2018-08-24 13:34:27 +02:00
Martin Hořeňovský
92e25049cf
Move all<int> to .cpp file to remove <limits> from common path
2018-08-24 13:34:03 +02:00
Martin Hořeňovský
fdcd46420e
Update baselines
2018-08-24 13:31:51 +02:00
Phil Nash
7c25dae9ea
First attempt at data generator support
...
The support is to be considered experimental, that is, the interfaces,
the first party generators and helper functions can change or be removed
at any point in time.
Related to #850
2018-08-24 13:31:51 +02:00
David Seifert
7f18282d17
Allow overriding of Python interpreter
...
* Calling `python` does not allow overriding
downstream when running tests.
2018-08-20 14:52:54 +02:00
Phil Nash
1cdaa48a0b
CAPTURE is now variadic
2018-08-19 22:40:20 +02:00
Phil Nash
1a63fad8d6
Seed the RNG in approval tests
2018-08-19 22:34:14 +02:00
Phil Nash
d6f2fd486c
Moved ReusableStringStream impl to generic singleton
2018-08-19 11:28:46 +02:00
Phil Nash
5884ec1e28
Moved registry hub to generic singleton
2018-08-19 11:13:19 +02:00
Phil Nash
eb783fc20e
Added generic singletons facility
...
<sigh> yes, I know - but we have them - may as well make them consistent and safer
2018-08-19 10:34:44 +02:00
Igor Murashkin
38248f3f2c
Add pragma ignore for -Wnon-virtual-dtor in Catch matchers
2018-08-17 17:14:56 +02:00
Martin Hořeňovský
c9de7dd12d
Optimize SourceLineInfo::operator< with short-circuiting
...
In case of 2 instances of SourceLineInfo constructed in the same
file, they will have the same `file` pointer (even at O0). Thus, we
can check if they are equal before calling potentially pointless
`strcmp`.
2018-07-23 20:46:42 +02:00
Martin Hořeňovský
52cbb507ab
Avoid copying StringRef
...
In theory the copy is cheap (couple of pointers change), but tests
are usually compiled in Debug mode/with minimal optimizations, which
means that most users will still have to pay the cost for those
function calls.
2018-07-23 14:04:43 +02:00
Martin Hořeňovský
83bfae1a50
Construct StringRef from constant strings in macros directly using UDL
...
This avoids having to call `strlen` to get the constant string's length
and thus should improve performance.
2018-07-23 14:00:45 +02:00
Martin Hořeňovský
f7f592dfc9
Introduce "C-namespaced" UDL for StringRef
2018-07-23 14:00:45 +02:00
Martin Hořeňovský
78804ea304
Replace std::string with StringRef in MessageInfo for macro capture
...
Because the macro name is compile-time constant, we do not have to
worry about lifetimes and will avoid allocation in case of missing
SSO or long macro name.
2018-07-23 14:00:44 +02:00
Martin Hořeňovský
b93284716e
Update gitattributes
2018-07-23 10:15:52 +02:00
Martin Hořeňovský
15cf3caace
v2.3.0
2018-07-23 10:12:15 +02:00
Martin Hořeňovský
12a8dfa2f2
Fix Listening reporter use of ReporterPreferences
2018-07-22 22:58:18 +02:00
Martin Hořeňovský
797d3b04df
Reinstate CATCH_BUILD_TESTING CMake option
2018-07-22 18:01:42 +02:00
Martin Hořeňovský
82b8744b8c
Direct construct empty StringRef in test macros
2018-07-22 14:13:34 +02:00
Martin Hořeňovský
ce80358306
Document Approx's UDL support
2018-07-15 17:38:57 +02:00
Henry Schreiner
283e2e6d41
Add float/int literal for Approx
2018-07-15 17:03:12 +02:00
Martin Hořeňovský
d6c7392b24
Add a new reporter customization point: reporting all assertions
...
By opting the JUnit and XML reporters into it, we no longer run
into problem where they underreport the results without `-s` flag.
Related to #1264 , #1267 , #1310
2018-07-14 20:51:02 +02:00
Martin Hořeňovský
9ee4c1db52
Allow disabling the implementation of the new output capture
...
As it turns out, some platforms do not provide things like `dup`,
or `std::tmpfile`, but they do provide streams...
Closes #1335
Related to #1311
2018-07-13 20:27:00 +02:00
Axel Huebl
5347ff9e5f
Refactor: override implies virtual
...
If not used with `final`, override implies `virtual`.
Detected via CodeFactor score.
Another reference on SO:
https://stackoverflow.com/questions/43466863/isnt-virtual-keyword-redundant-when-override-or-final-specifiers-are-used
2018-07-12 14:27:06 +02:00
Guillaume Egles
76790604f5
Properly unset tags variable.
2018-07-10 12:48:14 +02:00
Unknown
e21c6aa94d
Fix the second Multiple-file example file link
...
Previously it pointed to the first file as well.
2018-07-09 15:47:03 +02:00
Martin Hořeňovský
7a59d5027f
Link the example from CATCH_CONFIG_NOSTDOUT
documentation
2018-07-08 13:58:44 +02:00
Martin Hořeňovský
c8941cccb5
Add an example on providing streams with CATCH_CONFIG_NOSTDOUT
...
Related to #1037
Closes #1290
2018-07-08 13:38:42 +02:00
Martin Hořeňovský
5eeb6aa361
Update Approx documentation
...
Fixes #1328
2018-07-05 17:28:00 +02:00
Martin Hořeňovský
1c1b447ede
Properly guard CATCH_CONFIG_ENABLE_CHRONO_STRINGMAKER definition
2018-07-03 09:29:26 +02:00
Martin Hořeňovský
e1d81174db
Add -Wmissing-declarations to the SelfTest project
...
This required some clean-up in our test files
2018-07-02 17:36:13 +02:00
Martin Hořeňovský
4846ad59e1
Remove obsolete test
...
`REQUIRE`, `CHECK` and many other macros already support expressions
with multiple template parameters without parenthesizing.
2018-07-02 17:32:47 +02:00
Martin Hořeňovský
ff2b3c85a7
Add comment explaining why we leak -Wparentheses under g++
2018-07-02 17:28:45 +02:00
Martin Hořeňovský
b55424d3b2
Stop -Wunused-variable suppression leaking out of Catch's header
...
Previously it was leaking to suppress warnings on `SECTION`s,
but Clang's support for `_Pragma` is solid, so we can suppress
those locally.
Fixes #1317
2018-07-02 17:28:29 +02:00
Martin Hořeňovský
e69c7ce297
Add Discord badge to README
2018-07-01 20:48:21 +02:00
Martin Hořeňovský
7be8ba36c1
Install contrib when installing Catch using conan
...
Closes #1322
2018-07-01 19:04:50 +02:00
Stephen McDowell
ad120965cf
fix link to single header version catch.hpp
2018-07-01 12:37:13 +02:00
Martin Hořeňovský
f460a7d8f9
Fix documentation of CATCH_CONFIG_FAST_COMPILE
...
Related to issue #1279
2018-06-30 12:31:46 +02:00
Martin Hořeňovský
ebf89000f1
Update thread safety documentation
...
Closes #1302
2018-06-28 22:35:42 +02:00
Martin Hořeňovský
7d00cb83f1
Remove unused benchmark project
2018-06-28 10:53:25 +02:00
Martin Hořeňovský
e69afb6252
Remove removed macros from documentation
2018-06-28 09:43:10 +02:00
Phil Nash
9fb38fcc14
Restored description field in SectionInfo for now - but marked it deprecated
2018-06-25 20:18:41 +01:00
Phil Nash
0f49a600b0
Added DYNAMIC_SECTION to CATCH_CONFIG_DISABLE builds
2018-06-25 19:22:57 +01:00
Phil Nash
5c0efa1cfc
Added DYNAMIC_SECTION and implemented GIVEN/ WHEN/ THEN in terms of it
2018-06-25 19:19:21 +01:00
Phil Nash
1579744ddd
Deprecated description in SECTION (still accepts it, for now, but doesn't use it anywhere)
2018-06-25 19:04:29 +01:00
Phil Nash
9b0e740e31
Changed approval tests path to match changes in CMakeLists.txt
2018-06-25 18:38:08 +01:00
Martin Hořeňovský
1af60ef5ab
Separate Catch2Config from targets
...
This lets us add the installed helper scripts to the cmake module
path, letting CMake users just include them after requiring Catch2
package.
2018-06-24 12:32:22 +02:00
Martin Hořeňovský
3743295ca8
Stop conan package from installing Catch's helpers
2018-06-24 12:32:22 +02:00