feat add inja test
All checks were successful
linux-mips64-gcc / linux-gcc-mips64el (Debug) (push) Successful in 1m30s
linux-aarch64-cpu-gcc / linux-gcc-aarch64 (push) Successful in 2m5s
linux-x64-gcc / linux-gcc (Release) (push) Successful in 2m17s
linux-mips64-gcc / linux-gcc-mips64el (Release) (push) Successful in 2m22s
linux-arm-gcc / linux-gcc-armhf (push) Successful in 2m41s
linux-x64-gcc / linux-gcc (Debug) (push) Successful in 2m45s
All checks were successful
linux-mips64-gcc / linux-gcc-mips64el (Debug) (push) Successful in 1m30s
linux-aarch64-cpu-gcc / linux-gcc-aarch64 (push) Successful in 2m5s
linux-x64-gcc / linux-gcc (Release) (push) Successful in 2m17s
linux-mips64-gcc / linux-gcc-mips64el (Release) (push) Successful in 2m22s
linux-arm-gcc / linux-gcc-armhf (push) Successful in 2m41s
linux-x64-gcc / linux-gcc (Debug) (push) Successful in 2m45s
This commit is contained in:
parent
d93e4802c7
commit
8d76becf1c
@ -199,6 +199,7 @@ if(SLED_BUILD_TESTS)
|
||||
sled_add_test(NAME sled_expected_test SRCS src/sled/nonstd/expected_test.cc)
|
||||
sled_add_test(NAME sled_config_test SRCS src/sled/config_test.cc)
|
||||
sled_add_test(NAME sled_ioc_test SRCS src/sled/ioc/ioc_test.cc)
|
||||
sled_add_test(NAME sled_inja_test SRCS src/sled/nonstd/inja_test.cc)
|
||||
endif(SLED_BUILD_TESTS)
|
||||
|
||||
if(SLED_BUILD_FUZZ)
|
||||
|
13
src/sled/nonstd/inja_test.cc
Normal file
13
src/sled/nonstd/inja_test.cc
Normal file
@ -0,0 +1,13 @@
|
||||
#include <sled/nonstd/inja.h>
|
||||
|
||||
TEST_SUITE("inja")
|
||||
{
|
||||
TEST_CASE("render")
|
||||
{
|
||||
inja::json data;
|
||||
data["a"] = 1;
|
||||
data["b"] = "str";
|
||||
auto res = inja::render("{{ a }} {{ b }}", data);
|
||||
CHECK_EQ(res, "1 str");
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user