mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-08-07 18:15:51 +08:00
Some fixes / tweaks / Doxygen:
* helper method to detect disconnected state * clear ATC info if disconnected or not available * unit test for "finders" * added Doxygen file * formatting frequency in text message tabs
This commit is contained in:
@@ -4,8 +4,10 @@
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
#include "testcontainers.h"
|
||||
#include "blackmisc/blackmiscfreefunctions.h"
|
||||
#include "blackmisc/collection.h"
|
||||
#include "blackmisc/sequence.h"
|
||||
#include "blackmisc/avcallsignlist.h"
|
||||
#include <QList>
|
||||
#include <QVector>
|
||||
#include <QSet>
|
||||
@@ -13,6 +15,7 @@
|
||||
#include <set>
|
||||
|
||||
using namespace BlackMisc;
|
||||
using namespace BlackMisc::Aviation;
|
||||
|
||||
namespace BlackMiscTest
|
||||
{
|
||||
@@ -109,4 +112,16 @@ namespace BlackMiscTest
|
||||
QVERIFY2(c1 == c3, "Split collections");
|
||||
}
|
||||
|
||||
} //namespace BlackMiscTest
|
||||
void CTestContainers::findTests()
|
||||
{
|
||||
BlackMisc::registerMetadata();
|
||||
CCallsignList callsigns;
|
||||
CSequence<CCallsign> found = callsigns.findBy(&CCallsign::asString, "Foo");
|
||||
QVERIFY2(found.isEmpty(), "Empty found");
|
||||
callsigns.push_back(CCallsign("EDDM_TWR"));
|
||||
callsigns.push_back(CCallsign("KLAX_TWR"));
|
||||
found = callsigns.findBy(&CCallsign::asString, "KLAXTWR");
|
||||
QVERIFY2(found.size() == 1, "found");
|
||||
}
|
||||
|
||||
} //namespace BlackMiscTest
|
||||
|
||||
Reference in New Issue
Block a user