doctest

FORK: The fastest feature-rich C++11/14/17/20 single-header testing framework
git clone https://git.neptards.moe/neptards/doctest.git
Log | Files | Refs | README

dll.cpp (476B)


      1 #define DOCTEST_CONFIG_IMPLEMENTATION_IN_DLL
      2 #include <doctest/doctest.h>
      3 
      4 DOCTEST_MAKE_STD_HEADERS_CLEAN_FROM_WARNINGS_ON_WALL_BEGIN
      5 #include <iostream>
      6 DOCTEST_MAKE_STD_HEADERS_CLEAN_FROM_WARNINGS_ON_WALL_END
      7 
      8 TEST_CASE("dll") {
      9     std::cout << "I am a test from the dll!\n";
     10     CHECK(true);
     11 }
     12 
     13 DOCTEST_SYMBOL_EXPORT void from_dll();   // to silence "-Wmissing-declarations" with GCC
     14 DOCTEST_SYMBOL_EXPORT void from_dll() {} // force the creation of a .lib file with MSVC