cmake_test/asserts/string
- cmake_test/asserts/string.ct_assert_string(var)
Asserts that an identifier contains a string
For our purposes a string is anything that is not a list (a list being a string that contains at least one unescaped semicolon). This function will raise an error if the provided identifier is not a string. Consequentially, this function is more-or-less equivalent to ct_assert_not_list.
Note
Be careful not to confuse this assertion with testing for the
str
CMakePPLang type. This assertion only tests that the given variable is not a list.- Parameters:
var (desc*) – The identifier we want the stringy-ness of.
- cmake_test/asserts/string.ct_assert_not_string(var)
Asserts that an identifier does not contain a string
For our purposes a string is anything that is not a list (a list being a string that contains at least one unescaped semicolon). This function will raise an error if the provided identifier is a string. Consequentially, this function is more-or-less equivalent to ct_assert_list.
- Parameters:
var (desc*) – The identifier we want the stringy-ness of.