4 #include <catch_ros/catch.hpp> 6 #include "../../src/launch/launch_config.h" 17 <param if="false" name="test_if" value="hello" /> 18 <param if="true" name="test_if" value="world" /> 20 <param if="1" name="test_if_number" value="hello" /> 21 <param if="0" name="test_if_number" value="world" /> 23 <param unless="false" name="test_unless" value="hello" /> 24 <param unless="true" name="test_unless" value="world" /> 40 using Catch::Matchers::Contains;
43 LaunchConfig().
parseString(R
"EOF(<launch><param if="true" unless="true" name="test" value="test" /></launch>)EOF"), 44 Contains("if") && Contains(
"unless")
const std::map< std::string, XmlRpc::XmlRpcValue > & parameters() const
void evaluateParameters()
void parseString(const std::string &input, bool onlyArguments=false)
TEST_CASE("if/unless basic","[if_unless]")
config parseString(R"EOF(
<launch>
<group ns="/">
<param name="param1" value="hello" />
</group>
<node name="test_node" pkg="rosmon_core" type="abort" ns="/racecar">
<param name="private_param" value="hello again" />
</node>
</launch>
)EOF")