Update test case to verify error inheritance

Ensure inherited metadata shows up in the journal.

Change-Id: I4b6c30e1439bf6a799fbb78d8e8eb6754141b568
Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
diff --git a/logging_test.cpp b/logging_test.cpp
index 6a5f07f..1920f36 100644
--- a/logging_test.cpp
+++ b/logging_test.cpp
@@ -83,9 +83,9 @@
                 example::xyz::openbmc_project::Example::TestErrorOne::
                     FILE_NAME("elog_test_3.txt"),
                 example::xyz::openbmc_project::Example::TestErrorTwo::
-                    DEV_ADDR(0xDEAD),
+                    DEV_ADDR(0xDEADDEAD),
                 example::xyz::openbmc_project::Example::TestErrorTwo::
-                    DEV_ID(0x100),
+                    DEV_ID(100),
                 example::xyz::openbmc_project::Example::TestErrorTwo::
                     DEV_NAME("test case 3"));
     }
@@ -115,6 +115,21 @@
     if(rc)
         return(rc);
 
+    rc = validate_journal(TestErrorTwo::DEV_ADDR::str_short,
+                          "0xDEADDEAD");
+    if(rc)
+        return(rc);
+
+    rc = validate_journal(TestErrorTwo::DEV_ID::str_short,
+                          "100");
+    if(rc)
+        return(rc);
+
+    rc = validate_journal(TestErrorTwo::DEV_NAME::str_short,
+                          "test case 3");
+    if(rc)
+        return(rc);
+
     // TEST 4 - Create error log with previous entry use
     number = 0x9876;
     try
@@ -122,8 +137,8 @@
         elog<TestErrorOne>(TestErrorOne::ERRNUM(number),
                            prev_entry<TestErrorOne::FILE_PATH>(),
                            TestErrorOne::FILE_NAME("elog_test_4.txt"),
-                           TestErrorTwo::DEV_ADDR(0xDEAD),
-                           TestErrorTwo::DEV_ID(0x100),
+                           TestErrorTwo::DEV_ADDR(0xDEADDEAD),
+                           TestErrorTwo::DEV_ID(100),
                            TestErrorTwo::DEV_NAME("test case 4"));
     }
     catch (elogExceptionBase& e)
@@ -150,6 +165,21 @@
     if(rc)
         return(rc);
 
+    rc = validate_journal(TestErrorTwo::DEV_ADDR::str_short,
+                          "0xDEADDEAD");
+    if(rc)
+        return(rc);
+
+    rc = validate_journal(TestErrorTwo::DEV_ID::str_short,
+                          "100");
+    if(rc)
+        return(rc);
+
+    rc = validate_journal(TestErrorTwo::DEV_NAME::str_short,
+                          "test case 4");
+    if(rc)
+        return(rc);
+
     // Compile fail tests
 
     // Simple test to prove we fail to compile due to missing param