Doomseeker
Wadseeker
Download
Tracker
Git
Docs
Main Page
Plugin API
Modules
Classes
Files
File List
All
Classes
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Groups
Pages
src
core
tests
testini.h
1
//------------------------------------------------------------------------------
2
// testini.h
3
//------------------------------------------------------------------------------
4
//
5
// This program is free software; you can redistribute it and/or
6
// modify it under the terms of the GNU General Public License
7
// as published by the Free Software Foundation; either version 2
8
// of the License, or (at your option) any later version.
9
//
10
// This program is distributed in the hope that it will be useful,
11
// but WITHOUT ANY WARRANTY; without even the implied warranty of
12
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
// GNU General Public License for more details.
14
//
15
// You should have received a copy of the GNU General Public License
16
// along with this program; if not, write to the Free Software
17
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
18
// 02110-1301, USA.
19
//
20
//------------------------------------------------------------------------------
21
// Copyright (C) 2010 "Zalewa" <zalewapl@gmail.com>
22
//------------------------------------------------------------------------------
23
#ifndef __TESTINI_H__
24
#define __TESTINI_H__
25
26
#include "tests/testbase.h"
27
#include <QByteArray>
28
29
class
ExampleINIs
30
{
31
public
:
39
static
QByteArray
getExampleINI
();
40
44
static
QByteArray
getExampleError1
();
45
};
46
47
class
TestReadINI
:
public
TestUnitBase
48
{
49
public
:
50
TestReadINI
();
51
52
bool
executeTest();
53
};
54
55
class
TestReadINIVariable
:
public
TestUnitBase
56
{
57
public
:
58
TestReadINIVariable
()
59
:
TestUnitBase
(
"Read INI Variable"
)
60
{
61
}
62
63
bool
executeTest();
64
};
65
66
class
TestReadINIList
:
public
TestUnitBase
67
{
68
public
:
69
TestReadINIList
()
70
:
TestUnitBase
(
"Read INI List"
)
71
{
72
}
73
74
bool
executeTest();
75
76
protected
:
77
bool
compareEntry(
const
QString& actual,
const
QString& expected);
78
};
79
80
class
TestDeleteINIVariable
:
public
TestUnitBase
81
{
82
public
:
83
TestDeleteINIVariable
()
84
:
TestUnitBase
(
"Delete INI Variable"
)
85
{
86
}
87
88
bool
executeTest();
89
};
90
91
class
TestDeleteINISection
:
public
TestUnitBase
92
{
93
public
:
94
TestDeleteINISection
()
95
:
TestUnitBase
(
"Delete INI Section"
)
96
{
97
}
98
99
bool
executeTest();
100
};
101
102
class
TestReadINIWithErrors
:
public
TestUnitBase
103
{
104
public
:
105
TestReadINIWithErrors
()
106
:
TestUnitBase
(
"Read INI file with errors"
)
107
{
108
}
109
110
bool
executeTest();
111
};
112
113
#endif
TestDeleteINISection
Definition:
testini.h:91
TestReadINI
Definition:
testini.h:47
TestUnitBase
Base class for Test Units.
Definition:
testbase.h:42
ExampleINIs::getExampleINI
static QByteArray getExampleINI()
Gets an INI file that is written in a format that is 100% supported by the Ini class.
Definition:
testini.cpp:52
TestDeleteINIVariable
Definition:
testini.h:80
TestReadINIWithErrors
Definition:
testini.h:102
ExampleINIs
Definition:
testini.h:29
TestReadINIVariable
Definition:
testini.h:55
ExampleINIs::getExampleError1
static QByteArray getExampleError1()
Ini class should detect errors in this example.
Definition:
testini.cpp:57
TestReadINIList
Definition:
testini.h:66
Doomseeker © 2009-2024 The Doomseeker Team