doc
diff --git a/README.md b/README.md
index bf5c62b..9e20478 100644
--- a/README.md
+++ b/README.md
@@ -1,14 +1,39 @@
the lightest feature rich C++ single header testing framework
-------
-The **doctest** library is inspired by the ```unittest {}``` functionality of the **D** programming language and **Python**'s **docstrings** - tests can be considered a form of documentation and _should_ be able to reside near the production code which they test.
+The **doctest** library is inspired by the ```unittest {}``` functionality of the **D** programming language.
It is heavily influenced by [**Catch**](https://github.com/philsquared/Catch) which is currently the most popular, simple and user friendly alternative out there.
+The main differences are:
+
+A complete compiling example with a self-registering test and a test runner looks like this:
+
+```c++
+#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
+#include "doctest.h"
+
+int factorial(int number) { return number <= 1 ? number : factorial(number - 1) * number; }
+
+TEST_CASE("testing the factorial function") {
+ CHECK(factorial(1) == 1);
+ CHECK(factorial(2) == 2);
+ CHECK(factorial(10) == 3628800);
+}
+```
+
+
+
+
+
+
+
+
- Check out [**features and design goals**](doc/markdown/features.md#why-does-this-library-exist-and-how-is-it-different-from-all-the-rest) to see why this library exists and how it is different from all the rest.
- Check out the tutorial [**here**](doc/markdown/tutorial.md#tutorial).
- [![Try it online](https://img.shields.io/badge/try%20it-online-orange.svg)](http://melpon.org/wandbox/permlink/xvF0y5DTzIDLN98f)
+- a rich set of examples...
- [![documentation](https://img.shields.io/badge/documentation-online%20%20%20%20%20-blue.svg)](doc/markdown/readme.md#reference)
- [![download](https://img.shields.io/badge/latest%20version%20%20-download-blue.svg)](https://raw.githubusercontent.com/onqtam/doctest/master/doctest/doctest.h)
diff --git a/doc/markdown/configuration.md b/doc/markdown/configuration.md
index eb72158..808a8fe 100644
--- a/doc/markdown/configuration.md
+++ b/doc/markdown/configuration.md
@@ -9,6 +9,8 @@
#include "doctest.h"
```
+This should be done in only one source file! Otherwise there will be linker errors and slower build times.
+
If the client wants to [**supply the ```main()``` function**](main.md) (either to set an option with some value from the code or to integrate the framework into his existing project codebase) then the **```DOCTEST_CONFIG_IMPLEMENT```** define should be used.
The next most important configuration option is **```DOCTEST_CONFIG_DISABLE```** - when defined globally in the whole project before the inclusion of the framework header - everything testing - related is removed from the binary - including most of the framework implementation and every test case written anywhere! This is one of the most unique features of **doctest**.
@@ -29,7 +31,7 @@
- **```DOCTEST_CONFIG_USE_IOSFWD```** - the library by default provides a forward declaration of ```std::ostream``` in order to support the ```operator<<``` [**stringification**](stringification.md) mechanism. This is forbidden by the standard (even though it works everywhere on all tested compilers). However if the user wishes to be 100% standards compliant - then this configuration option can be used to force the inclusion of ```<iosfwd>```. It should be defined everywhere before the framework header is included.
-- **```DOCTEST_CONFIG_WITH_LONG_LONG```** - by default the library includes support for stringifying ```long long``` only if the value of ```__cplusplus``` is atleast ```201103L``` (C++11) or if the compiler is MSVC 2003 or newer. Many compilers that don't fully support C++11 have it as an extension but it errors for GCC/Clang when the ```-std=c++98``` option is used and this cannot be detected with the preprocessor in any way. Use this configuration option if your compiler supports ```long long``` but doesn't yet support the full C++11 standard. It should be defined everywhere before the framework header is included.
+- **```DOCTEST_CONFIG_WITH_LONG_LONG```** - by default the library includes support for stringifying ```long long``` only if the value of ```__cplusplus``` is at least ```201103L``` (C++11) or if the compiler is MSVC 2003 or newer. Many compilers that don't fully support C++11 have it as an extension but it errors for GCC/Clang when the ```-std=c++98``` option is used and this cannot be detected with the preprocessor in any way. Use this configuration option if your compiler supports ```long long``` but doesn't yet support the full C++11 standard. It should be defined everywhere before the framework header is included.
---------------
diff --git a/doc/markdown/faq.md b/doc/markdown/faq.md
index 96e3048..22a2f32 100644
--- a/doc/markdown/faq.md
+++ b/doc/markdown/faq.md
@@ -22,9 +22,6 @@
- why c++98?
-- why no ```long long``` in gcc/clang when in the c++98 standard?
- - http://stackoverflow.com/questions/35826731/detect-if-long-long-is-present-at-compile-time
-
- will the library support checking for memory leaks? no. use tools like valgrind or the sanitizers.
- mixing different versions of the framework within the same executable?
diff --git a/doc/markdown/main.md b/doc/markdown/main.md
index 09aa6bd..2c2ed44 100644
--- a/doc/markdown/main.md
+++ b/doc/markdown/main.md
@@ -1,2 +1,49 @@
-## main() entry point
+## The ```main()``` entry point
+The usual way of writing tests in C++ has always been into separate source files from the code they test that form an executable containing only tests. In that scenario the default ```main()``` provided by **doctest** is usually sufficient:
+
+```c++
+#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
+#include "doctest.h"
+```
+
+This should be done in exactly one source file and is even a good idea to do this in a separate file with nothing else in it.
+
+However if you need more control - want to set options with code to the execution context or want to integrate the framework in your production code - then the default ```main()``` just won't do the job. In that case use **```DOCTEST_CONFIG_IMPLEMENT```**.
+
+All the [**command line**](commandline.md) options can be set like this (flags cannot because it wouldn't make sense). Filters can only be appended - the user cannot remove a filter given from the command line with code.
+
+```c++
+#define DOCTEST_CONFIG_IMPLEMENT
+#include "doctest.h"
+
+int main(int argc, char** argv) {
+ doctest::Context context(argc, argv); // initialize
+
+ // overrides
+ context.addFilter("test-case-exclude", "*math*"); // exclude test cases with "math" in their name
+ context.setOption("no-breaks", true); // don't break in the debugger when assertions fail
+ context.setOption("abort-after", 5); // stop test execution after 5 failed assertions
+ context.setOption("sort", "name"); // sort the test cases by their name
+
+ int res = context.run(); // run
+
+ if(context.shouldExit()) // important - query flags (and --no-run) rely on the user doing this
+ return res;
+
+ // your program - if the testing framework is integrated in your production code
+
+ return res;
+}
+
+```
+
+#### dealing with shared objects (DLLs)
+
+When integrating the framework in production code which gets built as a shared object (dll) everything still works. Many shared objects and an executable can have tests in them and can even use different versions of the **doctest** framework.
+
+Check out [**this**](../../examples/dll_and_executable/) example which showcases how to call the tests in a shared object from the executable (and it also showcases that if a file with a test case is included both in the shared object and the executable then the test is registered in both places).
+
+---------------
+
+[Home](readme.md#reference)
diff --git a/examples/dll_and_executable/CMakeLists.txt b/examples/dll_and_executable/CMakeLists.txt
new file mode 100644
index 0000000..2016df7
--- /dev/null
+++ b/examples/dll_and_executable/CMakeLists.txt
@@ -0,0 +1,21 @@
+cmake_minimum_required(VERSION 2.8)
+
+get_filename_component(PROJECT_NAME ${CMAKE_CURRENT_SOURCE_DIR} NAME)
+project(${PROJECT_NAME})
+
+include(../../scripts/common.cmake)
+
+if(DEFINED ENV{TRAVIS} AND APPLE)
+ set(CMAKE_MACOSX_RPATH ON)
+ # force 64 bit for OSX because -m32 fails >>> SOMETIMES <<< (x86_64 vs 386 - like the dll is not linked with -m32...)
+ add_compiler_flags(-m64)
+endif()
+
+include_directories("../../doctest/")
+
+add_library(dll_1 SHARED dll.cpp)
+
+add_executable(${PROJECT_NAME} main.cpp)
+target_link_libraries(${PROJECT_NAME} dll_1)
+
+add_test(NAME ${PROJECT_NAME} COMMAND $<TARGET_FILE:${PROJECT_NAME}>)
diff --git a/examples/dll_and_executable/common.h b/examples/dll_and_executable/common.h
new file mode 100644
index 0000000..0d90176
--- /dev/null
+++ b/examples/dll_and_executable/common.h
@@ -0,0 +1,39 @@
+#pragma once
+
+// taken from https://gcc.gnu.org/wiki/Visibility
+#if defined _WIN32 || defined __CYGWIN__
+ #ifdef BUILDING_DLL
+ #ifdef __GNUC__
+ #define DLL_PUBLIC __attribute__ ((dllexport))
+ #else
+ #define DLL_PUBLIC __declspec(dllexport)
+ #endif
+ #else
+ #ifdef __GNUC__
+ #define DLL_PUBLIC __attribute__ ((dllimport))
+ #else
+ #define DLL_PUBLIC __declspec(dllimport)
+ #endif
+ #endif
+#else
+ #ifdef BUILDING_DLL
+ #if __GNUC__ >= 4
+ #define DLL_PUBLIC __attribute__ ((visibility ("default")))
+ #else
+ #define DLL_PUBLIC
+ #endif
+ #else
+ #define DLL_PUBLIC
+ #endif
+#endif
+
+#define DOCTEST_CONFIG_IMPLEMENT
+#include "doctest.h"
+
+#include <cstdio>
+
+TEST_CASE("shared") {
+ printf("I am a test in a header used by the executable and the dll!\n");
+}
+
+DLL_PUBLIC int call_tests_from_dll(int argc, char** argv);
diff --git a/examples/dll_and_executable/dll.cpp b/examples/dll_and_executable/dll.cpp
new file mode 100644
index 0000000..937a67a
--- /dev/null
+++ b/examples/dll_and_executable/dll.cpp
@@ -0,0 +1,11 @@
+#define BUILDING_DLL
+#include "common.h"
+
+TEST_CASE("dll") {
+ printf("I am a test from the dll!\n");
+}
+
+DLL_PUBLIC int call_tests_from_dll(int argc, char** argv) {
+ doctest::Context context(argc, argv);
+ return context.run();
+}
diff --git a/examples/dll_and_executable/main.cpp b/examples/dll_and_executable/main.cpp
new file mode 100644
index 0000000..1d2d6e2
--- /dev/null
+++ b/examples/dll_and_executable/main.cpp
@@ -0,0 +1,14 @@
+#include "common.h"
+
+TEST_CASE("executable") {
+ printf("I am a test from the executable!\n");
+}
+
+int main(int argc, char** argv) {
+ doctest::Context context(argc, argv);
+ int res = context.run();
+
+ res += call_tests_from_dll(argc, argv);
+
+ return res;
+}
diff --git a/examples/dll_and_executable/test_output/multi_dll.txt b/examples/dll_and_executable/test_output/multi_dll.txt
new file mode 100644
index 0000000..f939eeb
--- /dev/null
+++ b/examples/dll_and_executable/test_output/multi_dll.txt
@@ -0,0 +1,4 @@
+I am a test in a header used by the executable and the dll!
+I am a test from the executable!
+I am a test in a header used by the executable and the dll!
+I am a test from the dll!
diff --git a/examples/linker_stress_test/CMakeLists.txt b/examples/linker_stress_test/CMakeLists.txt
new file mode 100644
index 0000000..234e63c
--- /dev/null
+++ b/examples/linker_stress_test/CMakeLists.txt
@@ -0,0 +1,22 @@
+cmake_minimum_required(VERSION 2.8)
+
+if(CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang")
+ # Clang stalls on linking this example - shame... - hope it gets a lot faster in the future
+ # GCC just takes a lot of time - but I want faster travis builds
+ return()
+endif()
+
+get_filename_component(PROJECT_NAME ${CMAKE_CURRENT_SOURCE_DIR} NAME)
+project(${PROJECT_NAME})
+
+include(../../scripts/common.cmake)
+
+include_directories("../../doctest/")
+
+if(MSVC)
+ add_definitions(/bigobj)
+endif()
+
+add_executable(${PROJECT_NAME} main.cpp test.cpp)
+
+add_test(NAME ${PROJECT_NAME} COMMAND $<TARGET_FILE:${PROJECT_NAME}>)
diff --git a/examples/linker_stress_test/main.cpp b/examples/linker_stress_test/main.cpp
new file mode 100644
index 0000000..5bf4cfb
--- /dev/null
+++ b/examples/linker_stress_test/main.cpp
@@ -0,0 +1,12 @@
+#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
+#include "doctest.h"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
diff --git a/examples/linker_stress_test/readme.txt b/examples/linker_stress_test/readme.txt
new file mode 100644
index 0000000..30889e3
--- /dev/null
+++ b/examples/linker_stress_test/readme.txt
@@ -0,0 +1,27 @@
+Machine:
+ intel i7 3770k
+ 16g ram
+ ssd
+OS:
+ windows 7 x64
+ ubuntu 14.04
+Compilers:
+ MinGW:
+ gcc (x86_64-posix-seh-rev1, Built by MinGW-W64 project) 4.9.0
+ MSVC:
+ MSVC 2013
+ Linux GCC:
+ gcc (Ubuntu 4.8.2-19ubuntu1) 4.8.2
+
+Test consists of: 10k doctests in each of the 2 cpp files.
+
+gcc (mingw/linux): "-std=c++98 -m64"
+
+debug build:
+ mingw: 121 sec (~100 sec link time)
+ msvc: 11 sec
+ linux: 11 sec (~1 sec link time)
+release build:
+ mingw: 148 sec
+ msvc: 21 sec
+ linux: 24 sec
diff --git a/examples/linker_stress_test/stress.inl b/examples/linker_stress_test/stress.inl
new file mode 100644
index 0000000..325a447
--- /dev/null
+++ b/examples/linker_stress_test/stress.inl
@@ -0,0 +1,1000 @@
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
+TEST_CASE("trololo"){}
diff --git a/examples/linker_stress_test/test.cpp b/examples/linker_stress_test/test.cpp
new file mode 100644
index 0000000..3ebf1fb
--- /dev/null
+++ b/examples/linker_stress_test/test.cpp
@@ -0,0 +1,11 @@
+#include "doctest.h"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
+#include "stress.inl"
diff --git a/examples/range_based_execution/CMakeLists.txt b/examples/range_based_execution/CMakeLists.txt
new file mode 100644
index 0000000..8304f37
--- /dev/null
+++ b/examples/range_based_execution/CMakeLists.txt
@@ -0,0 +1,12 @@
+cmake_minimum_required(VERSION 2.8)
+
+get_filename_component(PROJECT_NAME ${CMAKE_CURRENT_SOURCE_DIR} NAME)
+project(${PROJECT_NAME})
+
+include(../../scripts/common.cmake)
+
+include_directories("../../doctest/")
+
+add_executable(${PROJECT_NAME} main.cpp)
+
+add_test(NO_VALGRIND NO_OUTPUT NAME ${PROJECT_NAME}_1 COMMAND python ${CMAKE_CURRENT_SOURCE_DIR}/run.py $<TARGET_FILE:${PROJECT_NAME}>)
diff --git a/examples/range_based_execution/main.cpp b/examples/range_based_execution/main.cpp
new file mode 100644
index 0000000..8c0acf4
--- /dev/null
+++ b/examples/range_based_execution/main.cpp
@@ -0,0 +1,114 @@
+#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
+#include "doctest.h"
+
+#include <cstdio>
+
+static void sleeper(int line) {
+#ifdef NDEBUG
+ for(int i = 0; i < 50000000; i++) ((void)0);
+#else
+ for(int i = 0; i < 10000000; i++) ((void)0);
+#endif
+ printf("hello from test case %d!\n", line);
+}
+
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
+TEST_CASE("") { sleeper(__LINE__ - 14); }
diff --git a/examples/range_based_execution/run.py b/examples/range_based_execution/run.py
new file mode 100644
index 0000000..d29de5c
--- /dev/null
+++ b/examples/range_based_execution/run.py
@@ -0,0 +1,33 @@
+#!/usr/bin/python
+
+import sys
+import math
+import multiprocessing
+import subprocess
+
+if len(sys.argv) != 2:
+ print("supply the path to the doctest executable as the first argument!")
+ sys.exit(0)
+
+# get the number of tests in the doctest executable
+result = subprocess.Popen([sys.argv[1], "-count"], stdout = subprocess.PIPE).communicate()[0]
+num_tests = int(result.rsplit(' ', 1)[-1])
+
+# calculate the ranges
+cores = multiprocessing.cpu_count()
+l = range(num_tests + 1)
+n = int(math.ceil(float(len( l )) / cores))
+data = [l[i : i + n] for i in range(1, len( l ), n)]
+data = tuple([[x[0], x[-1]] for x in data])
+
+# for 8 cores and 100 tests the ranges will look like this
+# ([1, 13], [14, 26], [27, 39], [40, 52], [53, 65], [66, 78], [79, 91], [92, 100])
+
+# the worker callback that runs the executable for the given range of tests
+def worker((first, last)):
+ subprocess.Popen([sys.argv[1], "-first=%s -last=%s" % (first, last)])
+
+# run the tasks on a pool
+if __name__ == '__main__':
+ p = multiprocessing.Pool(cores)
+ p.map(worker, data)
diff --git a/examples/stringification/CMakeLists.txt b/examples/stringification/CMakeLists.txt
new file mode 100644
index 0000000..4d62381
--- /dev/null
+++ b/examples/stringification/CMakeLists.txt
@@ -0,0 +1,12 @@
+cmake_minimum_required(VERSION 2.8)
+
+get_filename_component(PROJECT_NAME ${CMAKE_CURRENT_SOURCE_DIR} NAME)
+project(${PROJECT_NAME})
+
+include(../../scripts/common.cmake)
+
+include_directories("../../doctest/")
+
+add_executable(${PROJECT_NAME} main.cpp)
+
+add_test(NAME ${PROJECT_NAME} COMMAND $<TARGET_FILE:${PROJECT_NAME}> -dt-no-exitcode=1)
diff --git a/examples/stringification/main.cpp b/examples/stringification/main.cpp
new file mode 100644
index 0000000..8fc44c5
--- /dev/null
+++ b/examples/stringification/main.cpp
@@ -0,0 +1,54 @@
+#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
+#include "doctest.h"
+
+#include <string>
+#include <vector>
+
+/*
+#include <sstream>
+
+namespace doctest {
+template <typename T>
+String toString(const std::vector<T>&) {
+ return "aaa";
+}
+}
+*/
+
+/*
+namespace doctest {
+template <typename T>
+String toString(const std::vector<T>& in) {
+ std::ostringstream s;
+ s << "[";
+ for(size_t i = 0; i < in.size(); ++i)
+ if(i < in.size() - 1)
+ s << in[i] << ", ";
+ else
+ s << in[i];
+ s << "]";
+ return s.str().c_str();
+}
+} // namespace doctest
+*/
+
+TEST_CASE("the only test") {
+ std::string dummy1 = "omg";
+ std::string dummy2 = "tralala";
+
+ std::vector<int> vec1;
+ vec1.push_back(1);
+ vec1.push_back(2);
+ vec1.push_back(3);
+
+ std::vector<int> vec2;
+ vec2.push_back(1);
+ vec2.push_back(2);
+ vec2.push_back(4);
+
+ CHECK(4 == 3);
+
+ CHECK(dummy1 == dummy2);
+
+ CHECK(vec1 == vec2);
+}
diff --git a/scripts/how_subcases_work.cpp b/scripts/how_subcases_work.cpp
new file mode 100644
index 0000000..60121d5
--- /dev/null
+++ b/scripts/how_subcases_work.cpp
@@ -0,0 +1,116 @@
+/* THE OUTPUT IS:
+
+creating empty vector
++ 2
+== size: 2
++ 2
+== size: 4
+
+creating empty vector
++ 2
+== size: 2
++ 1
+== size: 3
+
+creating empty vector
++ 1
+== size: 1
+
+*/
+
+#include <iostream>
+#include <vector>
+#include <set>
+
+using namespace std;
+
+set<pair<const char*, int> > passed_subcases;
+set<int> entered_levels;
+int current_level;
+bool has_skipped;
+
+struct Subcase {
+ Subcase(const char* file, int line)
+ : m_entered(false)
+ , m_file(file)
+ , m_line(line)
+ {
+ m_entered = false;
+
+ // if we have already completed it
+ if(passed_subcases.count(pair<const char*, int>(file, line)) != 0)
+ return;
+
+ // if a Subcase on the same level has already been entered
+ if(entered_levels.count(current_level) != 0) {
+ has_skipped = true;
+ return;
+ }
+
+ entered_levels.insert(current_level++);
+
+ m_entered = true;
+ }
+
+ ~Subcase() {
+ if(m_entered) {
+ current_level--;
+ // only mark the subcase as passed if no subcases have been skipped
+ if(has_skipped == false)
+ passed_subcases.insert(pair<const char*, int>(m_file, m_line));
+ }
+ }
+
+ operator bool() const { return m_entered; }
+
+ bool m_entered;
+ const char* m_file;
+ int m_line;
+};
+
+#define STR_CONCAT_IMPL(s1, s2) s1##s2
+#define STR_CONCAT(s1, s2) STR_CONCAT_IMPL(s1, s2)
+#define ANON_VAR STR_CONCAT(anon, __LINE__)
+
+#define subcase(title) if(const Subcase& ANON_VAR = Subcase(__FILE__, __LINE__))
+
+void test() {
+ cout << endl << "creating empty vector" << endl;
+ vector<int> data;
+
+ subcase("size should grow to 2") {
+ cout << "+ 2" << endl;
+ data.push_back(42);
+ data.push_back(10);
+ cout << "== size: " << data.size() << endl;
+
+ subcase("size should grow to 4") {
+ cout << "+ 2" << endl;
+ data.push_back(666);
+ data.push_back(100);
+ cout << "== size: " << data.size() << endl;
+ }
+ subcase("size should grow to 3") {
+ cout << "+ 1" << endl;
+ data.push_back(666);
+ cout << "== size: " << data.size() << endl;
+ }
+ }
+ subcase("size should grow to 1") {
+ cout << "+ 1" << endl;
+ data.push_back(42);
+ cout << "== size: " << data.size() << endl;
+ }
+}
+
+int main() {
+ passed_subcases.clear();
+ do {
+ has_skipped = false;
+ current_level = 0;
+ entered_levels.clear();
+ test();
+ } while(has_skipped == true);
+
+ return 0;
+}