19 :pv(
"pv",
"pvd", vector<double>(10,5.0))
27 bool operator==(
const std::vector<double>& a,
const std::vector<double>& b)
29 if ( a.size() != b.size() ) {
30 log(
Error) <<
"Wrong vector sizes : " << a.size() <<
" "<< b.size()<<
endlog();
33 for(
unsigned int i =0; i != a.size(); ++i)
36 log(
Error) <<
"Wrong vector element: "<<a[i]<<
" != "<<b[i]<<
" i:" << i<<
endlog();
44 std::ostream& operator<<(std::ostream& os, const std::vector<double>& vect) {
46 for(
unsigned int i= 0; i != vect.size(); ++i)
47 os << vect[i] << (i+1 == vect.size() ?
"]" :
", ");
57 while ( ita != a.
end() ) {
95 BOOST_REQUIRE( decomposed.ready() );
96 BOOST_CHECK_EQUAL( decomposed.value().getType(),
"array" );
100 BOOST_CHECK_EQUAL( decomposed.value().size(),
pv.
value().size() );
106 BOOST_REQUIRE( pr.
ready() );
107 BOOST_CHECK_EQUAL( pr.
value().size(),
pv.
value().size() );
#define BOOST_FIXTURE_TEST_SUITE(suite_name, F)
Property< T > * getPropertyType(const std::string &name) const
~PropertyCompositionTest()
#define BOOST_AUTO_TEST_SUITE_END()
bool RTT_API composePropertyBag(PropertyBag const &sourcebag, PropertyBag &target)
bool operator==(const std::vector< double > &a, const std::vector< double > &b)
A container for holding references to properties.
BOOST_AUTO_TEST_CASE(testDecomposeComposeEmptyBag)
bool RTT_API decomposePropertyBag(PropertyBag const &sourcebag, PropertyBag &target)
Property< T > & addProperty(const std::string &name, T &attr)
Property< vector< double > > pv
A property represents a named value of any type with a description.
const std::string & getDescription() const
Properties::const_iterator const_iterator
base::PropertyBase * getProperty(const std::string &name) const
Contains TaskContext, Activity, OperationCaller, Operation, Property, InputPort, OutputPort, Attribute.
PropertyCompositionTest()
static Logger::LogFunction endlog()