test: added QueryTree tests checking correct query syntax

This commit is contained in:
Eberhard Graether
2014-08-31 11:36:08 +02:00
parent c84972b96e
commit aee0b7c337
8 changed files with 392 additions and 14 deletions
+11
View File
@@ -2,6 +2,7 @@
QueryNode::QueryNode()
: m_isGroup(false)
, m_isComplete(true)
{
}
@@ -28,6 +29,11 @@ void QueryNode::print(std::ostream& ostream, int n) const
ostream << ')';
}
if (!m_isComplete || !isComplete())
{
ostream << " INVALID";
}
ostream << '\n';
}
@@ -40,3 +46,8 @@ void QueryNode::setIsGroup(bool isGroup)
{
m_isGroup = isGroup;
}
void QueryNode::setIsComplete(bool isComplete)
{
m_isComplete = isComplete;
}