v-chhsieh 6e197a8ba5 MdePkg: Add Google Test Library and Protocol
Mock Libraries:
 MdePkg\Test\Mock\Library\GoogleTest\MockCpuLib
 MdePkg\Test\Mock\Library\GoogleTest\MockPciSegmentLib
 MdePkg\Test\Mock\Library\GoogleTest\MockReportStatusCodeLib
 MdePkg\Test\Mock\Library\GoogleTest\MockSmmServicesTableLib

Mock Protocol:
 MdePkg\Test\Mock\Include\GoogleTest\Protocol\MockMpService.h

Signed-off-by: jack Hsieh <v-chhsieh@microsoft.com>
Cc: Maintainer Shruti Gupta <shrugupt@microsoft.com>
Cc: Reviewer   Shruti Gupta <shrugupt@microsoft.com>
2024-10-17 17:03:15 +00:00

65 lines
964 B
C

/** @file MockCpuLib.h
Google Test mocks for the CPU Library
Copyright (c) Microsoft Corporation.
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
#ifndef MOCK_CPU_LIB_H_
#define MOCK_CPU_LIB_H_
#include <Library/GoogleTestLib.h>
#include <Library/FunctionMockLib.h>
extern "C" {
#include <Uefi.h>
}
struct MockCpuLib {
MOCK_INTERFACE_DECLARATION (MockCpuLib);
MOCK_FUNCTION_DECLARATION (
VOID,
CpuSleep,
(
)
);
MOCK_FUNCTION_DECLARATION (
VOID,
CpuFlushTlb,
(
)
);
MOCK_FUNCTION_DECLARATION (
VOID,
InitializeFloatingPointUnits,
(
)
);
MOCK_FUNCTION_DECLARATION (
BOOLEAN,
StandardSignatureIsAuthenticAMD,
(
)
);
MOCK_FUNCTION_DECLARATION (
UINT32,
GetCpuFamilyModel,
(
)
);
MOCK_FUNCTION_DECLARATION (
UINT8,
GetCpuSteppingId,
(
)
);
};
#endif