Changeset View
Changeset View
Standalone View
Standalone View
autotests/testentrytest.h
- This file was added.
1 | /*************************************************************************** | ||||
---|---|---|---|---|---|
2 | * Copyright (C) 2019 by Hartmut Riesenbeck <hartmut.riesenbeck@gmx.de> * | ||||
3 | * * | ||||
4 | * This program is free software; you can redistribute it and/or modify * | ||||
5 | * it under the terms of the GNU General Public License as published by * | ||||
6 | * the Free Software Foundation; either version 2 of the License, or * | ||||
7 | * (at your option) any later version. * | ||||
8 | * * | ||||
9 | * This program is distributed in the hope that it will be useful, * | ||||
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * | ||||
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * | ||||
12 | * GNU General Public License for more details. * | ||||
13 | * * | ||||
14 | * You should have received a copy of the GNU General Public License * | ||||
15 | * along with this program; if not, write to the * | ||||
16 | * Free Software Foundation, Inc., * | ||||
17 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * | ||||
18 | ***************************************************************************/ | ||||
19 | | ||||
20 | #ifndef TESTENTRYTEST_H | ||||
21 | #define TESTENTRYTEST_H | ||||
22 | | ||||
23 | #include <QObject> | ||||
24 | | ||||
25 | | ||||
26 | class KEduVocExpression; | ||||
27 | class TestEntry; | ||||
28 | | ||||
29 | | ||||
30 | namespace TestEntryTests { | ||||
31 | /** @file | ||||
32 | * \brief TestEntry test application | ||||
33 | * Various tests for TestEntry class. | ||||
34 | * @author Hartmut Riesenbeck <hartmut.riesenbeck@gmx.de> | ||||
35 | */ | ||||
36 | | ||||
37 | class TestEntryTest : public QObject | ||||
38 | { | ||||
39 | Q_OBJECT | ||||
40 | | ||||
41 | private slots: | ||||
42 | void initTestCase(); | ||||
43 | void cleanupTestCase(); | ||||
44 | void test_practiceModeDependentMinGrade_written(); | ||||
45 | void test_practiceModeDependentMinGrade_gender(); | ||||
46 | void test_practiceModeDependentMinGrade_conjugation(); | ||||
47 | void test_practiceModeDependentMinGrade_comparsion(); | ||||
48 | void test_practiceModeDependentMaxGrade_written(); | ||||
49 | void test_practiceModeDependentMaxGrade_gender(); | ||||
50 | void test_practiceModeDependentMaxGrade_conjugation(); | ||||
51 | void test_practiceModeDependentMaxGrade_comparsion(); | ||||
52 | void test_practiceModeDependentMinPreGrade_written(); | ||||
53 | void test_practiceModeDependentMinPreGrade_gender(); | ||||
54 | void test_practiceModeDependentMinPreGrade_conjugation(); | ||||
55 | void test_practiceModeDependentMinPreGrade_comparsion(); | ||||
56 | void test_practiceModeDependentMaxPreGrade_written(); | ||||
57 | void test_practiceModeDependentMaxPreGrade_gender(); | ||||
58 | void test_practiceModeDependentMaxPreGrade_conjugation(); | ||||
59 | void test_practiceModeDependentMaxPreGrade_comparsion(); | ||||
60 | | ||||
61 | private: | ||||
62 | KEduVocExpression *makeKEduVocExpressionGrade(); | ||||
63 | KEduVocExpression *makeKEduVocExpressionPreGrade(); | ||||
64 | TestEntry *makeTestEntry(KEduVocExpression *expression); | ||||
65 | | ||||
66 | private: | ||||
67 | KEduVocExpression *m_gradeExpression = nullptr; | ||||
68 | TestEntry *m_gradeTestEntry = nullptr; | ||||
69 | KEduVocExpression *m_preGradeExpression = nullptr; | ||||
70 | TestEntry *m_preGradeTestEntry = nullptr; | ||||
71 | }; | ||||
72 | } | ||||
73 | | ||||
74 | #endif // TESTENTRYTEST_H | ||||
75 | |