Apply clang-format to Lts/Common and DTC/enum headers
- Formatted all CodeGen module files (9 files) - Formatted LtsAppDescriptor module files - Formatted LtsAppManager/AppChooser files - Applied clang-format to all DTC and enum headers across modules - Removed coordTransTests from CommonUnitTestsPlaceholder (moved to tests/) Cosmetic changes only, no functional modifications. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
848 files changed
+89305
-100020
No files matched your search
-12
@@ -1,12 +0,0 @@
|
||||
#include "mocks/MockCoordTrans.h"
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
TEST(CoordTransGTest, ForwardInverseRoundtrip) {
|
||||
auto p = MockCoordTrans::forward(1.2345, 2.3456);
|
||||
EXPECT_NEAR(p.first, 1.2345 * 111000.0, 1e-6);
|
||||
EXPECT_NEAR(p.second, 2.3456 * 111000.0, 1e-6);
|
||||
|
||||
auto inv = MockCoordTrans::inverse(p.first, p.second);
|
||||
EXPECT_NEAR(inv.first, 1.2345, 1e-9);
|
||||
EXPECT_NEAR(inv.second, 2.3456, 1e-9);
|
||||
}
|
||||
-15
@@ -1,15 +0,0 @@
|
||||
#include <QtTest/QtTest>
|
||||
#include "mocks/MockCoordTrans.h"
|
||||
|
||||
class CoordTransSmoke : public QObject {
|
||||
Q_OBJECT
|
||||
private slots:
|
||||
void testForward() {
|
||||
auto p = MockCoordTrans::forward(10.0, 20.0);
|
||||
QVERIFY(qFuzzyCompare(p.first, 10.0 * 111000.0));
|
||||
QVERIFY(qFuzzyCompare(p.second, 20.0 * 111000.0));
|
||||
}
|
||||
};
|
||||
|
||||
QTEST_MAIN(CoordTransSmoke)
|
||||
#include "coordTransTests_smoke.moc"
|
||||
-16
@@ -1,16 +0,0 @@
|
||||
#pragma once
|
||||
#include <utility>
|
||||
|
||||
// Minimal realistic mock for coordinate transforms used during migration.
|
||||
// Forward conversion returns approximate meters using lat/lon*111000.
|
||||
class MockCoordTrans {
|
||||
public:
|
||||
// approximate forward: (lat, lon) -> (x_m, y_m)
|
||||
static std::pair<double,double> forward(double lat_deg, double lon_deg) {
|
||||
return {lat_deg * 111000.0, lon_deg * 111000.0};
|
||||
}
|
||||
// approximate inverse
|
||||
static std::pair<double,double> inverse(double x_m, double y_m) {
|
||||
return {x_m / 111000.0, y_m / 111000.0};
|
||||
}
|
||||
};
|
||||
Reference in new issue
Block a user