Reviewed-by: Michael D Kinney <michael.d.kin...@intel.com>
> -----Original Message----- > From: Douglas Flick [MSFT] <doug.e...@gmail.com> > Sent: Thursday, January 25, 2024 1:55 PM > To: devel@edk2.groups.io > Cc: Douglas Flick [MSFT] <doug.e...@gmail.com>; Kinney, Michael D > <michael.d.kin...@intel.com>; Liming Gao <gaolim...@byosoft.com.cn>; > Liu, Zhiguang <zhiguang....@intel.com> > Subject: [PATCH v2 12/15] MdePkg: Test: Add gRT_GetTime Google Test Mock > > This adds support for GetTime Google Test Mock > > Cc: Michael D Kinney <michael.d.kin...@intel.com> > Cc: Liming Gao <gaolim...@byosoft.com.cn> > Cc: Zhiguang Liu <zhiguang....@intel.com> > > Signed-off-by: Doug Flick [MSFT] <doug.e...@gmail.com> > --- > .../GoogleTest/Library/MockUefiRuntimeServicesTableLib.h | 7 +++++++ > .../MockUefiRuntimeServicesTableLib.cpp | 5 +++-- > 2 files changed, 10 insertions(+), 2 deletions(-) > > diff --git > a/MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiRuntimeServicesTab > leLib.h > b/MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiRuntimeServicesTab > leLib.h > index 241abc55c079..bcc902cb93c2 100644 > --- > a/MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiRuntimeServicesTab > leLib.h > +++ > b/MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiRuntimeServicesTab > leLib.h > @@ -37,6 +37,13 @@ struct MockUefiRuntimeServicesTableLib { > IN UINTN DataSize, > > IN VOID *Data) > > ); > > + > > + MOCK_FUNCTION_DECLARATION ( > > + EFI_STATUS, > > + gRT_GetTime, > > + (OUT EFI_TIME *Time, > > + OUT EFI_TIME_CAPABILITIES *Capabilities OPTIONAL) > > + ); > > }; > > > > #endif > > diff --git > a/MdePkg/Test/Mock/Library/GoogleTest/MockUefiRuntimeServicesTableLib/Mo > ckUefiRuntimeServicesTableLib.cpp > b/MdePkg/Test/Mock/Library/GoogleTest/MockUefiRuntimeServicesTableLib/Mo > ckUefiRuntimeServicesTableLib.cpp > index 14296b0ccb88..8d2afd5dd63a 100644 > --- > a/MdePkg/Test/Mock/Library/GoogleTest/MockUefiRuntimeServicesTableLib/Mo > ckUefiRuntimeServicesTableLib.cpp > +++ > b/MdePkg/Test/Mock/Library/GoogleTest/MockUefiRuntimeServicesTableLib/Mo > ckUefiRuntimeServicesTableLib.cpp > @@ -10,11 +10,12 @@ MOCK_INTERFACE_DEFINITION > (MockUefiRuntimeServicesTableLib); > > > MOCK_FUNCTION_DEFINITION (MockUefiRuntimeServicesTableLib, > gRT_GetVariable, 5, EFIAPI); > > MOCK_FUNCTION_DEFINITION (MockUefiRuntimeServicesTableLib, > gRT_SetVariable, 5, EFIAPI); > > +MOCK_FUNCTION_DEFINITION (MockUefiRuntimeServicesTableLib, gRT_GetTime, > 2, EFIAPI); > > > > static EFI_RUNTIME_SERVICES localRt = { > > - { 0 }, // EFI_TABLE_HEADER > > + { 0 }, // EFI_TABLE_HEADER > > > > - NULL, // EFI_GET_TIME > > + gRT_GetTime, // EFI_GET_TIME > > NULL, // EFI_SET_TIME > > NULL, // EFI_GET_WAKEUP_TIME > > NULL, // EFI_SET_WAKEUP_TIME > > -- > 2.43.0 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#114625): https://edk2.groups.io/g/devel/message/114625 Mute This Topic: https://groups.io/mt/103964988/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/leave/9847357/21656/1706620634/xyzzy [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-