stuff-from-scratch/test/compiler/TestTemplatingEngine.cpp
2022-11-29 18:00:19 +00:00

19 lines
426 B
C++

#include "TemplatingEngine.h"
#include <File.h>
#include "TestFramework.h"
#include <filesystem>
#include <iostream>
TEST_CASE(TestTemplatingEngine, "compiler")
{
const auto data_loc = std::filesystem::path(__FILE__) / "../../data";
auto engine = TemplatingEngine(data_loc);
engine.loadTemplateFiles();
const auto content = engine.processTemplate("index");
File outfile("index.html");
outfile.WriteText(content);
}