File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed
Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -49,17 +49,21 @@ run_command(
4949
5050
5151if get_option (' build_tests' )
52+ test_flags = [' -D__TEST_DIR__=' + meson .project_source_root() / ' test' ]
53+
5254 inja_test = executable (
5355 ' inja_test' ,
5456 ' test/test.cpp' ,
55- dependencies : inja_dep
57+ dependencies : inja_dep,
58+ cpp_args : test_flags,
5659 )
5760
5861 inja_single_test = executable (
5962 ' inja_single_test' ,
6063 ' test/test.cpp' ,
6164 ' single_include/inja/inja.hpp' ,
62- dependencies : [inja_dep]
65+ dependencies : [inja_dep],
66+ cpp_args : test_flags,
6367 )
6468
6569 test (' Inja unit test' , inja_test)
@@ -69,6 +73,7 @@ if get_option('build_tests')
6973 inja_benchmark = executable (
7074 ' inja_benchmark' ,
7175 ' test/benchmark.cpp' ,
72- dependencies : inja_dep
76+ dependencies : inja_dep,
77+ cpp_args : test_flags,
7378 )
7479endif
You can’t perform that action at this time.
0 commit comments