CreatureLib/tests/LibraryTests/TestLibraryTests.cpp

36 lines
789 B
C++

#ifdef TESTS_BUILD
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include "../../extern/doctest.hpp"
#include "../TestLibrary/TestLibrary.hpp"
TEST_CASE("Can Create Species Library") {
auto l = TestLibrary::BuildSpeciesLibrary();
REQUIRE(l != nullptr);
delete l;
}
TEST_CASE("Can Create Attack Library") {
auto l = TestLibrary::BuildAttackLibrary();
REQUIRE(l != nullptr);
delete l;
}
TEST_CASE("Can Create Item Library") {
auto l = TestLibrary::BuildItemLibrary();
REQUIRE(l != nullptr);
delete l;
}
TEST_CASE("Can Create Growth Rate Library") {
auto l = TestLibrary::BuildGrowthRateLibrary();
REQUIRE(l != nullptr);
delete l;
}
TEST_CASE("Can Create Data Library") {
auto l = TestLibrary::Get();
REQUIRE(l != nullptr);
}
#endif