File tree Expand file tree Collapse file tree 1 file changed +32
-0
lines changed Expand file tree Collapse file tree 1 file changed +32
-0
lines changed Original file line number Diff line number Diff line change 1+ include ("rsp/testing" )
2+ include ("rsp/debug" )
3+
4+ define_test_case(
5+ "Build Info Test"
6+ LABELS "debug;build_info"
7+ )
8+
9+ # -------------------------------------------------------------------------------------------------------------- #
10+ # Actual Tests
11+ # -------------------------------------------------------------------------------------------------------------- #
12+
13+ define_test("can output build info" "outputs_build_info" )
14+ function (outputs_build_info)
15+
16+ # Set a few of the build info variables
17+ set (CMAKE_BUILD_TYPE "Debug" )
18+ set (LIB_TYPE "STATIC" )
19+
20+ # ---------------------------------------------------------------------- #
21+
22+ build_info(OUTPUT result)
23+
24+ # Debug
25+ # message("${result}")
26+
27+ # ---------------------------------------------------------------------- #
28+
29+ # Ensure that a few of the properties are in the output
30+ assert_string_contains("${result} " "Type: ${CMAKE_BUILD_TYPE} " MESSAGE "Incorrect build info output (build type)" )
31+ assert_string_contains("${result} " "Library Type: ${LIB_TYPE} " MESSAGE "Incorrect build info output (library type)" )
32+ endfunction ()
You can’t perform that action at this time.
0 commit comments