2016-07-05 11:01:22 +08:00
|
|
|
#define CATCH_CONFIG_MAIN
|
|
|
|
#include "catch.hpp"
|
|
|
|
|
|
|
|
#include "template_engine/engine.hpp"
|
|
|
|
|
|
|
|
TEST_CASE("Template Engine - basic placeholder replacement")
|
|
|
|
{
|
2016-11-02 23:05:02 +08:00
|
|
|
auto rendered = template_engine::render("{{one}} {{two}}",
|
|
|
|
{{"one", "two"}, {"two", "one"}});
|
2016-07-05 11:01:22 +08:00
|
|
|
|
|
|
|
REQUIRE(rendered == "two one");
|
|
|
|
}
|