Commit Graph

20 Commits

Author SHA1 Message Date
Martin Hořeňovský
82cec69e93
Don't set C++ standard in CMakeLists for tests 2022-10-29 21:04:58 +02:00
Dimitrij Mijoski
98d37da03e
Raise the minimum CMake version to 3.10 (#2523) 2022-09-16 17:56:00 +02:00
Richard Ash
2840ce1e70
Add an example of using GENERATE(table())
There are some examples on issue #850 of using this feature, but they
are not easily found from the documentation. Adding them here as an
example makes them more findable and ensures they keep working if the
API changes.
2020-07-22 21:49:54 +02:00
Martin Hořeňovský
19ecad6f68
Rename CMake/pkg-config target Catch2Main to Catch2WithMain
This describes the reality better, as it also links in the rest
of Catch2.

The on-disk name of the static library remains just `Catch2Main`,
as that is what it is -- single main function -- and on-disk artifacts
cannot describe link dependencies.
2020-05-03 18:54:38 +02:00
Martin Hořeňovský
b955355ec4
Avoid recompiling main for each example
Instead, link against `Catch2Main` CMake target as intended.
2020-04-24 21:13:07 +02:00
Martin Hořeňovský
6e270958a2
Add development build option to CMake and enable it on CI
Development build enables warnings and and `Werror` or equivalent.
2020-02-26 16:07:26 +01:00
Martin Hořeňovský
5fbf04cd59
Redo how the separate compilation tests are handled 2019-12-15 20:33:39 +01:00
Martin Hořeňovský
29b441949c
Port the last example 2019-12-08 20:58:52 +01:00
Martin Hořeňovský
70ef2f7f12
Update building of examples for static lib 2019-12-08 15:55:04 +01:00
Martin Hořeňovský
d6f7f1fbed
Set CMakeLists to default to C++14 for our internal projects 2019-11-07 13:02:43 +01:00
Martin Hořeňovský
3816e99d0c
Add GENERATE_COPY and GENERATE_VAR capturing generator macros 2019-03-31 14:11:10 +02:00
Martin Hořeňovský
5bf6e47381
Add another example for generators 2019-02-26 12:52:21 +01:00
Martin Hořeňovský
061f1f836a
Update documentation and examples for generators 2019-01-31 10:43:25 +01:00
Martin Moene
558bbe7d24 Add example for TeamCity reporter and refer to it
Prevent warnings
- gnu: -Wcomment: multi-line comment
- clang: -Wweak-vtables 'class' has no out-of-line virtual method definitions; its vtable will be emitted in every translation unit
- clang: -Winconsistent-missing-override: 'method' overrides a member function but is not marked 'override'
- MSVC: C4702: unreachable code
2018-09-27 23:20:02 +02:00
Martin Hořeňovský
1e98c820bb Simplify the Appveyor configuration batch script 2018-09-09 10:18:30 +02:00
Martin Hořeňovský
1a501fcb48 Fix examples compilation for some combinations of Clang and libstdc++ 2018-08-28 10:12:53 +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ý
44722f9ed3 Integrate CMake with <catch2/catch.hpp> include paths
This also goes for pkg-config installed by our CMake installation.

This includes

* Updating CMake version on Travis
* Adding a `Catch2` subfolder to the `single_include/` folder to
provide this include path both _inside_ the repository, and _outside_.
* Updated examples to build with the new paths
* Other general CMake cleanup
2018-06-24 12:32:22 +02:00
David Seifert
b0f4f16ee0 Namespace Catch CMake options 2018-01-18 23:20:26 +01:00
Martin Moene
85de0727d4 Add examples subdirectory to CMake build; included if BUILD_EXAMPLES is true 2017-11-15 15:37:39 +01:00