32#include <boost/test/unit_test.hpp>
42 grammars::URIGrammar lGrammar;
43 std::string::const_iterator lBegin ( aUri.begin() );
44 std::string::const_iterator lEnd ( aUri.end() );
45 boost::spirit::qi::phrase_parse ( lBegin , lEnd , lGrammar , boost::spirit::ascii::space , lUri );
51BOOST_AUTO_TEST_SUITE( grammars )
53BOOST_AUTO_TEST_SUITE(
uri )
57 URI lURI =
parseURI(
"ipbusudp-2.0://someHost.xyz:2468");
69 URI lURI =
parseURI(
"chtcp-2.0://someHost.xyz:2468?target=other-host.domain:3579");
83 URI lURI =
parseURI(
"ipbuspcie-2.0:///dev/aFile,/dev/anotherFile");
92 lURI =
parseURI(
"ipbuspcie-2.0:///dev/aFile,/dev/anotherFile?events=/path/to/someOtherFile");
103 lURI =
parseURI(
"ipbuspcie-2.0:///dev/aFile,/dev/anotherFile?events=/path/to/someOtherFile&sleep=20");
117BOOST_AUTO_TEST_SUITE_END()
119BOOST_AUTO_TEST_SUITE_END()
None tests(nox.Session session)
BOOST_CHECK_EQUAL(mem.size(), N)
BOOST_CHECK(!mem.valid())
BOOST_AUTO_TEST_CASE(core_clients)
URI parseURI(const std::string &aUri)
Struct to store a URI when parsed by boost spirit.
std::string mHostname
The "host" part of a URI of the form "protocol://host:port/patha/pathb/blah.ext?key1=val1&key2=val2&k...
NameValuePairVectorType mArguments
The "key1=val1&key2=val2&key3=val3" part of a URI of the form "protocol://host:port/patha/pathb/blah....
std::string mProtocol
The "protocol" part of a URI of the form "protocol://host:port/patha/pathb/blah.ext?...
std::string mPort
The "port" part of a URI of the form "protocol://host:port/patha/pathb/blah.ext?key1=val1&key2=val2&k...
std::string mExtension
The "ext" part of a URI of the form "protocol://host:port/patha/pathb/blah.ext?key1=val1&key2=val2&ke...
std::string mPath
The "patha/pathb/blah" part of a URI of the form "protocol://host:port/patha/pathb/blah....