diff options
author | Stefan Radomski <radomski@tk.informatik.tu-darmstadt.de> | 2014-07-15 10:17:15 (GMT) |
---|---|---|
committer | Stefan Radomski <radomski@tk.informatik.tu-darmstadt.de> | 2014-07-15 10:17:15 (GMT) |
commit | 61439d49e15045bbe9c3cf55b62fc15909dd48e2 (patch) | |
tree | 6bfacf394b186226e0ba5308d8fcd735203e52a4 /test/src | |
parent | dbd110e2b7eb08c65218a5f9d09ef12fdc62c04a (diff) | |
download | uscxml-61439d49e15045bbe9c3cf55b62fc15909dd48e2.zip uscxml-61439d49e15045bbe9c3cf55b62fc15909dd48e2.tar.gz uscxml-61439d49e15045bbe9c3cf55b62fc15909dd48e2.tar.bz2 |
Improved support for dot output
Diffstat (limited to 'test/src')
-rw-r--r-- | test/src/test-cmdline-parsing.cpp | 24 | ||||
-rw-r--r-- | test/src/test-predicates.cpp | 6 |
2 files changed, 17 insertions, 13 deletions
diff --git a/test/src/test-cmdline-parsing.cpp b/test/src/test-cmdline-parsing.cpp index 341f24e..6fa0c57 100644 --- a/test/src/test-cmdline-parsing.cpp +++ b/test/src/test-cmdline-parsing.cpp @@ -47,7 +47,7 @@ int main(int argc, char** argv) { assert(options); assert(options.verbose); assert(options.interpreters.size() == 1); - assert(options.interpreters.find("/foo/bar.scxml") != options.interpreters.end()); + assert(options.interpreters.front().first == "/foo/bar.scxml"); } if (true) { @@ -66,12 +66,13 @@ int main(int argc, char** argv) { assert(options); assert(options.httpPort == 80); assert(options.interpreters.size() == 3); - assert(options.interpreters.find("/foo/bar1.scxml") != options.interpreters.end()); - assert(options.interpreters.find("/foo/bar2.scxml") != options.interpreters.end()); - assert(options.interpreters.find("/foo/bar3.scxml") != options.interpreters.end()); - assert(!options.interpreters["/foo/bar1.scxml"]->withHTTP); - assert(options.interpreters["/foo/bar2.scxml"]->withHTTP); - assert(!options.interpreters["/foo/bar3.scxml"]->withHTTP); + assert(options.interpreters[0].first == "/foo/bar1.scxml"); + assert(options.interpreters[1].first == "/foo/bar2.scxml"); + assert(options.interpreters[2].first == "/foo/bar3.scxml"); + + assert(!options.interpreters[0].second->withHTTP); + assert(options.interpreters[1].second->withHTTP); + assert(!options.interpreters[2].second->withHTTP); } if (true) { @@ -88,9 +89,12 @@ int main(int argc, char** argv) { assert(options); assert(options.httpPort == 80); assert(options.interpreters.size() == 1); - assert(options.interpreters.find("/foo/bar1.scxml") != options.interpreters.end()); - assert(options.interpreters["/foo/bar1.scxml"]->additionalParameters.find("vrml-path") != options.interpreters["/foo/bar1.scxml"]->additionalParameters.end()); - assert(options.interpreters["/foo/bar1.scxml"]->additionalParameters.find("tmp-path") != options.interpreters["/foo/bar1.scxml"]->additionalParameters.end()); + assert(options.interpreters[0].first == "/foo/bar1.scxml"); + + assert(options.interpreters[0].second->additionalParameters.find("vrml-path") + != options.interpreters[0].second->additionalParameters.end()); + assert(options.interpreters[0].second->additionalParameters.find("tmp-path") + != options.interpreters[0].second->additionalParameters.end()); } return EXIT_SUCCESS; diff --git a/test/src/test-predicates.cpp b/test/src/test-predicates.cpp index fb4551e..02e0faf 100644 --- a/test/src/test-predicates.cpp +++ b/test/src/test-predicates.cpp @@ -24,17 +24,17 @@ int main(int argc, char** argv) { assert(interpreter); interpreter.getImpl()->init(); - Node<std::string> atomicState = interpreter.getImpl()->getState("atomic"); + Element<std::string> atomicState = interpreter.getImpl()->getState("atomic"); assert(InterpreterImpl::isAtomic(atomicState)); assert(!InterpreterImpl::isParallel(atomicState)); assert(!InterpreterImpl::isCompound(atomicState)); - Node<std::string> compoundState = interpreter.getImpl()->getState("compound"); + Element<std::string> compoundState = interpreter.getImpl()->getState("compound"); assert(!InterpreterImpl::isAtomic(compoundState)); assert(!InterpreterImpl::isParallel(compoundState)); assert(InterpreterImpl::isCompound(compoundState)); - Node<std::string> parallelState = interpreter.getImpl()->getState("parallel"); + Element<std::string> parallelState = interpreter.getImpl()->getState("parallel"); assert(!InterpreterImpl::isAtomic(parallelState)); assert(InterpreterImpl::isParallel(parallelState)); assert(!InterpreterImpl::isCompound(parallelState)); // parallel states are not compound! |