| 1 |
/* |
| 2 |
* Copyright (C) 2018 Edward d'Auvergne |
| 3 |
* |
| 4 |
* This file is part of the program FlightGear. |
| 5 |
* |
| 6 |
* This program is free software: you can redistribute it and/or modify |
| 7 |
* it under the terms of the GNU General Public License as published by |
| 8 |
* the Free Software Foundation, either version 2 of the License, or |
| 9 |
* (at your option) any later version. |
| 10 |
* |
| 11 |
* This program is distributed in the hope that it will be useful, |
| 12 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 14 |
* GNU General Public License for more details. |
| 15 |
* |
| 16 |
* You should have received a copy of the GNU General Public License |
| 17 |
* along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 18 |
*/ |
| 19 |
|
| 20 |
|
| 21 |
#ifndef FG_FLIGHTPLAN_UNIT_TESTS_HXX |
| 22 |
#define FG_FLIGHTPLAN_UNIT_TESTS_HXX |
| 23 |
|
| 24 |
|
| 25 |
#include <cppunit/extensions/HelperMacros.h> |
| 26 |
#include <cppunit/TestFixture.h> |
| 27 |
|
| 28 |
|
| 29 |
// The flight plan unit tests. |
| 30 |
class FlightplanTests : public CppUnit::TestFixture |
| 31 |
{ |
| 32 |
// Set up the test suite. |
| 33 |
CPPUNIT_TEST_SUITE(FlightplanTests); |
| 34 |
CPPUNIT_TEST(testBasic); |
| 35 |
CPPUNIT_TEST(testRoutePathBasic); |
| 36 |
CPPUNIT_TEST(testRoutePathSkipped); |
| 37 |
CPPUNIT_TEST(testRoutePathTrivialFlightPlan); |
| •38 |
// CPPUNIT_TEST(testBasicAirways); |
| 39 |
CPPUNIT_TEST(testAirwayNetworkRoute); |
| 40 |
CPPUNIT_TEST(testBug1814); |
| 41 |
CPPUNIT_TEST(testRoutPathWpt0Midflight); |
| 42 |
CPPUNIT_TEST(testRoutePathVec); |
| 43 |
CPPUNIT_TEST(testRoutePathFinalLegVQPR15); |
| 44 |
CPPUNIT_TEST(testLoadSaveMachRestriction); |
| 45 |
CPPUNIT_TEST(testOnlyDiscontinuityRoute); |
| 46 |
CPPUNIT_TEST(testBasicDiscontinuity); |
| 47 |
CPPUNIT_TEST(testLeadingWPDynamic); |
| 48 |
CPPUNIT_TEST(testRadialIntercept); |
| 49 |
CPPUNIT_TEST(loadFGFPWithoutDepartureArrival); |
| 50 |
CPPUNIT_TEST(loadFGFPWithEmbeddedProcedures); |
| 51 |
CPPUNIT_TEST(loadFGFPWithOldProcedures); |
| 52 |
CPPUNIT_TEST(loadFGFPWithProcedureIdents); |
| 53 |
CPPUNIT_TEST(testCloningBasic); |
| 54 |
CPPUNIT_TEST(testCloningFGFP); |
| 55 |
CPPUNIT_TEST(testCloningProcedures); |
| 56 |
CPPUNIT_TEST(testBug2616); |
| 57 |
CPPUNIT_TEST(testRoute); |
| 58 |
CPPUNIT_TEST(testViaInsertIntoFP); |
| 59 |
CPPUNIT_TEST(testViaInsertIntoRoute); |
| 60 |
CPPUNIT_TEST(loadFGFPAsRoute); |
| 61 |
CPPUNIT_TEST(testLoadSaveBetweenRestriction); |
| 62 |
CPPUNIT_TEST(testRestrictionUnits); |
| 63 |
|
| 64 |
// CPPUNIT_TEST(testParseICAORoute); |
| 65 |
// CPPUNIT_TEST(testParseICANLowLevelRoute); |
| 66 |
CPPUNIT_TEST_SUITE_END(); |
| 67 |
|
| 68 |
public: |
| 69 |
// Set up function for each test. |
| 70 |
void setUp(); |
| 71 |
|
| 72 |
// Clean up after each test. |
| 73 |
void tearDown(); |
| 74 |
|
| 75 |
// The tests. |
| 76 |
void testBasic(); |
| 77 |
void testRoutePathBasic(); |
| 78 |
void testRoutePathSkipped(); |
| 79 |
void testRoutePathTrivialFlightPlan(); |
| 80 |
void testBasicAirways(); |
| 81 |
void testAirwayNetworkRoute(); |
| 82 |
void testParseICAORoute(); |
| 83 |
void testParseICANLowLevelRoute(); |
| 84 |
void testBug1814(); |
| 85 |
void testRoutPathWpt0Midflight(); |
| 86 |
void testRoutePathVec(); |
| 87 |
void testRoutePathFinalLegVQPR15(); |
| 88 |
void testLoadSaveMachRestriction(); |
| 89 |
void testBasicDiscontinuity(); |
| 90 |
void testOnlyDiscontinuityRoute(); |
| 91 |
void testLeadingWPDynamic(); |
| 92 |
void testRadialIntercept(); |
| 93 |
void loadFGFPWithoutDepartureArrival(); |
| 94 |
void loadFGFPWithEmbeddedProcedures(); |
| 95 |
void loadFGFPWithOldProcedures(); |
| 96 |
void loadFGFPWithProcedureIdents(); |
| 97 |
void testCloningBasic(); |
| 98 |
void testCloningFGFP(); |
| 99 |
void testCloningProcedures(); |
| 100 |
void testBug2616(); |
| 101 |
void testRoute(); |
| 102 |
void testViaInsertIntoFP(); |
| 103 |
void testViaInsertIntoRoute(); |
| 104 |
void loadFGFPAsRoute(); |
| 105 |
void testLoadSaveBetweenRestriction(); |
| 106 |
void testRestrictionUnits(); |
| 107 |
}; |
| 108 |
|
| 109 |
#endif // FG_FLIGHTPLAN_UNIT_TESTS_HXX |