Seamly2D
Code documentation
qmuparsertest.cpp File Reference

This file contains the implementation of parser test cases. More...

#include "qmuparsertest.h"
#include <stdio.h>
#include <QChar>
#include <QCoreApplication>
#include <QMessageLogger>
#include <QString>
#include <QtDebug>
#include <exception>
#include <limits>
#include <map>
#include <memory>
#include <sstream>
#include <stdexcept>
#include <string>
#include <utility>
#include "qmudef.h"
#include "qmuparser.h"
#include "qmuparsererror.h"
#include "../vmisc/vmath.h"
Include dependency graph for qmuparsertest.cpp:

Go to the source code of this file.

Namespaces

 qmu
 Namespace for mathematical applications.
 
 qmu::Test
 Namespace for test cases.
 

Macros

#define EQN_TEST_BULK(EXPR, R1, R2, R3, R4, PASS)
 
#define PARSER_THROWCHECK(DOMAIN, FAIL, EXPR, ARG)
 

Detailed Description

This file contains the implementation of parser test cases.

Definition in file qmuparsertest.cpp.

Macro Definition Documentation

◆ EQN_TEST_BULK

#define EQN_TEST_BULK (   EXPR,
  R1,
  R2,
  R3,
  R4,
  PASS 
)
Value:
{ \
double res[] = { R1, R2, R3, R4 }; \
iStat += EqnTestBulk(EXPR, res, (PASS)); \
}

◆ PARSER_THROWCHECK

#define PARSER_THROWCHECK (   DOMAIN,
  FAIL,
  EXPR,
  ARG 
)
Value:
iErr = 0; \
QmuParserTester::c_iCount++; \
try \
{ \
p.Define##DOMAIN(EXPR, ARG); \
} \
catch (QmuParserError &) \
{ \
iErr = static_cast<int>(FAIL); \
} \
iStat += iErr;