PEL: Create FailingMTMS section for new PELs
When a PEL is created from an OpenBMC event log, add the FailingMTMS
section to the PEL. This contains the machine type, model, and serial
number fields.
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Change-Id: I8d08e6dda00260efebd2c6ac165270d2aaf98d67
diff --git a/test/openpower-pels/pel_test.cpp b/test/openpower-pels/pel_test.cpp
index 1f9917a..b0c6528 100644
--- a/test/openpower-pels/pel_test.cpp
+++ b/test/openpower-pels/pel_test.cpp
@@ -1,6 +1,7 @@
#include "elog_entry.hpp"
#include "extensions/openpower-pels/generic.hpp"
#include "extensions/openpower-pels/pel.hpp"
+#include "mocks.hpp"
#include "pel_utils.hpp"
#include <filesystem>
@@ -121,9 +122,10 @@
regEntry.src.reasonCode = 0x1234;
AdditionalData ad;
+ MockDataInterface dataIface;
- PEL pel{regEntry, 42, timestamp, phosphor::logging::Entry::Level::Error,
- ad};
+ PEL pel{regEntry, 42, timestamp, phosphor::logging::Entry::Level::Error, ad,
+ dataIface};
EXPECT_TRUE(pel.valid());
EXPECT_EQ(pel.privateHeader()->obmcLogID(), 42);
@@ -131,8 +133,6 @@
EXPECT_EQ(pel.primarySRC().value()->asciiString(),
"BD051234 ");
-
- // Add more checks as more sections are added
}
// Test that we'll create Generic optional sections for sections that