Engauge Digitizer 2
Loading...
Searching...
No Matches
TestFitting.h
Go to the documentation of this file.
1#ifndef TEST_FITTING_H
2#define TEST_FITTING_H
3
4#include <QObject>
5
7class TestFitting : public QObject
8{
10public:
12 explicit TestFitting(QObject *parent = 0);
13
14private slots:
15 void cleanupTestCase ();
16 void initTestCase ();
17
18 // Test exact fit cases, for which the order equals the number of points minus 1
19 void testFunctionExactFit01 ();
20 void testFunctionExactFit12 ();
21 void testFunctionExactFit23 ();
22 void testFunctionExactFit34 ();
23
24 // Test overfitted cases, for which the order is equal to, or greater than, the number of points
25 void testFunctionOverfit11 ();
26 void testFunctionOverfit22 ();
27 void testFunctionOverfit33 ();
28 void testFunctionOverfit44 ();
29
30 // Test underfitted cases, for which the order is less than the number of points minus 1
31 void testFunctionUnderfit02 ();
32 void testFunctionUnderfit13 ();
33 void testFunctionUnderfit24 ();
34 void testFunctionUnderfit35 ();
35
36 // Test case where non-function data was entered even though points should be functional
37 void testNonFunction ();
38
39 // Test the automatic order reduction as a function of the initial order
40 void testOrderReduced3 ();
41 void testOrderReduced4 ();
42 void testOrderReduced5 ();
43 void testOrderReduced6 ();
44
45 // Test the automatic order reduction as a function of the significant digits
46 void testSignificantDigits3 ();
47 void testSignificantDigits4 ();
48 void testSignificantDigits5 ();
49 void testSignificantDigits6 ();
50
51 private:
52 bool generalFunctionTest (int order,
53 int numPoints) const;
54 bool generalNonFunctionTest () const;
55 int orderReducedVersusOrderAndSignificantDigits (int order,
56 int significantDigits) const;
57};
58
59#endif // TEST_FITTING_H
const int INNER_RADIUS_MIN
Unit test of Fitting classes.
Definition TestFitting.h:8
TestFitting(QObject *parent=0)
Single constructor.