summaryrefslogtreecommitdiffstats
path: root/test/src/test-arabica-namespaces.cpp
diff options
context:
space:
mode:
authorStefan Radomski <sradomski@mintwerk.de>2016-02-23 11:28:18 (GMT)
committerStefan Radomski <sradomski@mintwerk.de>2016-02-23 11:28:18 (GMT)
commit7212d5a3dbbd2845d09df96b2c345132c8a24931 (patch)
tree194bf3525bc7b607013301b79dde6c9950ccbf2e /test/src/test-arabica-namespaces.cpp
parent8e62f3801b98bf4b7f7f85b848b2fe6339c99162 (diff)
downloaduscxml-7212d5a3dbbd2845d09df96b2c345132c8a24931.zip
uscxml-7212d5a3dbbd2845d09df96b2c345132c8a24931.tar.gz
uscxml-7212d5a3dbbd2845d09df96b2c345132c8a24931.tar.bz2
Some refactoring for improved compile times
Diffstat (limited to 'test/src/test-arabica-namespaces.cpp')
-rw-r--r--test/src/test-arabica-namespaces.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/test/src/test-arabica-namespaces.cpp b/test/src/test-arabica-namespaces.cpp
index 3214d9f..ced9578 100644
--- a/test/src/test-arabica-namespaces.cpp
+++ b/test/src/test-arabica-namespaces.cpp
@@ -7,7 +7,8 @@
#include <DOM/SAX2DOM/SAX2DOM.hpp>
#include <DOM/io/Stream.hpp>
#include "uscxml/Interpreter.h"
-#include "uscxml/DOMUtils.h"
+#include "uscxml/dom/DOMUtils.h"
+#include "uscxml/dom/NameSpacingParser.h"
using namespace Arabica::DOM;
using namespace Arabica::XPath;
@@ -25,8 +26,8 @@ parsed = cloneDocument(parsed);\
insertBaz(parsed);\
std::cout << parsed.first << std::endl;\
validateRootFooBarBaz(parsed);\
-assert(InterpreterImpl::filterChildElements(origNS.xmlNSPrefix + "bar", origDoc.getDocumentElement()).size() == 3);\
-assert(InterpreterImpl::filterChildElements(origNS.xmlNSPrefix + "baz", origDoc.getDocumentElement()).size() == 0);
+assert(DOMUtils::filterChildElements(origNS.xmlNSPrefix + "bar", origDoc.getDocumentElement()).size() == 3);\
+assert(DOMUtils::filterChildElements(origNS.xmlNSPrefix + "baz", origDoc.getDocumentElement()).size() == 0);
/**
@@ -96,7 +97,7 @@ static void validateRootFoo(std::pair<Document<std::string>, NameSpaceInfo>& par
assert(TAGNAME_CAST(root) == nsInfo.xmlNSPrefix + "root");
assert(LOCALNAME_CAST(root) == "root");
- NodeSet<std::string> foosFiltered = InterpreterImpl::filterChildElements(nsInfo.xmlNSPrefix + "foo", root);
+ NodeSet<std::string> foosFiltered = DOMUtils::filterChildElements(nsInfo.xmlNSPrefix + "foo", root);
assert(foosFiltered.size() == 3);
NodeSet<std::string> foosXPath = _xpath.evaluate("//" + nsInfo.xpathPrefix + "foo", root).asNodeSet();
assert(foosXPath.size() == 3);
@@ -118,7 +119,7 @@ static void validateRootFooBar(std::pair<Document<std::string>, NameSpaceInfo>&
Node<std::string> root = document.getDocumentElement();
_xpath.setNamespaceContext(*nsInfo.getNSContext());
- NodeSet<std::string> barsFiltered = InterpreterImpl::filterChildElements(nsInfo.xmlNSPrefix + "bar", root);
+ NodeSet<std::string> barsFiltered = DOMUtils::filterChildElements(nsInfo.xmlNSPrefix + "bar", root);
assert(barsFiltered.size() == 3);
NodeSet<std::string> barsXPath = _xpath.evaluate("//" + nsInfo.xpathPrefix + "bar", root).asNodeSet();
assert(barsXPath.size() == 3);
@@ -143,7 +144,7 @@ static void validateRootFooBarBaz(std::pair<Document<std::string>, NameSpaceInfo
assert(TAGNAME_CAST(root) == nsInfo.xmlNSPrefix + "root");
assert(LOCALNAME_CAST(root) == "root");
- NodeSet<std::string> bazsFiltered = InterpreterImpl::filterChildElements(nsInfo.xmlNSPrefix + "baz", root);
+ NodeSet<std::string> bazsFiltered = DOMUtils::filterChildElements(nsInfo.xmlNSPrefix + "baz", root);
assert(bazsFiltered.size() == 3);
NodeSet<std::string> bazsXPath = _xpath.evaluate("//" + nsInfo.xpathPrefix + "baz", root).asNodeSet();
assert(bazsXPath.size() == 3);