diff options
Diffstat (limited to 'test/src/test-lifecycle.cpp')
-rw-r--r-- | test/src/test-lifecycle.cpp | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/test/src/test-lifecycle.cpp b/test/src/test-lifecycle.cpp index 22c724a..9b1ac5a 100644 --- a/test/src/test-lifecycle.cpp +++ b/test/src/test-lifecycle.cpp @@ -212,6 +212,30 @@ int main(int argc, char** argv) { int iterations = 1; while(iterations--) { + + if (1) { + // syntactic xml parse error + try { + const char* xml = + "<scxml datamodel=\"ecmascript\">" + " <state id=\"start\">" + " <transition target=\"done\" cond=\"%sf\" />" + " </state>" + " <final id=\"done\" />" + "</scxml>"; + Interpreter interpreter = Interpreter::fromXML(xml); + std::list<InterpreterIssue> issues = interpreter.validate(); + + for (std::list<InterpreterIssue>::iterator issueIter = issues.begin(); issueIter != issues.end(); issueIter++) { + std::cout << *issueIter << std::endl; + } + + } catch (Event& e) { + std::cout << e; + } + } + + if (1) { // syntactic xml parse error try { |