Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
testhelper.cxx File Reference
#include "testhelper.hxx"
#include <QFile>
#include <QString>
#include "QtHelper.hxx"
#include "MyDataModel.hxx"
#include <stdlib.h>

Macros

#define SEP   ";"
 

Functions

QString TESTHELPER_testfilename (const char *basefilename)
 
DataObjectTESTHELPER_dummyObject (QString label)
 
void TESTHELPER_loadDataFromFile (TreeModel *dataTreeModel, const QString &filename)
 

Macro Definition Documentation

#define SEP   ";"

Function Documentation

DataObject* TESTHELPER_dummyObject ( QString  label)

This creates a dummy data object for the needs of the test functions. The label is the basename of the spécified pathname.

References QCHARSTAR, and DataObject::setLabel().

void TESTHELPER_loadDataFromFile ( TreeModel dataTreeModel,
const QString &  filename 
)

This test function shows how it's possible to load data from a file to populate the tree model.

References TreeModel::addData(), MyDataObject::PROPERTY_KEY_CIRCUIT, MyDataObject::PROPERTY_KEY_REPFONC, MyDataObject::PROPERTY_KEY_TYPE, QCHARSTAR, QLOG, SEP, and DataObject::setProperty().

QString TESTHELPER_testfilename ( const char *  basefilename)

References QLOG.