This commit is contained in:
Lars Melchior 2020-04-11 12:31:08 +02:00
commit c94580f25c
15 changed files with 711 additions and 0 deletions

13
test/source/greeter.cpp Normal file
View file

@ -0,0 +1,13 @@
#include <doctest/doctest.h>
#include <greeter.h>
TEST_CASE("Greeter") {
using namespace greeter;
Greeter greeter("World");
CHECK(greeter.greet(LanguageCode::EN) == "Hello, World!");
CHECK(greeter.greet(LanguageCode::DE) == "Hello, World!");
CHECK(greeter.greet(LanguageCode::ES) == "Hello, World!");
CHECK(greeter.greet(LanguageCode::FR) == "Hello, World!");
}

3
test/source/main.cpp Normal file
View file

@ -0,0 +1,3 @@
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include <doctest/doctest.h>