From: stephan b. <sg...@us...> - 2004-12-26 11:13:12
|
Update of /cvsroot/pclasses/pclasses2/test In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3706/test Added Files: StringToolTest.cpp Log Message: egg --- NEW FILE: StringToolTest.cpp --- #ifdef NDEBUG # // force assert() to work... # undef NDEBUG #endif #include <string> #include <map> #include <cassert> #include <pclasses/s11n/s11n_debuggering_macros.h> #include <pclasses/Util/StringTool.h> int main( int argc, char ** argv ) { CERR << "StringTool tests...\n"; using namespace P::StringTool; EntityMap map; map["foo"] = "FOOFOO"; map["bar"] = "BARBAR"; std::string ins = "this is a ${foo} input ${bar}."; CERR << "string: ["<<ins<<"]\n" << "Expanded: [" << expandVars( map, ins ) << "]\n"; return 0; } |