summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@theqtcompany.com>2015-03-27 08:38:39 +0100
committerLiang Qi <liang.qi@theqtcompany.com>2015-03-27 08:38:39 +0100
commit5e8d8f9f07c52546ef5f59eeb687022e7acdc892 (patch)
treeba739a253da553b682e1ee378fc64f3a5759f1a0
parent4dfcd15a412e8e19f0d9e9d99dafd70ae1089c5d (diff)
parenta0fdb626e5779e0f393fb9d031bc44d5f48de263 (diff)
downloadqtxmlpatterns-5e8d8f9f07c52546ef5f59eeb687022e7acdc892.tar.gz
Merge remote-tracking branch 'origin/5.5' into dev
Change-Id: Ic5fa3d4a4bc9e1a9c96c78869c2f8b5c4cd19a07
-rw-r--r--tests/auto/headersclean/headersclean.pro3
-rw-r--r--tests/auto/host.pro2
-rw-r--r--tests/auto/xmlpatternssdk/Worker.cpp2
-rw-r--r--tests/auto/xmlpatternssdk/XMLWriter.cpp16
4 files changed, 8 insertions, 15 deletions
diff --git a/tests/auto/headersclean/headersclean.pro b/tests/auto/headersclean/headersclean.pro
deleted file mode 100644
index ecf5f1f..0000000
--- a/tests/auto/headersclean/headersclean.pro
+++ /dev/null
@@ -1,3 +0,0 @@
-QT = xmlpatterns
-load(qt_headersclean)
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/host.pro b/tests/auto/host.pro
index 6bc8753..4095052 100644
--- a/tests/auto/host.pro
+++ b/tests/auto/host.pro
@@ -1,4 +1,4 @@
TEMPLATE=subdirs
SUBDIRS=\
- headersclean \
+
diff --git a/tests/auto/xmlpatternssdk/Worker.cpp b/tests/auto/xmlpatternssdk/Worker.cpp
index d17696e..883599d 100644
--- a/tests/auto/xmlpatternssdk/Worker.cpp
+++ b/tests/auto/xmlpatternssdk/Worker.cpp
@@ -209,6 +209,8 @@ void Worker::threadFinished()
else if(m_unexpectedPasses.isEmpty() && baselineCount == resultCount)
{
err << "Result was identical to the baseline, baseline was not updated.\n";
+ err.flush();
+ QTextStream(stderr) << out;
m_eventLoop.exit(ExitCode::Success);
return;
}
diff --git a/tests/auto/xmlpatternssdk/XMLWriter.cpp b/tests/auto/xmlpatternssdk/XMLWriter.cpp
index 635f693..71ef022 100644
--- a/tests/auto/xmlpatternssdk/XMLWriter.cpp
+++ b/tests/auto/xmlpatternssdk/XMLWriter.cpp
@@ -76,12 +76,6 @@ using namespace QPatternistSDK;
typedef QPair<QString, QString> NSBinding;
typedef QList<NSBinding> NSBindingList;
-#ifdef QT_NO_DEBUG
-# define DEBUG_CODE(code)
-#else
-# define DEBUG_CODE(code) code
-#endif
-
class XMLWriter::Private
{
public:
@@ -290,8 +284,8 @@ public:
QIODevice *dev;
QStack<bool> hasContentStack;
QString errorString;
- DEBUG_CODE(QStack<QString> tags;)
- DEBUG_CODE(QStack<NSBindingList> namespaceTracker;)
+ QStack<QString> tags;
+ QStack<NSBindingList> namespaceTracker;
};
/**
@@ -364,8 +358,8 @@ bool XMLWriter::startElement(const QString &qName,
serialize('<');
serialize(qName);
- DEBUG_CODE(d->tags.push(qName));
- DEBUG_CODE(d->namespaceTracker.push(d->namespaces));
+ d->tags.push(qName);
+ d->namespaceTracker.push(d->namespaces);
/* Add namespace declarations. */
const NSBindingList::const_iterator end(d->namespaces.constEnd());
@@ -421,7 +415,7 @@ bool XMLWriter::endElement(const QString &qName)
Q_ASSERT_X(d->tags.pop() == qName, Q_FUNC_INFO,
"The element tags are not balanced, the produced XML is invalid.");
- DEBUG_CODE(d->namespaceTracker.pop());
+ d->namespaceTracker.pop();
/* "this" element is content for our parent, so ensure hasElementContent is true. */