From 2c11e4561c42331decf12e373c0839f40116c936 Mon Sep 17 00:00:00 2001 From: Gunnar Mills Date: Mon, 14 Aug 2017 16:13:32 -0500 Subject: Add tests for elog Change-Id: I58a6ac714cfa80462ab53d4487dc727e40038b06 Signed-off-by: Gunnar Mills --- src/example/test.yaml | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ src/test/Makefile.am | 8 +++++++- 2 files changed, 55 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/example/test.yaml b/src/example/test.yaml index 1ba22a4..43755f3 100644 --- a/src/example/test.yaml +++ b/src/example/test.yaml @@ -223,6 +223,54 @@ severity: INFO message: Testing... +- name: test string elog + class: callback + callback: elog + paths: test path group + properties: test string property group + error: xyz::openbmc_project::Common::Error::InvalidArgument + metadata: + - name: xyz::openbmc_project::Common::InvalidArgument::ARGUMENT_NAME + value: testing... + type: string + - name: xyz::openbmc_project::Common::InvalidArgument::ARGUMENT_VALUE + value: testing... + type: string + +- name: test int32 elog + class: callback + callback: elog + paths: test path group + properties: test string property group + error: xyz::openbmc_project::Common::Callout::Error::Device + metadata: + - name: xyz::openbmc_project::Common::Callout::Device::CALLOUT_ERRNO + value: 123 + type: int32 + - name: xyz::openbmc_project::Common::Callout::Device::CALLOUT_DEVICE_PATH + value: testing... + type: string + +- name: test int64 elog + class: callback + callback: elog + paths: test path group + properties: test string property group + error: xyz::openbmc_project::Common::File::Error::Seek + metadata: + - name: xyz::openbmc_project::Common::File::Seek::OFFSET + value: 123 + type: int64 + - name: xyz::openbmc_project::Common::File::Seek::WHENCE + value: 123 + type: int32 + - name: xyz::openbmc_project::Common::File::Seek::ERRNO + value: 123 + type: int32 + - name: xyz::openbmc_project::Common::File::Seek::PATH + value: testing... + type: string + - name: test method class: callback callback: method diff --git a/src/test/Makefile.am b/src/test/Makefile.am index a5d7405..7dddccd 100644 --- a/src/test/Makefile.am +++ b/src/test/Makefile.am @@ -185,9 +185,15 @@ callbacktest_SOURCES = \ callbacktest.cpp callbacktest_CXXFLAGS = \ $(gtest_cflags) + $(SDBUSPLUS_CFLAGS) \ + $(PHOSPHOR_DBUS_INTERFACES_CFLAGS) \ + $(PHOSPHOR_LOGGING_CFLAGS) callbacktest_LDFLAGS = \ $(OESDK_TESTCASE_FLAGS) callbacktest_LDADD = \ ${gtest_ldadd} \ ${SDBUSPLUS_LIBS} \ - $(builddir)/../journal.o + $(PHOSPHOR_DBUS_INTERFACES_LIBS) \ + $(PHOSPHOR_LOGGING_LIBS) \ + $(builddir)/../journal.o \ + $(builddir)/../elog.o -- cgit v1.2.1