A very simple testing framework that rejects all previous testing designs and aims for plain wording, simple usability, and ease of debugging. You will never ask where a failure was ever again.
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
project ( 'fuc2' , 'cpp' ,
version : '0.1.0' ,
default_options : [
'cpp_std=c++23' ,
'cpp_args=-D_GLIBCXX_DEBUG=1 -D_GLIBCXX_DEBUG_PEDANTIC=1' ,
] )
# use this for common options only for our executables
cpp_args = [
'-Wno-unused-parameter' ,
'-Wno-unused-function' ,
'-Wno-unused-variable' ,
'-Wno-unused-but-set-variable' ,
'-Wno-deprecated-declarations' ,
]
link_args = [ ]
# these are passed as override_defaults
exe_defaults = [ 'warning_level=2' , 'werror=false' ]
fmt = subproject ( 'fmt' ) . get_variable ( 'fmt_dep' )
dependencies = [ fmt ]
sources = [
'src/fuc2.cpp' ,
]
fuc2_includes = include_directories ( 'include' )
fuc2_lib = static_library ( 'fuc2' ,
sources ,
pic : true ,
cpp_args : cpp_args ,
include_directories : fuc2_includes ,
override_options : exe_defaults ,
dependencies : dependencies )
fuc2_dep = declare_dependency (
link_with : fuc2_lib ,
include_directories : fuc2_includes )
executable ( 'fuc2it' , [
'tests/sample1.cpp' ,
'tests/sample_failing.cpp' ,
'tests/main.cpp' ,
] ,
cpp_args : cpp_args ,
link_args : link_args ,
override_options : exe_defaults ,
include_directories : fuc2_includes ,
link_with : [ fuc2_lib ] ,
dependencies : dependencies )