stuff-from-scratch/test/compiler/TestTemplatingEngine.cpp
2022-11-30 18:28:50 +00:00

19 lines
444 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);
}