Engauge Digitizer
2
Toggle main menu visibility
Loading...
Searching...
No Matches
Test
TestGuidelines.h
Go to the documentation of this file.
1
#ifndef TEST_GUIDELINES_H
2
#define TEST_GUIDELINES_H
3
4
#include "
GuidelineState.h
"
5
#include <QObject>
6
#include <QString>
7
#include <QTimer>
8
9
class
MainWindow
;
10
22
class
TestGuidelines
:
public
QObject
23
{
24
Q_OBJECT
25
public
:
27
explicit
TestGuidelines
(QObject *parent = 0);
28
29
public
slots:
30
// These would be private slots but we want to control when they are called so
31
// these are moved outside of the private slots (which qttest automatically calls).
32
// Number of methods here must agree with NUMBER_TESTS
33
void
test00StartupWithoutTransformation
();
34
void
test01AfterAddingTransformation
();
35
void
test02AfterRemovingTransformation
();
36
37
private
slots:
38
39
void
cleanupTestCase ();
40
void
initTestCase ();
41
42
// Number of tests (with one private slot per test) must equal NUMBER_TESTS
43
void
test00StartupWithoutTransformationReport ();
44
void
test01AfterAddingTransformationReport ();
45
void
test02AfterRemovingTransformationReport ();
46
47
private
:
48
50
class
Result
51
{
52
public
:
54
Result (
bool
pass,
55
const
QString &problem);
56
58
bool
pass ()
const
;
59
61
QString problem ()
const
;
62
63
private
:
64
Result ();
65
66
bool
m_pass;
67
QString m_problem;
68
};
69
71
typedef
QList<Result> Results;
72
73
Result compareExpectedAndGot (
const
QVector<int> &countsExpectedXT,
74
const
QVector<int> &countsExpectedYR);
75
GuidelineState
guidelineStateFromString (
const
QString &
string
)
const
;
76
77
// Number of methods here must agree with NUMBER_TESTS
78
void
test00StartupWithoutTransformationPrepare ();
79
void
test01AfterAddingTransformationPrepare ();
80
void
test02AfterRemovingTransformationPrepare ();
81
82
void
turnOffChecklist ();
83
84
MainWindow
*m_mainWindow;
85
QTimer m_showTimer;
86
Results m_results;
87
};
88
89
#endif
// TEST_GUIDELINES_H
GuidelineState.h
GuidelineState
GuidelineState
Set of possible Guideline states. See class Guideline for more information.
Definition
GuidelineState.h:13
MainWindow
Main window consisting of menu, graphics scene, status bar and optional toolbars as a Single Document...
Definition
MainWindow.h:95
TestGuidelines::test02AfterRemovingTransformation
void test02AfterRemovingTransformation()
Definition
TestGuidelines.cpp:294
TestGuidelines::test01AfterAddingTransformation
void test01AfterAddingTransformation()
Definition
TestGuidelines.cpp:227
TestGuidelines::test00StartupWithoutTransformation
void test00StartupWithoutTransformation()
Definition
TestGuidelines.cpp:188
TestGuidelines::TestGuidelines
TestGuidelines(QObject *parent=0)
Single constructor.
Definition
TestGuidelines.cpp:41
Generated on
for Engauge Digitizer by
1.17.0