feat(cpp-object-oriented-modular-refactoring): step 3 - foundation-google-style

This commit is contained in:
KOKO\Mimi
2026-08-16 04:26:14 +09:00
parent 2628ed3488
commit 042edadffb
93 changed files with 3144 additions and 3175 deletions
@@ -501,9 +501,9 @@ private:
void expectFailureCode(
const fesa::Result<fesa::test::Mitc4ComparisonReport>& result,
const std::string& code) {
ASSERT_FALSE(result.hasValue());
ASSERT_FALSE(result.status().diagnostics().empty());
EXPECT_EQ(result.status().diagnostics().front().code, code);
ASSERT_FALSE(result.HasValue());
ASSERT_FALSE(result.GetStatus().Diagnostics().empty());
EXPECT_EQ(result.GetStatus().Diagnostics().front().code, code);
}
const fesa::test::Mitc4RowDecision* findRow(
@@ -550,8 +550,8 @@ TEST(Mitc4ReferenceComparison, MapsTrimmedHeaderAndSixComponentsBySourceIdentity
auto result = fesa::test::Mitc4ReferenceComparison::compare(
fixture.referenceCase());
ASSERT_TRUE(result.hasValue());
const auto& report = result.value();
ASSERT_TRUE(result.HasValue());
const auto& report = result.Value();
ASSERT_TRUE(report.passed);
ASSERT_EQ(report.rows.size(), 12U);
EXPECT_EQ(report.rows[0U].sourceNodeLabel, 1);
@@ -676,8 +676,8 @@ TEST(Mitc4ReferenceComparison, AppliesFixedAbsoluteToleranceWithoutScaleClampOrR
auto result = fesa::test::Mitc4ReferenceComparison::compare(
fixture.referenceCase());
ASSERT_TRUE(result.hasValue());
const auto& report = result.value();
ASSERT_TRUE(result.HasValue());
const auto& report = result.Value();
EXPECT_FALSE(report.passed);
const auto* u1Zero = findRow(report, 1, "U1");
const auto* u1Scaled = findRow(report, 2, "U1");
@@ -717,8 +717,8 @@ TEST(Mitc4ReferenceComparison, RotationExceedanceWarnsWithoutBlockingTranslation
auto result = fesa::test::Mitc4ReferenceComparison::compare(
fixture.referenceCase());
ASSERT_TRUE(result.hasValue());
const auto& report = result.value();
ASSERT_TRUE(result.HasValue());
const auto& report = result.Value();
EXPECT_TRUE(report.passed);
ASSERT_EQ(report.warnings.size(), 1U);
EXPECT_EQ(report.warnings[0U].code, "rotation-reference-exceedance");
@@ -744,8 +744,8 @@ TEST(Mitc4ReferenceComparison, ReportsMetricsVectorsWorstRowAndJsonDeterministic
auto result = fesa::test::Mitc4ReferenceComparison::compare(
fixture.referenceCase());
ASSERT_TRUE(result.hasValue());
const auto& report = result.value();
ASSERT_TRUE(result.HasValue());
const auto& report = result.Value();
ASSERT_TRUE(report.passed);
ASSERT_EQ(report.metrics.size(), 6U);
ASSERT_EQ(report.vectorMetrics.size(), 2U);
@@ -771,11 +771,11 @@ TEST(Mitc4ReferenceComparison, ReportsMetricsVectorsWorstRowAndJsonDeterministic
ASSERT_TRUE(
fesa::test::Mitc4ReferenceComparison::writeDeterministicJson(
report, jsonA)
.isOk());
.IsOk());
ASSERT_TRUE(
fesa::test::Mitc4ReferenceComparison::writeDeterministicJson(
report, jsonB)
.isOk());
.IsOk());
const std::string first = readBytes(jsonA);
EXPECT_EQ(first, readBytes(jsonB));
for (const char* key : {
@@ -798,8 +798,8 @@ TEST(Mitc4ReferenceComparison, RequiresOnlyDeclaredInputCsvAndHdf5) {
(std::vector<std::string>{"case.inp", "displacements.csv", "results.h5"}));
auto result = fesa::test::Mitc4ReferenceComparison::compare(
fixture.referenceCase());
ASSERT_TRUE(result.hasValue());
EXPECT_TRUE(result.value().passed);
ASSERT_TRUE(result.HasValue());
EXPECT_TRUE(result.Value().passed);
}
} // namespace