From f5f0334fe500da4653f7e7d6a57e8098b6c505a9 Mon Sep 17 00:00:00 2001 From: Klaus Basan Date: Mon, 17 Sep 2018 04:10:19 +0200 Subject: [PATCH] Ref T345, added ATIS/METAR to test ATC stations --- src/blackmisc/test/testing.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/blackmisc/test/testing.cpp b/src/blackmisc/test/testing.cpp index fa7be6942..a9f852244 100644 --- a/src/blackmisc/test/testing.cpp +++ b/src/blackmisc/test/testing.cpp @@ -59,6 +59,8 @@ namespace BlackMisc const QDateTime dtFrom = QDateTime::currentDateTimeUtc(); const QDateTime dtUntil = dtFrom.addSecs(60 * 60); // 1 hour const CUser user(id, usr); + const CInformationMessage atis(CInformationMessage::ATIS, "ATIS for " + QString::number(index)); + const CInformationMessage metar(CInformationMessage::METAR, "Metar for " + QString::number(index)); CAtcStation station; if (byPropertyIndex) @@ -72,6 +74,8 @@ namespace BlackMisc station.setPropertyByIndex(CAtcStation::IndexBookedFrom, CVariant::from(dtFrom)); station.setPropertyByIndex(CAtcStation::IndexBookedUntil, CVariant::from(dtUntil)); station.setPropertyByIndex(CAtcStation::IndexRelativeDistance, CVariant::from(CLength(index + 1, CLengthUnit::NM()))); + station.setPropertyByIndex(CAtcStation::IndexAtis, CVariant::from(atis)); + station.setPropertyByIndex(CAtcStation::IndexMetar, CVariant::from(metar)); } else { @@ -79,6 +83,8 @@ namespace BlackMisc CFrequency(f, CFrequencyUnit::MHz()), geoPos, CLength(50, CLengthUnit::km()), false, dtFrom, dtUntil); station.setRelativeDistance(CLength(index + 1, CLengthUnit::NM())); + station.setAtis(atis); + station.setMetar(metar); } station.setVoiceRoomUrl("vvl://foo.bar.baz/room" + QString::number(index));