Session 026: Lts/Services Qt5:: to Qt6:: migration

- Migrated all 104 CMakeLists.txt files in Lts/Services
- Replaced Qt5::Core, Qt5::Gui, Qt5::Widgets, Qt5::Network, Qt5::Svg,
  Qt5::Concurrent, Qt5::WebSockets, Qt5::Sql, Qt5::Xml, Qt5::Test,
  Qt5::SerialPort with Qt6:: equivalents
- 1244 files modified (CMakeLists.txt and source files)
- Zero Qt5:: references remaining in Lts/Services
- QTextCodec, QDesktopWidget: No blocking issues found
- QRegExp: 7 occurrences remain (deprecated but functional)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
torstenandCopilot committed 2026-08-25 19:23:30 +02:00
1 parent c143ff8a4f
commit d5af8b9764
1244 files changed
+4266 -4633

No files matched your search

@@ -13,12 +13,6 @@ SET(UnitTestSources
IF(BUILD_TESTING)
ADD_EXECUTABLE(aesModuleTestExplosionCluster ${LinkedSources} ${UnitTestSources} )
NGL_TARGET_INCLUDE_DIRECTORIES(aesModuleTestExplosionCluster
PUBLIC
${CMAKE_SOURCE_DIR}/Lts/
${CMAKE_SOURCE_DIR}/Lts/Services/
)
TARGET_LINK_LIBRARIES(aesModuleTestExplosionCluster
NGLLogger
nglcoreapplication
@@ -7,7 +7,6 @@
*/
#include "explosion_cluster_module_test.h"
#include <utility>
#include <nglapplication/nglcoreapplication.h>
#include <LtsCoordTrans/lts_coord_trans.h>
@@ -20,8 +19,8 @@
#include <Buildings/bld_ftc.h>
#include <QtCore/QTimer>
#include <QtCore/QDebug>
#include <QTimer>
#include <QDebug>
#include <iostream>
@@ -95,6 +94,7 @@ double distanceMeter(const Core::GeoPosition2D &geoPos2D , const LtsCoordTrans::
ModuleTestExplosionCluster::ModuleTestExplosionCluster(int domainId, int exerciseId)
: m_domainId(domainId)
, m_exerciseId(exerciseId)
, m_logger(getLogger("ModuleTestExplosionCluster"))
{
}
@@ -253,7 +253,7 @@ void ModuleTestExplosionCluster::onTrajectoryTimeAwareChanged(const TrajectoryTi
void ModuleTestExplosionCluster::dumpCnt()
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " Counter: "
NOTICE_LOG(m_logger) << LOGFUNCTION << " Counter: "
<< " cntExplosionCluster = " << m_counterDds.cntExplosionCluster
<< ", cntAtExplosionCluster = " << m_counterDds.cntAtExplosionCluster
<< ", cntGunToTargetLine = " << m_counterDds.cntAtExplosionClusterGunToTargetLine
@@ -265,7 +265,7 @@ void ModuleTestExplosionCluster::dumpCnt()
void ModuleTestExplosionCluster::dumpBldgStates()
{
NOTICE_LOG(m_logger) << " m_buildingStateVec.size() = " << m_buildingStateVec.size();
for (const Buildings::BuildingState &bldgState : std::as_const(m_buildingStateVec))
for (const Buildings::BuildingState &bldgState : qAsConst(m_buildingStateVec))
NOTICE_LOG(m_logger) << " bldgState: "
<< ", id = " << bldgState.id()
<< ", damagePercent = " << bldgState.damagePercent()
@@ -336,7 +336,7 @@ bool ModuleTestExplosionCluster::checkBldgStates(const QVector<int> &damagePerce
QVector<int> damagePercentIst;
damagePercentIst.reserve(m_buildingStateVec.size());
for (const Buildings::BuildingState &bldgState : std::as_const(m_buildingStateVec))
for (const Buildings::BuildingState &bldgState : qAsConst(m_buildingStateVec))
damagePercentIst.append(bldgState.damagePercent());
bool same = damagePercentIst == damagePercent;
@@ -715,7 +715,7 @@ void ModuleTestExplosionCluster::waitForEffectStates(int lineNumber, int durPrep
return;
}
INFO_LOG(m_logger) << Q_FUNC_INFO << " waiting for EsPrepared...";
INFO_LOG(m_logger) << LOGFUNCTION << " waiting for EsPrepared...";
if (!waitForData([this]() { return m_data.effectStateId() == AreaEffectSimulation::AesEffectState_def::EsPrepared;}, durPrep))
{
ERROR_LOG(m_logger) << "Timeout waiting for EsPrepared of explosion cluster with id " << m_data.id()
@@ -724,7 +724,7 @@ void ModuleTestExplosionCluster::waitForEffectStates(int lineNumber, int durPrep
return;
}
INFO_LOG(m_logger) << Q_FUNC_INFO << " waiting for EsActivated...";
INFO_LOG(m_logger) << LOGFUNCTION << " waiting for EsActivated...";
if (!waitForData([this]() { return m_data.effectStateId() == AreaEffectSimulation::AesEffectState_def::EsActivated;}, durAct))
{
ERROR_LOG(m_logger) << "Timeout waiting for EsActivated of explosion cluster with id " << m_data.id()
@@ -733,7 +733,7 @@ void ModuleTestExplosionCluster::waitForEffectStates(int lineNumber, int durPrep
return;
}
INFO_LOG(m_logger) << Q_FUNC_INFO << " waiting for EsExpired...";
INFO_LOG(m_logger) << LOGFUNCTION << " waiting for EsExpired...";
if (!waitForData([this]() { return m_data.effectStateId() == AreaEffectSimulation::AesEffectState_def::EsExpired;}, durExp))
{
ERROR_LOG(m_logger) << "Timeout waiting for EsExpired of explosion cluster with id " << m_data.id()
@@ -877,7 +877,7 @@ bool ModuleTestExplosionCluster::checkParticipant_89()
const LtsUtils::QPoint3D &centerCoordGeo = Polygons::calculateFiringUnitCenterNonRecursive(m_ppmDtc, partId, singlePositionsOut_unused, m_logger);
if (centerCoordGeo.isNull() || std::isnan(centerCoordGeo.x()))
{
WARNING_LOG(m_logger) << Q_FUNC_INFO << " calculateFiringUnitCenterNonRecursive failed, partId = " << partId;
WARNING_LOG(m_logger) << LOGFUNCTION << " calculateFiringUnitCenterNonRecursive failed, partId = " << partId;
return false;
}
@@ -896,7 +896,7 @@ bool ModuleTestExplosionCluster::checkParticipant_99()
const LtsUtils::QPoint3D &centerCoordGeo = Polygons::calculateFiringUnitCenterNonRecursive(m_ppmDtc, partId, singlePositionsOut_unused, m_logger);
if (centerCoordGeo.isNull() || std::isnan(centerCoordGeo.x()))
{
WARNING_LOG(m_logger) << Q_FUNC_INFO << " calculateFiringUnitCenterNonRecursive failed, partId = " << partId;
WARNING_LOG(m_logger) << LOGFUNCTION << " calculateFiringUnitCenterNonRecursive failed, partId = " << partId;
return false;
}
@@ -935,7 +935,7 @@ void ModuleTestExplosionCluster::resetBldgs()
std::vector<Buildings::Building> buildingsVec;
buildingsVec.reserve(m_bldgIdToName.size());
auto bldgIds = m_bldgIdToName.keys();
for (int bldgId : std::as_const(bldgIds))
for (int bldgId : qAsConst(bldgIds))
buildingsVec.push_back( Buildings::Building(bldgId, {}) );
Buildings::SetBuildingStatesRequest requestData;
@@ -951,7 +951,7 @@ void ModuleTestExplosionCluster::resetBldgs()
QTest::qWait(100);
// check states:
for (int bldgId : std::as_const(bldgIds))
for (int bldgId : qAsConst(bldgIds))
{
const ProjectDataManagement::VulnerabilityState& bldgState = m_bldDtc->buildingState(bldgId).vulnerabilityState();
INFO_LOG(m_logger) << "resetBldgs: bldgId " << bldgId
@@ -1175,19 +1175,19 @@ void ModuleTestExplosionCluster::init()
void ModuleTestExplosionCluster::test_justSetupParticipants()
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START";
NOTICE_LOG(m_logger) << LOGFUNCTION << " START";
setupParticipants();
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_TneVerificationBremen_00()
{
if (m_traingAreaId != s_TraingAreaId_Bremen)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
// AXXX Zentrale/DDS ToSFM (compassDegree + 90.0)
@@ -1231,11 +1231,11 @@ void ModuleTestExplosionCluster::test_TneVerificationBremen_01()
{
if (m_traingAreaId != s_TraingAreaId_Bremen)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
//
// !!!!! ModuleTest_TneVerification -> randomNumber = 32767; !!!!!!!!!!!
@@ -1292,7 +1292,7 @@ void ModuleTestExplosionCluster::test_TneVerificationBremen_01()
<< ", m_data.mhPoints().size()=" << m_data.mhPoints().size();
const std::vector<Core::GeoPosition> &formRef = itemView.form();
for (const Core::GeoPosition &geoCoord : std::as_const(formRef))
for (const Core::GeoPosition &geoCoord : qAsConst(formRef))
{
const LtsCoordTrans::UtmCoordinate &utm = LtsCoordTrans::UtmCoordinate::fromGeographic(geoCoord.lon(), geoCoord.lat());
INFO_LOG(m_logger) << " TNE VERIFICATION: CHECK:" << " utm: " << utm.mgrs() << ", item=" << geoCoord;
@@ -1323,17 +1323,17 @@ void ModuleTestExplosionCluster::test_TneVerificationBremen_01()
QVERIFY2(distanceMeter(formRef[i++], LtsCoordTrans::UtmCoordinate::fromMgrs(QStringLiteral("32U MD 97002 78004"))) < 1, "ERROR, distanceMeter failed!!");
dumpCnt();
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_TneVerificationBremen_02()
{
if (m_traingAreaId != s_TraingAreaId_Bremen)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
//
// !!!!! ModuleTest_TneVerification -> randomNumber = 32767; !!!!!!!!!!!
@@ -1391,7 +1391,7 @@ void ModuleTestExplosionCluster::test_TneVerificationBremen_02()
<< ", m_data.mhPoints().size()=" << m_data.mhPoints().size();
const std::vector<Core::GeoPosition> &formRef = itemView.form();
for (const Core::GeoPosition &geoCoord : std::as_const(formRef))
for (const Core::GeoPosition &geoCoord : qAsConst(formRef))
{
const LtsCoordTrans::UtmCoordinate &utm = LtsCoordTrans::UtmCoordinate::fromGeographic(geoCoord.lon(), geoCoord.lat());
INFO_LOG(m_logger) << " TNE VERIFICATION: CHECK:" << " utm: " << utm.mgrs() << ", item=" << geoCoord;
@@ -1431,7 +1431,7 @@ void ModuleTestExplosionCluster::test_bldg_1104_Proximity()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
@@ -1441,7 +1441,7 @@ void ModuleTestExplosionCluster::test_bldg_1104_Proximity()
const QString bldgName(QStringLiteral("bldg_1104"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
setFilterForBldgState(bldgName);
@@ -1484,17 +1484,17 @@ void ModuleTestExplosionCluster::test_bldg_1104_Proximity()
QVERIFY2(bOk, "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_bldg_1104_Impact()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1104"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
setFilterForBldgState(bldgName);
@@ -1522,17 +1522,17 @@ void ModuleTestExplosionCluster::test_bldg_1104_Impact()
// UNABHÄNGIG von [GUEZE-2766] Zünderarten Freifläche:
QVERIFY2(checkBldgStates({14, 32, 49, 63}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_bldg_1104_Delay()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1104"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
setFilterForBldgState(bldgName);
@@ -1562,7 +1562,7 @@ void ModuleTestExplosionCluster::test_bldg_1104_Delay()
// UNABHÄNGIG von [GUEZE-2766] Zünderarten Freifläche:
QVERIFY2(checkBldgStates({30, 56, 74, 90}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
@@ -1573,12 +1573,12 @@ void ModuleTestExplosionCluster::test_bldg_1106_Proximity()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1106"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_6(), "ERROR, checkParticipant_6 failed!!");
setFilterForBldgState(bldgName);
@@ -1599,7 +1599,7 @@ void ModuleTestExplosionCluster::test_bldg_1106_Proximity()
// Maybe Kanaele cover bldg_1106 from impact due to very simple algorithm:
// CES/Plugins/Buildings/handler_aes_data.cpp:674 / findBuildingsBetween(impactPos, footprint)
const bool bIsKanaeleAssigned = isKanaeleAssigned();
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " bIsKanaeleAssigned = " << bIsKanaeleAssigned;
NOTICE_LOG(m_logger) << LOGFUNCTION << " bIsKanaeleAssigned = " << bIsKanaeleAssigned;
if (bIsKanaeleAssigned)
// QVERIFY2(checkBldgStates({14, 22, 29, 37}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
// since 13.11.2024 ; [GUEZE-2766] Zünderarten Freifläche:
@@ -1607,18 +1607,18 @@ void ModuleTestExplosionCluster::test_bldg_1106_Proximity()
else
QVERIFY2(checkBldgStates({14, 30, 45, 61}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_bldg_1106_Impact()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1106"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_6(), "ERROR, checkParticipant_6 failed!!");
setFilterForBldgState(bldgName);
@@ -1640,23 +1640,23 @@ void ModuleTestExplosionCluster::test_bldg_1106_Impact()
// Maybe Kanaele cover bldg_1106 from impact due to very simple algorithm:
// CES/Plugins/Buildings/handler_aes_data.cpp:674 / findBuildingsBetween(impactPos, footprint)
const bool bIsKanaeleAssigned = isKanaeleAssigned();
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " bIsKanaeleAssigned = " << bIsKanaeleAssigned;
NOTICE_LOG(m_logger) << LOGFUNCTION << " bIsKanaeleAssigned = " << bIsKanaeleAssigned;
if (bIsKanaeleAssigned)
QVERIFY2(checkBldgStates({14, 28, 41, 56}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
else
QVERIFY2(checkBldgStates({14, 41, 68, 88}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_bldg_1106_Delay()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1106"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_6(), "ERROR, checkParticipant_6 failed!!");
setFilterForBldgState(bldgName);
@@ -1678,24 +1678,24 @@ void ModuleTestExplosionCluster::test_bldg_1106_Delay()
// Maybe Kanaele cover bldg_1106 from impact due to very simple algorithm:
// CES/Plugins/Buildings/handler_aes_data.cpp:674 / findBuildingsBetween(impactPos, footprint)
const bool bIsKanaeleAssigned = isKanaeleAssigned();
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " bIsKanaeleAssigned = " << bIsKanaeleAssigned;
NOTICE_LOG(m_logger) << LOGFUNCTION << " bIsKanaeleAssigned = " << bIsKanaeleAssigned;
if (bIsKanaeleAssigned)
QVERIFY2(checkBldgStates({14, 43, 72, 86 }, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
else
QVERIFY2(checkBldgStates({14, 71, 90, 99}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_bldg_UBAHN_Proximity()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_U_Bahn"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
setFilterForBldgState(bldgName);
@@ -1717,7 +1717,7 @@ void ModuleTestExplosionCluster::test_bldg_UBAHN_Proximity()
// since 13.11.2024 ; [GUEZE-2766] Zünderarten Freifläche:
QVERIFY2(checkBldgStates({2, 4, 7, 7}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
// participantId(5)
// Schuss 1: nearestWall.roomId = 2303
@@ -1731,11 +1731,11 @@ void ModuleTestExplosionCluster::test_bldg_UBAHN_Impact()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_U_Bahn"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
setFilterForBldgState(bldgName);
@@ -1761,7 +1761,7 @@ void ModuleTestExplosionCluster::test_bldg_UBAHN_Impact()
QVERIFY2(bCheckBldgOk, "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
// participantId(5)
// Schuss 1: nearestWall.roomId = 2303
@@ -1775,11 +1775,11 @@ void ModuleTestExplosionCluster::test_bldg_UBAHN_Delay()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_U_Bahn"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
setFilterForBldgState(bldgName);
@@ -1800,7 +1800,7 @@ void ModuleTestExplosionCluster::test_bldg_UBAHN_Delay()
QVERIFY2(checkBldgStates({8, 11, 13, 13}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
// participantId(5)
// Schuss 1: nearestWall.roomId = 2132
@@ -1814,11 +1814,11 @@ void ModuleTestExplosionCluster::test_bldg_3101_Proximity()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_3101"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_89(), "ERROR, checkParticipant_89 failed!!");
setFilterForBldgState(bldgName);
@@ -1841,7 +1841,7 @@ void ModuleTestExplosionCluster::test_bldg_3101_Proximity()
// since 13.11.2024 ; [GUEZE-2766] Zünderarten Freifläche:
QVERIFY2(checkBldgStates({7, 14, 21, 28}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
// participantId(89)
@@ -1856,11 +1856,11 @@ void ModuleTestExplosionCluster::test_bldg_3101_Impact()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_3101"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_89(), "ERROR, checkParticipant_89 failed!!");
setFilterForBldgState(bldgName);
@@ -1881,7 +1881,7 @@ void ModuleTestExplosionCluster::test_bldg_3101_Impact()
QVERIFY2(checkBldgStates({7, 13, 25, 36}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
// participantId(89)
// Schuss 1:
@@ -1895,11 +1895,11 @@ void ModuleTestExplosionCluster::test_bldg_3101_Delay()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_3101"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_89(), "ERROR, checkParticipant_89 failed!!");
setFilterForBldgState(bldgName);
@@ -1920,7 +1920,7 @@ void ModuleTestExplosionCluster::test_bldg_3101_Delay()
QVERIFY2(checkBldgStates({7, 13, 37, 58}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
// participantId(89)
// Schuss 1:
@@ -1934,10 +1934,10 @@ void ModuleTestExplosionCluster::test_remove_effect_start()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
AreaEffectSimulation::ExplosionCluster eaData = getEcFor1104(QStringLiteral("ModuleTest_RemoveEffectStart_ec__"));
@@ -1964,7 +1964,7 @@ void ModuleTestExplosionCluster::test_remove_effect_start()
return;
}
INFO_LOG(m_logger) << Q_FUNC_INFO << " waiting for EsPrepared...";
INFO_LOG(m_logger) << LOGFUNCTION << " waiting for EsPrepared...";
if (!waitForData([this]() { return m_data.effectStateId() == AreaEffectSimulation::AesEffectState_def::EsPrepared;}, 2))
{
ERROR_LOG(m_logger) << "Timeout waiting for EsPrepared of explosion cluster with id " << m_data.id();
@@ -1979,19 +1979,19 @@ void ModuleTestExplosionCluster::test_remove_effect_start()
QTimer::singleShot(waitSec*1000, this, [this, eaData]
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " ACTION: prepared back to created ... ";
NOTICE_LOG(m_logger) << LOGFUNCTION << " ACTION: prepared back to created ... ";
AreaEffectSimulation::ExplosionCluster copy = eaData;
copy.id(m_data.id());
copy.effectStart().reset(); // 'remove' -> prepared back to created
int ret = doExplosionClusterModifyRequest(copy);
QVERIFY2(ret != 0, "ERROR, explosionClusterModifyRequest failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " ACTION: prepared back to created ... DONE";
NOTICE_LOG(m_logger) << LOGFUNCTION << " ACTION: prepared back to created ... DONE";
});
}
INFO_LOG(m_logger) << Q_FUNC_INFO << " waiting to make sure, that next step is never reached:";
INFO_LOG(m_logger) << LOGFUNCTION << " waiting to make sure, that next step is never reached:";
if (waitForData([this]() { return m_data.effectStateId() == AreaEffectSimulation::AesEffectState_def::EsActivated;}, 60))
{
ERROR_LOG(m_logger) << "Next step is accidentically reached of explosion cluster with id " << m_data.id();
@@ -1999,27 +1999,27 @@ void ModuleTestExplosionCluster::test_remove_effect_start()
return;
}
INFO_LOG(m_logger) << Q_FUNC_INFO << " object effectState: " << m_data.effectStateId();
INFO_LOG(m_logger) << LOGFUNCTION << " object effectState: " << m_data.effectStateId();
QVERIFY2(m_data.effectStateId() == AreaEffectSimulation::AesEffectState_def::EsCreated, "ERROR, ExplosionCluster in wrong state");
dumpCnt();
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_create_bulk()
{
if (!ModuleTestExplosionCluster::m_enable_create_bulk)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase, has to be call explicitly called by user";
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase, has to be call explicitly called by user";
return;
}
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_89(), "ERROR, checkParticipant_89 failed!!");
@@ -2048,19 +2048,19 @@ void ModuleTestExplosionCluster::test_create_bulk()
QVERIFY2(m_data.effectStateId() == AreaEffectSimulation::AesEffectState_def::EsExpired, "ERROR, effectStateId failed!!");
dumpCnt();
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_point_geometry_bldg_1104()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1104"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
setFilterForBldgState(bldgName);
@@ -2099,7 +2099,7 @@ void ModuleTestExplosionCluster::test_point_geometry_bldg_1104()
QVERIFY2(checkBldgStates({29}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_point_geometry_bldg_1104_SMArt_Proximity()
@@ -2111,12 +2111,12 @@ void ModuleTestExplosionCluster::test_point_geometry_bldg_1104_SMArt_Proximity()
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1104_SMArt"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
setFilterForBldgState(bldgName);
@@ -2126,10 +2126,10 @@ void ModuleTestExplosionCluster::test_point_geometry_bldg_1104_SMArt_Proximity()
eaData.chargeStruct().igniterTypeId(s_IgniterTypeImpact);
eaData.chargeStruct().chargeTypeId(374); // 374: isSMArt=true ; radius == 25, diameter == 50m
NOTICE_LOG(m_logger) << Q_FUNC_INFO << "Vor eaData.flightCurve().is_set()";
NOTICE_LOG(m_logger) << LOGFUNCTION << "Vor eaData.flightCurve().is_set()";
QVERIFY2(eaData.flightCurve().is_set(), "ERROR, flightCurve() not set !!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << "Nach eaData.flightCurve().is_set()";
NOTICE_LOG(m_logger) << LOGFUNCTION << "Nach eaData.flightCurve().is_set()";
eaData.flightCurve().get().requestedRelativePeakHeight(500);
@@ -2163,19 +2163,19 @@ void ModuleTestExplosionCluster::test_point_geometry_bldg_1104_SMArt_Proximity()
QVERIFY2(checkBldgStates({29}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_bldg_1104_OC()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1104"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
// QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
// setFilterForBldgState(bldgName);
@@ -2209,7 +2209,7 @@ void ModuleTestExplosionCluster::test_bldg_1104_OC()
waitForEffectStates(__LINE__, 5, 60, 30);
QVERIFY2(m_data.effectStateId() == AreaEffectSimulation::AesEffectState_def::EsExpired, "ERROR, effectStateId failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
// light -> no curve
@@ -2217,12 +2217,12 @@ void ModuleTestExplosionCluster::test_point_geometry_bldg_1104_light()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1104"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
setFilterForBldgState(bldgName);
@@ -2267,19 +2267,19 @@ void ModuleTestExplosionCluster::test_point_geometry_bldg_1104_light()
// QVERIFY2(checkBldgStates({29}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster:: test_point_geometry_bldg_1104_single_effect_only()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1104"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
// // QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
setFilterForBldgState(bldgName);
@@ -2298,7 +2298,7 @@ void ModuleTestExplosionCluster:: test_point_geometry_bldg_1104_single_effect_on
const QPointF impactPointF(0.20256382834808495, 0.9161105453111705);
request.impactPosition(Core::GeoPosition2D(impactPointF.x(), impactPointF.y()));
INFO_LOG(m_logger) << Q_FUNC_INFO << " requested impact position = " << LtsCoordTrans::UtmCoordinate::fromGeographic(impactPointF).mgrs();
INFO_LOG(m_logger) << LOGFUNCTION << " requested impact position = " << LtsCoordTrans::UtmCoordinate::fromGeographic(impactPointF).mgrs();
request.chargeTypeId(371);
request.externalId(815);
@@ -2313,19 +2313,19 @@ void ModuleTestExplosionCluster:: test_point_geometry_bldg_1104_single_effect_on
QVERIFY2(checkBldgStates({29}, QString::fromStdString(request.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_bldg_1104_effects_only()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1104"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
// QVERIFY2(checkParticipant_5(), "ERROR, checkParticipant_5 failed!!");
setFilterForBldgState(bldgName);
@@ -2364,7 +2364,7 @@ void ModuleTestExplosionCluster::test_bldg_1104_effects_only()
QVERIFY2(m_counterDds.cntTrajectory == 0, "ERROR, cnt failed!!"); // 4 impacts -> 4 trajectory
std::vector<AreaEffectSimulation::SingleEffect>&singleEffects = m_effects.singleEffects();
for (const AreaEffectSimulation::SingleEffect &se : std::as_const(singleEffects))
for (const AreaEffectSimulation::SingleEffect &se : qAsConst(singleEffects))
{
// Since there is no trajectory, no intersection is calculated.
// Therefore the impacts are on the ground.
@@ -2376,7 +2376,7 @@ void ModuleTestExplosionCluster::test_bldg_1104_effects_only()
QVERIFY2(checkBldgStates({29, 59, 82, 94}, QString::fromStdString(eaData.name())), "ERROR, checkBldgStates failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
@@ -2385,12 +2385,12 @@ void ModuleTestExplosionCluster::test_vulcano_bldg_1104()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1104_VULCANO"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_99(), "ERROR, checkParticipant_99 failed!!");
@@ -2435,19 +2435,19 @@ void ModuleTestExplosionCluster::test_vulcano_bldg_1104()
QVERIFY2(m_counterDds.cntAtExplosionClusterGunToTargetLine == 1, "ERROR, cnt failed!!");
QVERIFY2(m_counterDds.cntExplosionClusterEffects == 1, "ERROR, cnt failed!!");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_vulcano_bldg_1104_withTargetModify()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1104_VULCANO"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_99(), "ERROR, checkParticipant_99 failed!!");
@@ -2494,7 +2494,7 @@ void ModuleTestExplosionCluster::test_vulcano_bldg_1104_withTargetModify()
const qint64 nowMsec = QDateTime::currentMSecsSinceEpoch();
const qint64 distMsec = startTimeMsec - nowMsec;
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " TIMER 1 "
NOTICE_LOG(m_logger) << LOGFUNCTION << " TIMER 1 "
<< ", effectStart (impactTime) = " << startTimeMsec
<< ", nowMsec = " << nowMsec
<< ", distMsec = " << distMsec;
@@ -2503,7 +2503,7 @@ void ModuleTestExplosionCluster::test_vulcano_bldg_1104_withTargetModify()
int delayMsec = 5000; // distMsec - 5000;
QTimer::singleShot(distMsec - delayMsec, this, [this] () { // local static is captured implicit by gcc and for MSVS
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " TIMER 2 ";
NOTICE_LOG(m_logger) << LOGFUNCTION << " TIMER 2 ";
QPointF newTargetPosGeo = s_newTargetPosUtm_1.geographic();
@@ -2511,9 +2511,9 @@ void ModuleTestExplosionCluster::test_vulcano_bldg_1104_withTargetModify()
request.aesItemId(m_data.id());
request.positions().emplace_back(Core::GeoPosition(newTargetPosGeo.x(), newTargetPosGeo.y(), 123));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " TIMER 2, doExplosionClusterTargetPositionsModify ...";
NOTICE_LOG(m_logger) << LOGFUNCTION << " TIMER 2, doExplosionClusterTargetPositionsModify ...";
doExplosionClusterTargetPositionsModify(request);
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " TIMER 2, doExplosionClusterTargetPositionsModify ... DONE";
NOTICE_LOG(m_logger) << LOGFUNCTION << " TIMER 2, doExplosionClusterTargetPositionsModify ... DONE";
});
});
@@ -2536,22 +2536,22 @@ void ModuleTestExplosionCluster::test_vulcano_bldg_1104_withTargetModify()
const LtsCoordTrans::UtmCoordinate &seUtmPos = LtsCoordTrans::UtmCoordinate::fromGeographic(seGeoPos.lon(), seGeoPos.lat());
int dist = LtsCoordTrans::distance(s_newTargetPosUtm_1, seUtmPos);
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " dist = " << dist;
NOTICE_LOG(m_logger) << LOGFUNCTION << " dist = " << dist;
}
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
void ModuleTestExplosionCluster::test_vulcano_bldg_1104_withTargetModify2()
{
if (m_traingAreaId != s_TraingAreaId_Altmark)
{
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " skip testcase due to m_traingAreaId = " << m_traingAreaId;
return;
}
const QString bldgName(QStringLiteral("bldg_1104_VULCANO"));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " START, m_traingAreaId = " << m_traingAreaId;
NOTICE_LOG(m_logger) << LOGFUNCTION << " START, m_traingAreaId = " << m_traingAreaId;
QVERIFY2(checkParticipant_99(), "ERROR, checkParticipant_99 failed!!");
@@ -2601,7 +2601,7 @@ void ModuleTestExplosionCluster::test_vulcano_bldg_1104_withTargetModify2()
const qint64 nowMsec = QDateTime::currentMSecsSinceEpoch();
const qint64 distMsec = startTimeMsec - nowMsec;
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " TIMER 1 "
NOTICE_LOG(m_logger) << LOGFUNCTION << " TIMER 1 "
<< ", effectStart (impactTime) = " << startTimeMsec
<< ", nowMsec = " << nowMsec
<< ", distMsec = " << distMsec;
@@ -2612,7 +2612,7 @@ void ModuleTestExplosionCluster::test_vulcano_bldg_1104_withTargetModify2()
// Timer _BEFORE_ EffectStart
const int delayMsec_1 = distMsec - offset;
QTimer::singleShot(delayMsec_1, this, [this] () { // local static is captured implicit by gcc and for MSVS
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " TIMER 2 ";
NOTICE_LOG(m_logger) << LOGFUNCTION << " TIMER 2 ";
QPointF newTargetPosGeo = s_newTargetPosUtm_1.geographic();
// ^
@@ -2621,15 +2621,15 @@ void ModuleTestExplosionCluster::test_vulcano_bldg_1104_withTargetModify2()
request.aesItemId(m_data.id());
request.positions().emplace_back(Core::GeoPosition(newTargetPosGeo.x(), newTargetPosGeo.y(), 123));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " TIMER 2, doExplosionClusterTargetPositionsModify ...";
NOTICE_LOG(m_logger) << LOGFUNCTION << " TIMER 2, doExplosionClusterTargetPositionsModify ...";
doExplosionClusterTargetPositionsModify(request);
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " TIMER 2, doExplosionClusterTargetPositionsModify ... DONE";
NOTICE_LOG(m_logger) << LOGFUNCTION << " TIMER 2, doExplosionClusterTargetPositionsModify ... DONE";
});
// Timer _AFTER_ EffectStart
const int delayMsec_2 = distMsec + offset;
QTimer::singleShot(delayMsec_2, this, [this] () { // local static is captured implicit by gcc and for MSVS
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " TIMER 3 ";
NOTICE_LOG(m_logger) << LOGFUNCTION << " TIMER 3 ";
QPointF newTargetPosGeo = s_newTargetPosUtm_2.geographic();
// ^
@@ -2638,9 +2638,9 @@ void ModuleTestExplosionCluster::test_vulcano_bldg_1104_withTargetModify2()
request.aesItemId(m_data.id());
request.positions().emplace_back(Core::GeoPosition(newTargetPosGeo.x(), newTargetPosGeo.y(), 124));
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " TIMER 3, doExplosionClusterTargetPositionsModify ...";
NOTICE_LOG(m_logger) << LOGFUNCTION << " TIMER 3, doExplosionClusterTargetPositionsModify ...";
doExplosionClusterTargetPositionsModify(request);
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " TIMER 3, doExplosionClusterTargetPositionsModify ... DONE";
NOTICE_LOG(m_logger) << LOGFUNCTION << " TIMER 3, doExplosionClusterTargetPositionsModify ... DONE";
});
});
@@ -2670,7 +2670,7 @@ void ModuleTestExplosionCluster::test_vulcano_bldg_1104_withTargetModify2()
// compare with s_newTargetPosUtm_1, not s_newTargetPosUtm_2:
int dist = LtsCoordTrans::distance(s_newTargetPosUtm_1, seUtmPos);
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " dist = " << dist;
NOTICE_LOG(m_logger) << LOGFUNCTION << " dist = " << dist;
QVERIFY2(dist < 100, "ERROR, m_effects failed");
}
@@ -2687,11 +2687,11 @@ void ModuleTestExplosionCluster::test_vulcano_bldg_1104_withTargetModify2()
const LtsCoordTrans::UtmCoordinate &bottomLeftUtm = LtsCoordTrans::UtmCoordinate::fromGeographic(bottomLeftGeo.lon(), bottomLeftGeo.lat());
const int distBL = LtsCoordTrans::distance(s_newTargetPosUtm_1, bottomLeftUtm);
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " itemViewBoundary.dist = " << distBL;
NOTICE_LOG(m_logger) << LOGFUNCTION << " itemViewBoundary.dist = " << distBL;
QVERIFY2(distBL < 100, "ERROR, itemViewBoundary failed");
NOTICE_LOG(m_logger) << Q_FUNC_INFO << " END";
NOTICE_LOG(m_logger) << LOGFUNCTION << " END";
}
@@ -2741,7 +2741,7 @@ int main(int argc, char *argv[])
--argc;
const QStringList &slPositionalArgs = options.positionalArguments();
for (const QString &item : std::as_const(slPositionalArgs))
for (const QString &item : qAsConst(slPositionalArgs))
std::cout << " item = " << item << std::endl;
// enable_create_bulk only if it´s explicitly called by user:
@@ -21,11 +21,11 @@
#include <Plugins/ProjectDataManagement/pdm_data_plugin_interface.h>
#include <ExerciseManagement/exm_dtc.h>
#include <ParticipantManagement/ppm.hpp>
#include <ParticipantManagement/ppm_dtc.h>
#include <ParticipantManagement/ppm_ftc.h>
#include <QtCore/QCoreApplication>
#include <QCoreApplication>
#include <QtTest/QTest>
#include <memory>
@@ -59,8 +59,6 @@ public:
ModuleTestExplosionCluster(int domainId, int exerciseId);
protected:
NGL::INGLLogger &m_logger;
void onSetSimulatedPositionReply(const Core::FunctionReplyObject &replyObject) override;
void onSetSimulatedParticipantFormationReply(const Core::FunctionReplyObject &replyObject) override;
void onExplosionClusterModifyReply(const Core::FunctionReplyObject &replyObject) override;
@@ -241,4 +239,6 @@ private:
}
}
m_counterDds;
LOGGER_T m_logger;
};