From: "VivianNK" <vnowkakeane@linux.microsoft.com>
To: devel@edk2.groups.io
Cc: Michael D Kinney <michael.d.kinney@intel.com>,
Liming Gao <gaoliming@byosoft.com.cn>,
Zhiguang Liu <zhiguang.liu@intel.com>
Subject: [edk2-devel] [PATCH v2 4/7] MdePkg: Apply uncrustify formatting to relevant files
Date: Wed, 16 Aug 2023 14:15:19 -0700 [thread overview]
Message-ID: <20230816211523.12-5-vnowkakeane@linux.microsoft.com> (raw)
In-Reply-To: <20230816211523.12-1-vnowkakeane@linux.microsoft.com>
Apply uncrustify formatting to GoogleTest cpp and header files.
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Zhiguang Liu <zhiguang.liu@intel.com>
Signed-off-by: Vivian Nowka-Keane <vnowkakeane@linux.microsoft.com>
---
MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTests32.cpp | 114 ++--
MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTests64.cpp | 114 ++--
MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/TestBaseSafeIntLib.cpp | 563 ++++++++++----------
MdePkg/Test/Mock/Include/GoogleTest/Library/MockHobLib.h | 6 +-
MdePkg/Test/Mock/Include/GoogleTest/Library/MockPeiServicesLib.h | 6 +-
MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiLib.h | 4 +-
MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiRuntimeServicesTableLib.h | 4 +-
MdePkg/Test/Mock/Library/GoogleTest/MockHobLib/MockHobLib.cpp | 40 +-
MdePkg/Test/Mock/Library/GoogleTest/MockPeiServicesLib/MockPeiServicesLib.cpp | 52 +-
MdePkg/Test/Mock/Library/GoogleTest/MockUefiLib/MockUefiLib.cpp | 6 +-
MdePkg/Test/Mock/Library/GoogleTest/MockUefiRuntimeServicesTableLib/MockUefiRuntimeServicesTableLib.cpp | 12 +-
11 files changed, 463 insertions(+), 458 deletions(-)
diff --git a/MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTests32.cpp b/MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTests32.cpp
index 6fbf302c1c5e..3f50f0cd99db 100644
--- a/MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTests32.cpp
+++ b/MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTests32.cpp
@@ -14,10 +14,10 @@ extern "C" {
#include <Library/SafeIntLib.h>
}
-TEST(ConversionTestSuite, TestSafeInt32ToUintn) {
+TEST (ConversionTestSuite, TestSafeInt32ToUintn) {
RETURN_STATUS Status;
- INT32 Operand;
- UINTN Result;
+ INT32 Operand;
+ UINTN Result;
//
// If Operand is non-negative, then it's a cast
@@ -36,10 +36,10 @@ TEST(ConversionTestSuite, TestSafeInt32ToUintn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint32ToIntn) {
+TEST (ConversionTestSuite, TestSafeUint32ToIntn) {
RETURN_STATUS Status;
- UINT32 Operand;
- INTN Result;
+ UINT32 Operand;
+ INTN Result;
//
// If Operand is <= MAX_INTN, then it's a cast
@@ -58,10 +58,10 @@ TEST(ConversionTestSuite, TestSafeUint32ToIntn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeIntnToInt32) {
+TEST (ConversionTestSuite, TestSafeIntnToInt32) {
RETURN_STATUS Status;
- INTN Operand;
- INT32 Result;
+ INTN Operand;
+ INT32 Result;
//
// INTN is same as INT32 in IA32, so this is just a cast
@@ -73,10 +73,10 @@ TEST(ConversionTestSuite, TestSafeIntnToInt32) {
ASSERT_EQ (0x5bababab, Result);
}
-TEST(ConversionTestSuite, TestSafeIntnToUint32) {
+TEST (ConversionTestSuite, TestSafeIntnToUint32) {
RETURN_STATUS Status;
- INTN Operand;
- UINT32 Result;
+ INTN Operand;
+ UINT32 Result;
//
// If Operand is non-negative, then it's a cast
@@ -95,10 +95,10 @@ TEST(ConversionTestSuite, TestSafeIntnToUint32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUintnToUint32) {
+TEST (ConversionTestSuite, TestSafeUintnToUint32) {
RETURN_STATUS Status;
- UINTN Operand;
- UINT32 Result;
+ UINTN Operand;
+ UINT32 Result;
//
// UINTN is same as UINT32 in IA32, so this is just a cast
@@ -110,10 +110,10 @@ TEST(ConversionTestSuite, TestSafeUintnToUint32) {
ASSERT_EQ (0xabababab, Result);
}
-TEST(ConversionTestSuite, TestSafeUintnToIntn) {
+TEST (ConversionTestSuite, TestSafeUintnToIntn) {
RETURN_STATUS Status;
- UINTN Operand;
- INTN Result;
+ UINTN Operand;
+ INTN Result;
//
// If Operand is <= MAX_INTN, then it's a cast
@@ -132,10 +132,10 @@ TEST(ConversionTestSuite, TestSafeUintnToIntn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUintnToInt64) {
+TEST (ConversionTestSuite, TestSafeUintnToInt64) {
RETURN_STATUS Status;
- UINTN Operand;
- INT64 Result;
+ UINTN Operand;
+ INT64 Result;
//
// UINTN is same as UINT32 in IA32, and UINT32 is a subset of
@@ -148,10 +148,10 @@ TEST(ConversionTestSuite, TestSafeUintnToInt64) {
ASSERT_EQ (0xabababab, Result);
}
-TEST(ConversionTestSuite, TestSafeInt64ToIntn) {
+TEST (ConversionTestSuite, TestSafeInt64ToIntn) {
RETURN_STATUS Status;
- INT64 Operand;
- INTN Result;
+ INT64 Operand;
+ INTN Result;
//
// If Operand is between MIN_INTN and MAX_INTN2 inclusive, then it's a cast
@@ -179,10 +179,10 @@ TEST(ConversionTestSuite, TestSafeInt64ToIntn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt64ToUintn) {
+TEST (ConversionTestSuite, TestSafeInt64ToUintn) {
RETURN_STATUS Status;
- INT64 Operand;
- UINTN Result;
+ INT64 Operand;
+ UINTN Result;
//
// If Operand is between 0 and MAX_UINTN inclusive, then it's a cast
@@ -205,10 +205,10 @@ TEST(ConversionTestSuite, TestSafeInt64ToUintn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint64ToIntn) {
+TEST (ConversionTestSuite, TestSafeUint64ToIntn) {
RETURN_STATUS Status;
- UINT64 Operand;
- INTN Result;
+ UINT64 Operand;
+ INTN Result;
//
// If Operand is <= MAX_INTN, then it's a cast
@@ -227,10 +227,10 @@ TEST(ConversionTestSuite, TestSafeUint64ToIntn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint64ToUintn) {
+TEST (ConversionTestSuite, TestSafeUint64ToUintn) {
RETURN_STATUS Status;
- UINT64 Operand;
- UINTN Result;
+ UINT64 Operand;
+ UINTN Result;
//
// If Operand is <= MAX_UINTN, then it's a cast
@@ -249,11 +249,11 @@ TEST(ConversionTestSuite, TestSafeUint64ToUintn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeUintnAdd) {
+TEST (AdditionSubtractionTestSuite, TestSafeUintnAdd) {
RETURN_STATUS Status;
- UINTN Augend;
- UINTN Addend;
- UINTN Result;
+ UINTN Augend;
+ UINTN Addend;
+ UINTN Result;
//
// If the result of addition doesn't overflow MAX_UINTN, then it's addition
@@ -274,11 +274,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeUintnAdd) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeIntnAdd) {
+TEST (AdditionSubtractionTestSuite, TestSafeIntnAdd) {
RETURN_STATUS Status;
- INTN Augend;
- INTN Addend;
- INTN Result;
+ INTN Augend;
+ INTN Addend;
+ INTN Result;
//
// If the result of addition doesn't overflow MAX_INTN
@@ -311,11 +311,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeIntnAdd) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeUintnSub) {
+TEST (AdditionSubtractionTestSuite, TestSafeUintnSub) {
RETURN_STATUS Status;
- UINTN Minuend;
- UINTN Subtrahend;
- UINTN Result;
+ UINTN Minuend;
+ UINTN Subtrahend;
+ UINTN Result;
//
// If Minuend >= Subtrahend, then it's subtraction
@@ -336,11 +336,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeUintnSub) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeIntnSub) {
+TEST (AdditionSubtractionTestSuite, TestSafeIntnSub) {
RETURN_STATUS Status;
- INTN Minuend;
- INTN Subtrahend;
- INTN Result;
+ INTN Minuend;
+ INTN Subtrahend;
+ INTN Result;
//
// If the result of subtractions doesn't overflow MAX_INTN or
@@ -373,11 +373,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeIntnSub) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(MultiplicationTestSuite, TestSafeUintnMult) {
+TEST (MultiplicationTestSuite, TestSafeUintnMult) {
RETURN_STATUS Status;
- UINTN Multiplicand;
- UINTN Multiplier;
- UINTN Result;
+ UINTN Multiplicand;
+ UINTN Multiplier;
+ UINTN Result;
//
// If the result of multiplication doesn't overflow MAX_UINTN, it will succeed
@@ -398,11 +398,11 @@ TEST(MultiplicationTestSuite, TestSafeUintnMult) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(MultiplicationTestSuite, TestSafeIntnMult) {
+TEST (MultiplicationTestSuite, TestSafeIntnMult) {
RETURN_STATUS Status;
- INTN Multiplicand;
- INTN Multiplier;
- INTN Result;
+ INTN Multiplicand;
+ INTN Multiplier;
+ INTN Result;
//
// If the result of multiplication doesn't overflow MAX_INTN and doesn't
diff --git a/MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTests64.cpp b/MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTests64.cpp
index 6fb0710cfed6..6efdd3be7c5e 100644
--- a/MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTests64.cpp
+++ b/MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/SafeIntLibUintnIntnUnitTests64.cpp
@@ -14,10 +14,10 @@ extern "C" {
#include <Library/SafeIntLib.h>
}
-TEST(ConversionTestSuite, TestSafeInt32ToUintn) {
+TEST (ConversionTestSuite, TestSafeInt32ToUintn) {
RETURN_STATUS Status;
- INT32 Operand;
- UINTN Result;
+ INT32 Operand;
+ UINTN Result;
//
// If Operand is non-negative, then it's a cast
@@ -36,10 +36,10 @@ TEST(ConversionTestSuite, TestSafeInt32ToUintn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint32ToIntn) {
+TEST (ConversionTestSuite, TestSafeUint32ToIntn) {
RETURN_STATUS Status;
- UINT32 Operand;
- INTN Result;
+ UINT32 Operand;
+ INTN Result;
//
// For x64, INTN is same as INT64 which is a superset of INT32
@@ -56,10 +56,10 @@ TEST(ConversionTestSuite, TestSafeUint32ToIntn) {
ASSERT_EQ (0xabababab, Result);
}
-TEST(ConversionTestSuite, TestSafeIntnToInt32) {
+TEST (ConversionTestSuite, TestSafeIntnToInt32) {
RETURN_STATUS Status;
- INTN Operand;
- INT32 Result;
+ INTN Operand;
+ INT32 Result;
//
// If Operand is between MIN_INT32 and MAX_INT32 inclusive, then it's a cast
@@ -87,10 +87,10 @@ TEST(ConversionTestSuite, TestSafeIntnToInt32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeIntnToUint32) {
+TEST (ConversionTestSuite, TestSafeIntnToUint32) {
RETURN_STATUS Status;
- INTN Operand;
- UINT32 Result;
+ INTN Operand;
+ UINT32 Result;
//
// If Operand is between 0 and MAX_UINT32 inclusive, then it's a cast
@@ -113,10 +113,10 @@ TEST(ConversionTestSuite, TestSafeIntnToUint32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUintnToUint32) {
+TEST (ConversionTestSuite, TestSafeUintnToUint32) {
RETURN_STATUS Status;
- UINTN Operand;
- UINT32 Result;
+ UINTN Operand;
+ UINT32 Result;
//
// If Operand is <= MAX_UINT32, then it's a cast
@@ -135,10 +135,10 @@ TEST(ConversionTestSuite, TestSafeUintnToUint32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUintnToIntn) {
+TEST (ConversionTestSuite, TestSafeUintnToIntn) {
RETURN_STATUS Status;
- UINTN Operand;
- INTN Result;
+ UINTN Operand;
+ INTN Result;
//
// If Operand is <= MAX_INTN (0x7fff_ffff_ffff_ffff), then it's a cast
@@ -157,10 +157,10 @@ TEST(ConversionTestSuite, TestSafeUintnToIntn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUintnToInt64) {
+TEST (ConversionTestSuite, TestSafeUintnToInt64) {
RETURN_STATUS Status;
- UINTN Operand;
- INT64 Result;
+ UINTN Operand;
+ INT64 Result;
//
// If Operand is <= MAX_INT64, then it's a cast
@@ -179,10 +179,10 @@ TEST(ConversionTestSuite, TestSafeUintnToInt64) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt64ToIntn) {
+TEST (ConversionTestSuite, TestSafeInt64ToIntn) {
RETURN_STATUS Status;
- INT64 Operand;
- INTN Result;
+ INT64 Operand;
+ INTN Result;
//
// INTN is same as INT64 in x64, so this is just a cast
@@ -194,10 +194,10 @@ TEST(ConversionTestSuite, TestSafeInt64ToIntn) {
ASSERT_EQ (0x5babababefefefef, Result);
}
-TEST(ConversionTestSuite, TestSafeInt64ToUintn) {
+TEST (ConversionTestSuite, TestSafeInt64ToUintn) {
RETURN_STATUS Status;
- INT64 Operand;
- UINTN Result;
+ INT64 Operand;
+ UINTN Result;
//
// If Operand is non-negative, then it's a cast
@@ -216,10 +216,10 @@ TEST(ConversionTestSuite, TestSafeInt64ToUintn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint64ToIntn) {
+TEST (ConversionTestSuite, TestSafeUint64ToIntn) {
RETURN_STATUS Status;
- UINT64 Operand;
- INTN Result;
+ UINT64 Operand;
+ INTN Result;
//
// If Operand is <= MAX_INTN (0x7fff_ffff_ffff_ffff), then it's a cast
@@ -238,10 +238,10 @@ TEST(ConversionTestSuite, TestSafeUint64ToIntn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint64ToUintn) {
+TEST (ConversionTestSuite, TestSafeUint64ToUintn) {
RETURN_STATUS Status;
- UINT64 Operand;
- UINTN Result;
+ UINT64 Operand;
+ UINTN Result;
//
// UINTN is same as UINT64 in x64, so this is just a cast
@@ -253,11 +253,11 @@ TEST(ConversionTestSuite, TestSafeUint64ToUintn) {
ASSERT_EQ (0xababababefefefef, Result);
}
-TEST(AdditionSubtractionTestSuite, TestSafeUintnAdd) {
+TEST (AdditionSubtractionTestSuite, TestSafeUintnAdd) {
RETURN_STATUS Status;
- UINTN Augend;
- UINTN Addend;
- UINTN Result;
+ UINTN Augend;
+ UINTN Addend;
+ UINTN Result;
//
// If the result of addition doesn't overflow MAX_UINTN, then it's addition
@@ -278,11 +278,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeUintnAdd) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeIntnAdd) {
+TEST (AdditionSubtractionTestSuite, TestSafeIntnAdd) {
RETURN_STATUS Status;
- INTN Augend;
- INTN Addend;
- INTN Result;
+ INTN Augend;
+ INTN Addend;
+ INTN Result;
//
// If the result of addition doesn't overflow MAX_INTN
@@ -315,11 +315,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeIntnAdd) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeUintnSub) {
+TEST (AdditionSubtractionTestSuite, TestSafeUintnSub) {
RETURN_STATUS Status;
- UINTN Minuend;
- UINTN Subtrahend;
- UINTN Result;
+ UINTN Minuend;
+ UINTN Subtrahend;
+ UINTN Result;
//
// If Minuend >= Subtrahend, then it's subtraction
@@ -340,11 +340,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeUintnSub) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeIntnSub) {
+TEST (AdditionSubtractionTestSuite, TestSafeIntnSub) {
RETURN_STATUS Status;
- INTN Minuend;
- INTN Subtrahend;
- INTN Result;
+ INTN Minuend;
+ INTN Subtrahend;
+ INTN Result;
//
// If the result of subtractions doesn't overflow MAX_INTN or
@@ -377,11 +377,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeIntnSub) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(MultiplicationTestSuite, TestSafeUintnMult) {
+TEST (MultiplicationTestSuite, TestSafeUintnMult) {
RETURN_STATUS Status;
- UINTN Multiplicand;
- UINTN Multiplier;
- UINTN Result;
+ UINTN Multiplicand;
+ UINTN Multiplier;
+ UINTN Result;
//
// If the result of multiplication doesn't overflow MAX_UINTN, it will succeed
@@ -402,11 +402,11 @@ TEST(MultiplicationTestSuite, TestSafeUintnMult) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(MultiplicationTestSuite, TestSafeIntnMult) {
+TEST (MultiplicationTestSuite, TestSafeIntnMult) {
RETURN_STATUS Status;
- INTN Multiplicand;
- INTN Multiplier;
- INTN Result;
+ INTN Multiplicand;
+ INTN Multiplier;
+ INTN Result;
//
// If the result of multiplication doesn't overflow MAX_INTN and doesn't
diff --git a/MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/TestBaseSafeIntLib.cpp b/MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/TestBaseSafeIntLib.cpp
index 1fd51067a1f3..857ab4d1d36c 100644
--- a/MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/TestBaseSafeIntLib.cpp
+++ b/MdePkg/Test/GoogleTest/Library/BaseSafeIntLib/TestBaseSafeIntLib.cpp
@@ -15,10 +15,10 @@ extern "C" {
//
// Conversion function tests:
//
-TEST(ConversionTestSuite, TestSafeInt8ToUint8) {
+TEST (ConversionTestSuite, TestSafeInt8ToUint8) {
RETURN_STATUS Status;
- INT8 Operand;
- UINT8 Result;
+ INT8 Operand;
+ UINT8 Result;
//
// Positive UINT8 should result in just a cast
@@ -37,10 +37,10 @@ TEST(ConversionTestSuite, TestSafeInt8ToUint8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt8ToUint16) {
+TEST (ConversionTestSuite, TestSafeInt8ToUint16) {
RETURN_STATUS Status;
- INT8 Operand;
- UINT16 Result;
+ INT8 Operand;
+ UINT16 Result;
//
// Positive UINT8 should result in just a cast
@@ -59,10 +59,10 @@ TEST(ConversionTestSuite, TestSafeInt8ToUint16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt8ToUint32) {
+TEST (ConversionTestSuite, TestSafeInt8ToUint32) {
RETURN_STATUS Status;
- INT8 Operand;
- UINT32 Result;
+ INT8 Operand;
+ UINT32 Result;
//
// Positive UINT8 should result in just a cast
@@ -81,10 +81,10 @@ TEST(ConversionTestSuite, TestSafeInt8ToUint32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt8ToUintn) {
+TEST (ConversionTestSuite, TestSafeInt8ToUintn) {
RETURN_STATUS Status;
- INT8 Operand;
- UINTN Result;
+ INT8 Operand;
+ UINTN Result;
//
// Positive UINT8 should result in just a cast
@@ -103,10 +103,10 @@ TEST(ConversionTestSuite, TestSafeInt8ToUintn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt8ToUint64) {
+TEST (ConversionTestSuite, TestSafeInt8ToUint64) {
RETURN_STATUS Status;
- INT8 Operand;
- UINT64 Result;
+ INT8 Operand;
+ UINT64 Result;
//
// Positive UINT8 should result in just a cast
@@ -125,10 +125,10 @@ TEST(ConversionTestSuite, TestSafeInt8ToUint64) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint8ToInt8) {
+TEST (ConversionTestSuite, TestSafeUint8ToInt8) {
RETURN_STATUS Status;
- UINT8 Operand;
- INT8 Result;
+ UINT8 Operand;
+ INT8 Result;
//
// Operand <= 0x7F (MAX_INT8) should result in a cast
@@ -147,10 +147,10 @@ TEST(ConversionTestSuite, TestSafeUint8ToInt8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint8ToChar8) {
+TEST (ConversionTestSuite, TestSafeUint8ToChar8) {
RETURN_STATUS Status;
- UINT8 Operand;
- CHAR8 Result;
+ UINT8 Operand;
+ CHAR8 Result;
//
// CHAR8 is typedefed as char, which by default is signed, thus
@@ -174,10 +174,10 @@ TEST(ConversionTestSuite, TestSafeUint8ToChar8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt16ToInt8) {
+TEST (ConversionTestSuite, TestSafeInt16ToInt8) {
RETURN_STATUS Status;
- INT16 Operand;
- INT8 Result;
+ INT16 Operand;
+ INT8 Result;
//
// If Operand is between MIN_INT8 and MAX_INT8 inclusive, then it's a cast
@@ -205,10 +205,10 @@ TEST(ConversionTestSuite, TestSafeInt16ToInt8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt16ToChar8) {
+TEST (ConversionTestSuite, TestSafeInt16ToChar8) {
RETURN_STATUS Status;
- INT16 Operand;
- CHAR8 Result;
+ INT16 Operand;
+ CHAR8 Result;
//
// CHAR8 is typedefed as char, which may be signed or unsigned based
@@ -252,10 +252,10 @@ TEST(ConversionTestSuite, TestSafeInt16ToChar8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt16ToUint8) {
+TEST (ConversionTestSuite, TestSafeInt16ToUint8) {
RETURN_STATUS Status;
- INT16 Operand;
- UINT8 Result;
+ INT16 Operand;
+ UINT8 Result;
//
// If Operand is between 0 and MAX_INT8 inclusive, then it's a cast
@@ -278,10 +278,10 @@ TEST(ConversionTestSuite, TestSafeInt16ToUint8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt16ToUint16) {
+TEST (ConversionTestSuite, TestSafeInt16ToUint16) {
RETURN_STATUS Status;
- INT16 Operand = 0x5b5b;
- UINT16 Result = 0;
+ INT16 Operand = 0x5b5b;
+ UINT16 Result = 0;
//
// If Operand is non-negative, then it's a cast
@@ -298,10 +298,10 @@ TEST(ConversionTestSuite, TestSafeInt16ToUint16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt16ToUint32) {
+TEST (ConversionTestSuite, TestSafeInt16ToUint32) {
RETURN_STATUS Status;
- INT16 Operand;
- UINT32 Result;
+ INT16 Operand;
+ UINT32 Result;
//
// If Operand is non-negative, then it's a cast
@@ -320,10 +320,10 @@ TEST(ConversionTestSuite, TestSafeInt16ToUint32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt16ToUintn) {
+TEST (ConversionTestSuite, TestSafeInt16ToUintn) {
RETURN_STATUS Status;
- INT16 Operand;
- UINTN Result;
+ INT16 Operand;
+ UINTN Result;
//
// If Operand is non-negative, then it's a cast
@@ -342,10 +342,10 @@ TEST(ConversionTestSuite, TestSafeInt16ToUintn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt16ToUint64) {
+TEST (ConversionTestSuite, TestSafeInt16ToUint64) {
RETURN_STATUS Status;
- INT16 Operand;
- UINT64 Result;
+ INT16 Operand;
+ UINT64 Result;
//
// If Operand is non-negative, then it's a cast
@@ -364,10 +364,10 @@ TEST(ConversionTestSuite, TestSafeInt16ToUint64) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint16ToInt8) {
+TEST (ConversionTestSuite, TestSafeUint16ToInt8) {
RETURN_STATUS Status;
- UINT16 Operand;
- INT8 Result;
+ UINT16 Operand;
+ INT8 Result;
//
// If Operand is <= MAX_INT8, it's a cast
@@ -386,10 +386,10 @@ TEST(ConversionTestSuite, TestSafeUint16ToInt8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint16ToChar8) {
+TEST (ConversionTestSuite, TestSafeUint16ToChar8) {
RETURN_STATUS Status;
- UINT16 Operand;
- CHAR8 Result;
+ UINT16 Operand;
+ CHAR8 Result;
// CHAR8 is typedefed as char, which by default is signed, thus
// CHAR8 is same as INT8, so same tests as above:
@@ -411,10 +411,10 @@ TEST(ConversionTestSuite, TestSafeUint16ToChar8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint16ToUint8) {
+TEST (ConversionTestSuite, TestSafeUint16ToUint8) {
RETURN_STATUS Status;
- UINT16 Operand;
- UINT8 Result;
+ UINT16 Operand;
+ UINT8 Result;
//
// If Operand is <= MAX_UINT8 (0xff), it's a cast
@@ -433,10 +433,10 @@ TEST(ConversionTestSuite, TestSafeUint16ToUint8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint16ToInt16) {
+TEST (ConversionTestSuite, TestSafeUint16ToInt16) {
RETURN_STATUS Status;
- UINT16 Operand;
- INT16 Result;
+ UINT16 Operand;
+ INT16 Result;
//
// If Operand is <= MAX_INT16 (0x7fff), it's a cast
@@ -455,10 +455,10 @@ TEST(ConversionTestSuite, TestSafeUint16ToInt16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt32ToInt8) {
+TEST (ConversionTestSuite, TestSafeInt32ToInt8) {
RETURN_STATUS Status;
- INT32 Operand;
- INT8 Result;
+ INT32 Operand;
+ INT8 Result;
//
// If Operand is between MIN_INT8 and MAX_INT8 inclusive, then it's a cast
@@ -486,10 +486,10 @@ TEST(ConversionTestSuite, TestSafeInt32ToInt8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt32ToChar8) {
+TEST (ConversionTestSuite, TestSafeInt32ToChar8) {
RETURN_STATUS Status;
- INT32 Operand;
- CHAR8 Result;
+ INT32 Operand;
+ CHAR8 Result;
//
// CHAR8 is typedefed as char, which may be signed or unsigned based
@@ -533,10 +533,10 @@ TEST(ConversionTestSuite, TestSafeInt32ToChar8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt32ToUint8) {
+TEST (ConversionTestSuite, TestSafeInt32ToUint8) {
RETURN_STATUS Status;
- INT32 Operand;
- UINT8 Result;
+ INT32 Operand;
+ UINT8 Result;
//
// If Operand is between 0 and MAX_INT8 inclusive, then it's a cast
@@ -563,10 +563,10 @@ TEST(ConversionTestSuite, TestSafeInt32ToUint8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt32ToInt16) {
+TEST (ConversionTestSuite, TestSafeInt32ToInt16) {
RETURN_STATUS Status;
- INT32 Operand;
- INT16 Result;
+ INT32 Operand;
+ INT16 Result;
//
// If Operand is between MIN_INT16 and MAX_INT16 inclusive, then it's a cast
@@ -594,10 +594,10 @@ TEST(ConversionTestSuite, TestSafeInt32ToInt16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt32ToUint16) {
+TEST (ConversionTestSuite, TestSafeInt32ToUint16) {
RETURN_STATUS Status;
- INT32 Operand;
- UINT16 Result;
+ INT32 Operand;
+ UINT16 Result;
//
// If Operand is between 0 and MAX_UINT16 inclusive, then it's a cast
@@ -624,10 +624,10 @@ TEST(ConversionTestSuite, TestSafeInt32ToUint16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt32ToUint32) {
+TEST (ConversionTestSuite, TestSafeInt32ToUint32) {
RETURN_STATUS Status;
- INT32 Operand;
- UINT32 Result;
+ INT32 Operand;
+ UINT32 Result;
//
// If Operand is non-negative, then it's a cast
@@ -646,10 +646,10 @@ TEST(ConversionTestSuite, TestSafeInt32ToUint32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt32ToUint64) {
+TEST (ConversionTestSuite, TestSafeInt32ToUint64) {
RETURN_STATUS Status;
- INT32 Operand;
- UINT64 Result;
+ INT32 Operand;
+ UINT64 Result;
//
// If Operand is non-negative, then it's a cast
@@ -668,10 +668,10 @@ TEST(ConversionTestSuite, TestSafeInt32ToUint64) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint32ToInt8) {
+TEST (ConversionTestSuite, TestSafeUint32ToInt8) {
RETURN_STATUS Status;
- UINT32 Operand;
- INT8 Result;
+ UINT32 Operand;
+ INT8 Result;
//
// If Operand is <= MAX_INT8, then it's a cast
@@ -690,10 +690,10 @@ TEST(ConversionTestSuite, TestSafeUint32ToInt8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint32ToChar8) {
+TEST (ConversionTestSuite, TestSafeUint32ToChar8) {
RETURN_STATUS Status;
- UINT32 Operand;
- CHAR8 Result;
+ UINT32 Operand;
+ CHAR8 Result;
// CHAR8 is typedefed as char, which by default is signed, thus
// CHAR8 is same as INT8, so same tests as above:
@@ -715,10 +715,10 @@ TEST(ConversionTestSuite, TestSafeUint32ToChar8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint32ToUint8) {
+TEST (ConversionTestSuite, TestSafeUint32ToUint8) {
RETURN_STATUS Status;
- UINT32 Operand;
- UINT8 Result;
+ UINT32 Operand;
+ UINT8 Result;
//
// If Operand is <= MAX_UINT8, then it's a cast
@@ -737,10 +737,10 @@ TEST(ConversionTestSuite, TestSafeUint32ToUint8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint32ToInt16) {
+TEST (ConversionTestSuite, TestSafeUint32ToInt16) {
RETURN_STATUS Status;
- UINT32 Operand;
- INT16 Result;
+ UINT32 Operand;
+ INT16 Result;
//
// If Operand is <= MAX_INT16, then it's a cast
@@ -759,10 +759,10 @@ TEST(ConversionTestSuite, TestSafeUint32ToInt16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint32ToUint16) {
+TEST (ConversionTestSuite, TestSafeUint32ToUint16) {
RETURN_STATUS Status;
- UINT32 Operand;
- UINT16 Result;
+ UINT32 Operand;
+ UINT16 Result;
//
// If Operand is <= MAX_UINT16, then it's a cast
@@ -781,10 +781,10 @@ TEST(ConversionTestSuite, TestSafeUint32ToUint16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint32ToInt32) {
+TEST (ConversionTestSuite, TestSafeUint32ToInt32) {
RETURN_STATUS Status;
- UINT32 Operand;
- INT32 Result;
+ UINT32 Operand;
+ INT32 Result;
//
// If Operand is <= MAX_INT32, then it's a cast
@@ -803,10 +803,10 @@ TEST(ConversionTestSuite, TestSafeUint32ToInt32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeIntnToInt8) {
+TEST (ConversionTestSuite, TestSafeIntnToInt8) {
RETURN_STATUS Status;
- INTN Operand;
- INT8 Result;
+ INTN Operand;
+ INT8 Result;
//
// If Operand is between MIN_INT8 and MAX_INT8 inclusive, then it's a cast
@@ -834,10 +834,10 @@ TEST(ConversionTestSuite, TestSafeIntnToInt8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeIntnToChar8) {
+TEST (ConversionTestSuite, TestSafeIntnToChar8) {
RETURN_STATUS Status;
- INTN Operand;
- CHAR8 Result;
+ INTN Operand;
+ CHAR8 Result;
//
// CHAR8 is typedefed as char, which may be signed or unsigned based
@@ -881,10 +881,10 @@ TEST(ConversionTestSuite, TestSafeIntnToChar8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeIntnToUint8) {
+TEST (ConversionTestSuite, TestSafeIntnToUint8) {
RETURN_STATUS Status;
- INTN Operand;
- UINT8 Result;
+ INTN Operand;
+ UINT8 Result;
//
// If Operand is between 0 and MAX_UINT8 inclusive, then it's a cast
@@ -907,10 +907,10 @@ TEST(ConversionTestSuite, TestSafeIntnToUint8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeIntnToInt16) {
+TEST (ConversionTestSuite, TestSafeIntnToInt16) {
RETURN_STATUS Status;
- INTN Operand;
- INT16 Result;
+ INTN Operand;
+ INT16 Result;
//
// If Operand is between MIN_INT16 and MAX_INT16 inclusive, then it's a cast
@@ -938,10 +938,10 @@ TEST(ConversionTestSuite, TestSafeIntnToInt16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeIntnToUint16) {
+TEST (ConversionTestSuite, TestSafeIntnToUint16) {
RETURN_STATUS Status;
- INTN Operand;
- UINT16 Result;
+ INTN Operand;
+ UINT16 Result;
//
// If Operand is between 0 and MAX_UINT16 inclusive, then it's a cast
@@ -964,10 +964,10 @@ TEST(ConversionTestSuite, TestSafeIntnToUint16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeIntnToUintn) {
+TEST (ConversionTestSuite, TestSafeIntnToUintn) {
RETURN_STATUS Status;
- INTN Operand;
- UINTN Result;
+ INTN Operand;
+ UINTN Result;
//
// If Operand is non-negative, then it's a cast
@@ -986,10 +986,10 @@ TEST(ConversionTestSuite, TestSafeIntnToUintn) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeIntnToUint64) {
+TEST (ConversionTestSuite, TestSafeIntnToUint64) {
RETURN_STATUS Status;
- INTN Operand;
- UINT64 Result;
+ INTN Operand;
+ UINT64 Result;
//
// If Operand is non-negative, then it's a cast
@@ -1008,10 +1008,10 @@ TEST(ConversionTestSuite, TestSafeIntnToUint64) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUintnToInt8) {
+TEST (ConversionTestSuite, TestSafeUintnToInt8) {
RETURN_STATUS Status;
- UINTN Operand;
- INT8 Result;
+ UINTN Operand;
+ INT8 Result;
//
// If Operand is <= MAX_INT8, then it's a cast
@@ -1030,10 +1030,10 @@ TEST(ConversionTestSuite, TestSafeUintnToInt8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUintnToChar8) {
+TEST (ConversionTestSuite, TestSafeUintnToChar8) {
RETURN_STATUS Status;
- UINTN Operand;
- CHAR8 Result;
+ UINTN Operand;
+ CHAR8 Result;
// CHAR8 is typedefed as char, which by default is signed, thus
// CHAR8 is same as INT8, so same tests as above:
@@ -1055,10 +1055,10 @@ TEST(ConversionTestSuite, TestSafeUintnToChar8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUintnToUint8) {
+TEST (ConversionTestSuite, TestSafeUintnToUint8) {
RETURN_STATUS Status;
- UINTN Operand;
- UINT8 Result;
+ UINTN Operand;
+ UINT8 Result;
//
// If Operand is <= MAX_UINT8, then it's a cast
@@ -1077,10 +1077,10 @@ TEST(ConversionTestSuite, TestSafeUintnToUint8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUintnToInt16) {
+TEST (ConversionTestSuite, TestSafeUintnToInt16) {
RETURN_STATUS Status;
- UINTN Operand;
- INT16 Result;
+ UINTN Operand;
+ INT16 Result;
//
// If Operand is <= MAX_INT16, then it's a cast
@@ -1099,10 +1099,10 @@ TEST(ConversionTestSuite, TestSafeUintnToInt16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUintnToUint16) {
+TEST (ConversionTestSuite, TestSafeUintnToUint16) {
RETURN_STATUS Status;
- UINTN Operand;
- UINT16 Result;
+ UINTN Operand;
+ UINT16 Result;
//
// If Operand is <= MAX_UINT16, then it's a cast
@@ -1121,10 +1121,10 @@ TEST(ConversionTestSuite, TestSafeUintnToUint16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUintnToInt32) {
+TEST (ConversionTestSuite, TestSafeUintnToInt32) {
RETURN_STATUS Status;
- UINTN Operand;
- INT32 Result;
+ UINTN Operand;
+ INT32 Result;
//
// If Operand is <= MAX_INT32, then it's a cast
@@ -1143,10 +1143,10 @@ TEST(ConversionTestSuite, TestSafeUintnToInt32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt64ToInt8) {
+TEST (ConversionTestSuite, TestSafeInt64ToInt8) {
RETURN_STATUS Status;
- INT64 Operand;
- INT8 Result;
+ INT64 Operand;
+ INT8 Result;
//
// If Operand is between MIN_INT8 and MAX_INT8 inclusive, then it's a cast
@@ -1174,10 +1174,10 @@ TEST(ConversionTestSuite, TestSafeInt64ToInt8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt64ToChar8) {
+TEST (ConversionTestSuite, TestSafeInt64ToChar8) {
RETURN_STATUS Status;
- INT64 Operand;
- CHAR8 Result;
+ INT64 Operand;
+ CHAR8 Result;
//
// CHAR8 is typedefed as char, which may be signed or unsigned based
@@ -1221,10 +1221,10 @@ TEST(ConversionTestSuite, TestSafeInt64ToChar8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt64ToUint8) {
+TEST (ConversionTestSuite, TestSafeInt64ToUint8) {
RETURN_STATUS Status;
- INT64 Operand;
- UINT8 Result;
+ INT64 Operand;
+ UINT8 Result;
//
// If Operand is between 0 and MAX_UINT8 inclusive, then it's a cast
@@ -1247,10 +1247,10 @@ TEST(ConversionTestSuite, TestSafeInt64ToUint8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt64ToInt16) {
+TEST (ConversionTestSuite, TestSafeInt64ToInt16) {
RETURN_STATUS Status;
- INT64 Operand;
- INT16 Result;
+ INT64 Operand;
+ INT16 Result;
//
// If Operand is between MIN_INT16 and MAX_INT16 inclusive, then it's a cast
@@ -1278,10 +1278,10 @@ TEST(ConversionTestSuite, TestSafeInt64ToInt16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt64ToUint16) {
+TEST (ConversionTestSuite, TestSafeInt64ToUint16) {
RETURN_STATUS Status;
- INT64 Operand;
- UINT16 Result;
+ INT64 Operand;
+ UINT16 Result;
//
// If Operand is between 0 and MAX_UINT16 inclusive, then it's a cast
@@ -1304,10 +1304,10 @@ TEST(ConversionTestSuite, TestSafeInt64ToUint16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt64ToInt32) {
+TEST (ConversionTestSuite, TestSafeInt64ToInt32) {
RETURN_STATUS Status;
- INT64 Operand;
- INT32 Result;
+ INT64 Operand;
+ INT32 Result;
//
// If Operand is between MIN_INT32 and MAX_INT32 inclusive, then it's a cast
@@ -1335,10 +1335,10 @@ TEST(ConversionTestSuite, TestSafeInt64ToInt32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt64ToUint32) {
+TEST (ConversionTestSuite, TestSafeInt64ToUint32) {
RETURN_STATUS Status;
- INT64 Operand;
- UINT32 Result;
+ INT64 Operand;
+ UINT32 Result;
//
// If Operand is between 0 and MAX_UINT32 inclusive, then it's a cast
@@ -1361,10 +1361,10 @@ TEST(ConversionTestSuite, TestSafeInt64ToUint32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeInt64ToUint64) {
+TEST (ConversionTestSuite, TestSafeInt64ToUint64) {
RETURN_STATUS Status;
- INT64 Operand;
- UINT64 Result;
+ INT64 Operand;
+ UINT64 Result;
//
// If Operand is non-negative, then it's a cast
@@ -1383,10 +1383,10 @@ TEST(ConversionTestSuite, TestSafeInt64ToUint64) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint64ToInt8) {
+TEST (ConversionTestSuite, TestSafeUint64ToInt8) {
RETURN_STATUS Status;
- UINT64 Operand;
- INT8 Result;
+ UINT64 Operand;
+ INT8 Result;
//
// If Operand is <= MAX_INT8, then it's a cast
@@ -1405,10 +1405,10 @@ TEST(ConversionTestSuite, TestSafeUint64ToInt8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint64ToChar8) {
+TEST (ConversionTestSuite, TestSafeUint64ToChar8) {
RETURN_STATUS Status;
- UINT64 Operand;
- CHAR8 Result;
+ UINT64 Operand;
+ CHAR8 Result;
// CHAR8 is typedefed as char, which by default is signed, thus
// CHAR8 is same as INT8, so same tests as above:
@@ -1430,10 +1430,10 @@ TEST(ConversionTestSuite, TestSafeUint64ToChar8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint64ToUint8) {
+TEST (ConversionTestSuite, TestSafeUint64ToUint8) {
RETURN_STATUS Status;
- UINT64 Operand;
- UINT8 Result;
+ UINT64 Operand;
+ UINT8 Result;
//
// If Operand is <= MAX_UINT8, then it's a cast
@@ -1452,10 +1452,10 @@ TEST(ConversionTestSuite, TestSafeUint64ToUint8) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint64ToInt16) {
+TEST (ConversionTestSuite, TestSafeUint64ToInt16) {
RETURN_STATUS Status;
- UINT64 Operand;
- INT16 Result;
+ UINT64 Operand;
+ INT16 Result;
//
// If Operand is <= MAX_INT16, then it's a cast
@@ -1474,10 +1474,10 @@ TEST(ConversionTestSuite, TestSafeUint64ToInt16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint64ToUint16) {
+TEST (ConversionTestSuite, TestSafeUint64ToUint16) {
RETURN_STATUS Status;
- UINT64 Operand;
- UINT16 Result;
+ UINT64 Operand;
+ UINT16 Result;
//
// If Operand is <= MAX_UINT16, then it's a cast
@@ -1496,10 +1496,10 @@ TEST(ConversionTestSuite, TestSafeUint64ToUint16) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint64ToInt32) {
+TEST (ConversionTestSuite, TestSafeUint64ToInt32) {
RETURN_STATUS Status;
- UINT64 Operand;
- INT32 Result;
+ UINT64 Operand;
+ INT32 Result;
//
// If Operand is <= MAX_INT32, then it's a cast
@@ -1518,10 +1518,10 @@ TEST(ConversionTestSuite, TestSafeUint64ToInt32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint64ToUint32) {
+TEST (ConversionTestSuite, TestSafeUint64ToUint32) {
RETURN_STATUS Status;
- UINT64 Operand;
- UINT32 Result;
+ UINT64 Operand;
+ UINT32 Result;
//
// If Operand is <= MAX_UINT32, then it's a cast
@@ -1540,10 +1540,10 @@ TEST(ConversionTestSuite, TestSafeUint64ToUint32) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(ConversionTestSuite, TestSafeUint64ToInt64) {
+TEST (ConversionTestSuite, TestSafeUint64ToInt64) {
RETURN_STATUS Status;
- UINT64 Operand;
- INT64 Result;
+ UINT64 Operand;
+ INT64 Result;
//
// If Operand is <= MAX_INT64, then it's a cast
@@ -1565,11 +1565,11 @@ TEST(ConversionTestSuite, TestSafeUint64ToInt64) {
//
// Addition function tests:
//
-TEST(AdditionSubtractionTestSuite, TestSafeUint8Add) {
+TEST (AdditionSubtractionTestSuite, TestSafeUint8Add) {
RETURN_STATUS Status;
- UINT8 Augend;
- UINT8 Addend;
- UINT8 Result;
+ UINT8 Augend;
+ UINT8 Addend;
+ UINT8 Result;
//
// If the result of addition doesn't overflow MAX_UINT8, then it's addition
@@ -1590,11 +1590,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeUint8Add) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeUint16Add) {
+TEST (AdditionSubtractionTestSuite, TestSafeUint16Add) {
RETURN_STATUS Status;
- UINT16 Augend = 0x3a3a;
- UINT16 Addend = 0x3a3a;
- UINT16 Result = 0;
+ UINT16 Augend = 0x3a3a;
+ UINT16 Addend = 0x3a3a;
+ UINT16 Result = 0;
//
// If the result of addition doesn't overflow MAX_UINT16, then it's addition
@@ -1612,11 +1612,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeUint16Add) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeUint32Add) {
+TEST (AdditionSubtractionTestSuite, TestSafeUint32Add) {
RETURN_STATUS Status;
- UINT32 Augend;
- UINT32 Addend;
- UINT32 Result;
+ UINT32 Augend;
+ UINT32 Addend;
+ UINT32 Result;
//
// If the result of addition doesn't overflow MAX_UINT32, then it's addition
@@ -1637,11 +1637,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeUint32Add) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeUint64Add) {
+TEST (AdditionSubtractionTestSuite, TestSafeUint64Add) {
RETURN_STATUS Status;
- UINT64 Augend;
- UINT64 Addend;
- UINT64 Result;
+ UINT64 Augend;
+ UINT64 Addend;
+ UINT64 Result;
//
// If the result of addition doesn't overflow MAX_UINT64, then it's addition
@@ -1662,11 +1662,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeUint64Add) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeInt8Add) {
+TEST (AdditionSubtractionTestSuite, TestSafeInt8Add) {
RETURN_STATUS Status;
- INT8 Augend;
- INT8 Addend;
- INT8 Result;
+ INT8 Augend;
+ INT8 Addend;
+ INT8 Result;
//
// If the result of addition doesn't overflow MAX_INT8
@@ -1699,11 +1699,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeInt8Add) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeInt16Add) {
+TEST (AdditionSubtractionTestSuite, TestSafeInt16Add) {
RETURN_STATUS Status;
- INT16 Augend;
- INT16 Addend;
- INT16 Result;
+ INT16 Augend;
+ INT16 Addend;
+ INT16 Result;
//
// If the result of addition doesn't overflow MAX_INT16
@@ -1736,11 +1736,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeInt16Add) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeInt32Add) {
+TEST (AdditionSubtractionTestSuite, TestSafeInt32Add) {
RETURN_STATUS Status;
- INT32 Augend;
- INT32 Addend;
- INT32 Result;
+ INT32 Augend;
+ INT32 Addend;
+ INT32 Result;
//
// If the result of addition doesn't overflow MAX_INT32
@@ -1773,11 +1773,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeInt32Add) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeInt64Add) {
+TEST (AdditionSubtractionTestSuite, TestSafeInt64Add) {
RETURN_STATUS Status;
- INT64 Augend;
- INT64 Addend;
- INT64 Result;
+ INT64 Augend;
+ INT64 Addend;
+ INT64 Result;
//
// If the result of addition doesn't overflow MAX_INT64
@@ -1813,11 +1813,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeInt64Add) {
//
// Subtraction function tests:
//
-TEST(AdditionSubtractionTestSuite, TestSafeUint8Sub) {
+TEST (AdditionSubtractionTestSuite, TestSafeUint8Sub) {
RETURN_STATUS Status;
- UINT8 Minuend;
- UINT8 Subtrahend;
- UINT8 Result;
+ UINT8 Minuend;
+ UINT8 Subtrahend;
+ UINT8 Result;
//
// If Minuend >= Subtrahend, then it's subtraction
@@ -1838,11 +1838,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeUint8Sub) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeUint16Sub) {
+TEST (AdditionSubtractionTestSuite, TestSafeUint16Sub) {
RETURN_STATUS Status;
- UINT16 Minuend;
- UINT16 Subtrahend;
- UINT16 Result;
+ UINT16 Minuend;
+ UINT16 Subtrahend;
+ UINT16 Result;
//
// If Minuend >= Subtrahend, then it's subtraction
@@ -1863,11 +1863,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeUint16Sub) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeUint32Sub) {
+TEST (AdditionSubtractionTestSuite, TestSafeUint32Sub) {
RETURN_STATUS Status;
- UINT32 Minuend;
- UINT32 Subtrahend;
- UINT32 Result;
+ UINT32 Minuend;
+ UINT32 Subtrahend;
+ UINT32 Result;
//
// If Minuend >= Subtrahend, then it's subtraction
@@ -1888,11 +1888,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeUint32Sub) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeUint64Sub) {
+TEST (AdditionSubtractionTestSuite, TestSafeUint64Sub) {
RETURN_STATUS Status;
- UINT64 Minuend;
- UINT64 Subtrahend;
- UINT64 Result;
+ UINT64 Minuend;
+ UINT64 Subtrahend;
+ UINT64 Result;
//
// If Minuend >= Subtrahend, then it's subtraction
@@ -1913,11 +1913,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeUint64Sub) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeInt8Sub) {
+TEST (AdditionSubtractionTestSuite, TestSafeInt8Sub) {
RETURN_STATUS Status;
- INT8 Minuend;
- INT8 Subtrahend;
- INT8 Result;
+ INT8 Minuend;
+ INT8 Subtrahend;
+ INT8 Result;
//
// If the result of subtractions doesn't overflow MAX_INT8 or
@@ -1950,11 +1950,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeInt8Sub) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeInt16Sub) {
+TEST (AdditionSubtractionTestSuite, TestSafeInt16Sub) {
RETURN_STATUS Status;
- INT16 Minuend;
- INT16 Subtrahend;
- INT16 Result;
+ INT16 Minuend;
+ INT16 Subtrahend;
+ INT16 Result;
//
// If the result of subtractions doesn't overflow MAX_INT16 or
@@ -1987,11 +1987,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeInt16Sub) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeInt32Sub) {
+TEST (AdditionSubtractionTestSuite, TestSafeInt32Sub) {
RETURN_STATUS Status;
- INT32 Minuend;
- INT32 Subtrahend;
- INT32 Result;
+ INT32 Minuend;
+ INT32 Subtrahend;
+ INT32 Result;
//
// If the result of subtractions doesn't overflow MAX_INT32 or
@@ -2024,11 +2024,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeInt32Sub) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(AdditionSubtractionTestSuite, TestSafeInt64Sub) {
+TEST (AdditionSubtractionTestSuite, TestSafeInt64Sub) {
RETURN_STATUS Status;
- INT64 Minuend;
- INT64 Subtrahend;
- INT64 Result;
+ INT64 Minuend;
+ INT64 Subtrahend;
+ INT64 Result;
//
// If the result of subtractions doesn't overflow MAX_INT64 or
@@ -2064,11 +2064,11 @@ TEST(AdditionSubtractionTestSuite, TestSafeInt64Sub) {
//
// Multiplication function tests:
//
-TEST(MultiplicationTestSuite, TestSafeUint8Mult) {
+TEST (MultiplicationTestSuite, TestSafeUint8Mult) {
RETURN_STATUS Status;
- UINT8 Multiplicand;
- UINT8 Multiplier;
- UINT8 Result;
+ UINT8 Multiplicand;
+ UINT8 Multiplier;
+ UINT8 Result;
//
// If the result of multiplication doesn't overflow MAX_UINT8, it will succeed
@@ -2089,11 +2089,11 @@ TEST(MultiplicationTestSuite, TestSafeUint8Mult) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(MultiplicationTestSuite, TestSafeUint16Mult) {
+TEST (MultiplicationTestSuite, TestSafeUint16Mult) {
RETURN_STATUS Status;
- UINT16 Multiplicand;
- UINT16 Multiplier;
- UINT16 Result;
+ UINT16 Multiplicand;
+ UINT16 Multiplier;
+ UINT16 Result;
//
// If the result of multiplication doesn't overflow MAX_UINT16, it will succeed
@@ -2114,11 +2114,11 @@ TEST(MultiplicationTestSuite, TestSafeUint16Mult) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(MultiplicationTestSuite, TestSafeUint32Mult) {
+TEST (MultiplicationTestSuite, TestSafeUint32Mult) {
RETURN_STATUS Status;
- UINT32 Multiplicand;
- UINT32 Multiplier;
- UINT32 Result;
+ UINT32 Multiplicand;
+ UINT32 Multiplier;
+ UINT32 Result;
//
// If the result of multiplication doesn't overflow MAX_UINT32, it will succeed
@@ -2139,11 +2139,11 @@ TEST(MultiplicationTestSuite, TestSafeUint32Mult) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(MultiplicationTestSuite, TestSafeUint64Mult) {
+TEST (MultiplicationTestSuite, TestSafeUint64Mult) {
RETURN_STATUS Status;
- UINT64 Multiplicand;
- UINT64 Multiplier;
- UINT64 Result;
+ UINT64 Multiplicand;
+ UINT64 Multiplier;
+ UINT64 Result;
//
// If the result of multiplication doesn't overflow MAX_UINT64, it will succeed
@@ -2164,11 +2164,11 @@ TEST(MultiplicationTestSuite, TestSafeUint64Mult) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(MultiplicationTestSuite, TestSafeInt8Mult) {
+TEST (MultiplicationTestSuite, TestSafeInt8Mult) {
RETURN_STATUS Status;
- INT8 Multiplicand;
- INT8 Multiplier;
- INT8 Result;
+ INT8 Multiplicand;
+ INT8 Multiplier;
+ INT8 Result;
//
// If the result of multiplication doesn't overflow MAX_INT8 and doesn't
@@ -2190,11 +2190,11 @@ TEST(MultiplicationTestSuite, TestSafeInt8Mult) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(MultiplicationTestSuite, TestSafeInt16Mult) {
+TEST (MultiplicationTestSuite, TestSafeInt16Mult) {
RETURN_STATUS Status;
- INT16 Multiplicand;
- INT16 Multiplier;
- INT16 Result;
+ INT16 Multiplicand;
+ INT16 Multiplier;
+ INT16 Result;
//
// If the result of multiplication doesn't overflow MAX_INT16 and doesn't
@@ -2216,11 +2216,11 @@ TEST(MultiplicationTestSuite, TestSafeInt16Mult) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(MultiplicationTestSuite, TestSafeInt32Mult) {
+TEST (MultiplicationTestSuite, TestSafeInt32Mult) {
RETURN_STATUS Status;
- INT32 Multiplicand;
- INT32 Multiplier;
- INT32 Result;
+ INT32 Multiplicand;
+ INT32 Multiplier;
+ INT32 Result;
//
// If the result of multiplication doesn't overflow MAX_INT32 and doesn't
@@ -2242,11 +2242,11 @@ TEST(MultiplicationTestSuite, TestSafeInt32Mult) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-TEST(MultiplicationTestSuite, TestSafeInt64Mult) {
+TEST (MultiplicationTestSuite, TestSafeInt64Mult) {
RETURN_STATUS Status;
- INT64 Multiplicand;
- INT64 Multiplier;
- INT64 Result;
+ INT64 Multiplicand;
+ INT64 Multiplier;
+ INT64 Result;
//
// If the result of multiplication doesn't overflow MAX_INT64 and doesn't
@@ -2268,7 +2268,12 @@ TEST(MultiplicationTestSuite, TestSafeInt64Mult) {
ASSERT_EQ (RETURN_BUFFER_TOO_SMALL, Status);
}
-int main(int argc, char* argv[]) {
- testing::InitGoogleTest(&argc, argv);
- return RUN_ALL_TESTS();
+int
+main (
+ int argc,
+ char *argv[]
+ )
+{
+ testing::InitGoogleTest (&argc, argv);
+ return RUN_ALL_TESTS ();
}
diff --git a/MdePkg/Test/Mock/Include/GoogleTest/Library/MockHobLib.h b/MdePkg/Test/Mock/Include/GoogleTest/Library/MockHobLib.h
index 994b8133e5d0..586b479ea5d2 100644
--- a/MdePkg/Test/Mock/Include/GoogleTest/Library/MockHobLib.h
+++ b/MdePkg/Test/Mock/Include/GoogleTest/Library/MockHobLib.h
@@ -11,9 +11,9 @@
#include <Library/GoogleTestLib.h>
#include <Library/FunctionMockLib.h>
extern "C" {
-#include <Pi/PiMultiPhase.h>
-#include <Uefi.h>
-#include <Library/HobLib.h>
+ #include <Pi/PiMultiPhase.h>
+ #include <Uefi.h>
+ #include <Library/HobLib.h>
}
struct MockHobLib {
diff --git a/MdePkg/Test/Mock/Include/GoogleTest/Library/MockPeiServicesLib.h b/MdePkg/Test/Mock/Include/GoogleTest/Library/MockPeiServicesLib.h
index 4a99fec539c0..6a6424d7c6fc 100644
--- a/MdePkg/Test/Mock/Include/GoogleTest/Library/MockPeiServicesLib.h
+++ b/MdePkg/Test/Mock/Include/GoogleTest/Library/MockPeiServicesLib.h
@@ -11,9 +11,9 @@
#include <Library/GoogleTestLib.h>
#include <Library/FunctionMockLib.h>
extern "C" {
-#include <PiPei.h>
-#include <Uefi.h>
-#include <Library/PeiServicesLib.h>
+ #include <PiPei.h>
+ #include <Uefi.h>
+ #include <Library/PeiServicesLib.h>
}
struct MockPeiServicesLib {
diff --git a/MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiLib.h b/MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiLib.h
index dec2c93e1b34..93697da9cf86 100644
--- a/MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiLib.h
+++ b/MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiLib.h
@@ -11,8 +11,8 @@
#include <Library/GoogleTestLib.h>
#include <Library/FunctionMockLib.h>
extern "C" {
-#include <Uefi.h>
-#include <Library/UefiLib.h>
+ #include <Uefi.h>
+ #include <Library/UefiLib.h>
}
struct MockUefiLib {
diff --git a/MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiRuntimeServicesTableLib.h b/MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiRuntimeServicesTableLib.h
index afdfc6b85597..241abc55c079 100644
--- a/MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiRuntimeServicesTableLib.h
+++ b/MdePkg/Test/Mock/Include/GoogleTest/Library/MockUefiRuntimeServicesTableLib.h
@@ -11,8 +11,8 @@
#include <Library/GoogleTestLib.h>
#include <Library/FunctionMockLib.h>
extern "C" {
-#include <Uefi.h>
-#include <Library/UefiRuntimeServicesTableLib.h>
+ #include <Uefi.h>
+ #include <Library/UefiRuntimeServicesTableLib.h>
}
struct MockUefiRuntimeServicesTableLib {
diff --git a/MdePkg/Test/Mock/Library/GoogleTest/MockHobLib/MockHobLib.cpp b/MdePkg/Test/Mock/Library/GoogleTest/MockHobLib/MockHobLib.cpp
index 5a5a9159fcfe..51ee09065e92 100644
--- a/MdePkg/Test/Mock/Library/GoogleTest/MockHobLib/MockHobLib.cpp
+++ b/MdePkg/Test/Mock/Library/GoogleTest/MockHobLib/MockHobLib.cpp
@@ -7,24 +7,24 @@
#include <GoogleTest/Library/MockHobLib.h>
-MOCK_INTERFACE_DEFINITION(MockHobLib);
+MOCK_INTERFACE_DEFINITION (MockHobLib);
-MOCK_FUNCTION_DEFINITION(MockHobLib, GetHobList, 0, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, GetNextHob, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, GetFirstHob, 1, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, GetNextGuidHob, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, GetFirstGuidHob, 1, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, GetBootModeHob, 0, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildModuleHob, 4, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildResourceDescriptorWithOwnerHob, 5, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildResourceDescriptorHob, 4, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildGuidHob, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildGuidDataHob, 3, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildFvHob, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildFv2Hob, 4, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildFv3Hob, 6, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildCvHob, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildCpuHob, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildStackHob, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildBspStoreHob, 3, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockHobLib, BuildMemoryAllocationHob, 3, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, GetHobList, 0, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, GetNextHob, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, GetFirstHob, 1, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, GetNextGuidHob, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, GetFirstGuidHob, 1, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, GetBootModeHob, 0, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildModuleHob, 4, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildResourceDescriptorWithOwnerHob, 5, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildResourceDescriptorHob, 4, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildGuidHob, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildGuidDataHob, 3, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildFvHob, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildFv2Hob, 4, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildFv3Hob, 6, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildCvHob, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildCpuHob, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildStackHob, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildBspStoreHob, 3, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockHobLib, BuildMemoryAllocationHob, 3, EFIAPI);
diff --git a/MdePkg/Test/Mock/Library/GoogleTest/MockPeiServicesLib/MockPeiServicesLib.cpp b/MdePkg/Test/Mock/Library/GoogleTest/MockPeiServicesLib/MockPeiServicesLib.cpp
index 9a7ff4bd8ffb..c6035bd664cf 100644
--- a/MdePkg/Test/Mock/Library/GoogleTest/MockPeiServicesLib/MockPeiServicesLib.cpp
+++ b/MdePkg/Test/Mock/Library/GoogleTest/MockPeiServicesLib/MockPeiServicesLib.cpp
@@ -7,30 +7,30 @@
#include <GoogleTest/Library/MockPeiServicesLib.h>
-MOCK_INTERFACE_DEFINITION(MockPeiServicesLib);
+MOCK_INTERFACE_DEFINITION (MockPeiServicesLib);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesInstallPpi, 1, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesReInstallPpi, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesLocatePpi, 4, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesNotifyPpi, 1, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesGetBootMode, 1, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesSetBootMode, 1, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesGetHobList, 1, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesCreateHob, 3, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesFfsFindNextVolume, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesFfsFindNextFile, 3, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesFfsFindSectionData, 3, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesFfsFindSectionData3, 5, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesInstallPeiMemory, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesAllocatePages, 3, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesFreePages, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesAllocatePool, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesResetSystem, 0, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesFfsFindFileByName, 3, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesFfsGetFileInfo, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesFfsGetFileInfo2, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesFfsGetVolumeInfo, 2, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesRegisterForShadow, 1, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesInstallFvInfoPpi, 5, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesInstallFvInfo2Ppi, 6, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockPeiServicesLib, PeiServicesResetSystem2, 4, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesInstallPpi, 1, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesReInstallPpi, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesLocatePpi, 4, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesNotifyPpi, 1, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesGetBootMode, 1, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesSetBootMode, 1, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesGetHobList, 1, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesCreateHob, 3, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesFfsFindNextVolume, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesFfsFindNextFile, 3, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesFfsFindSectionData, 3, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesFfsFindSectionData3, 5, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesInstallPeiMemory, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesAllocatePages, 3, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesFreePages, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesAllocatePool, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesResetSystem, 0, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesFfsFindFileByName, 3, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesFfsGetFileInfo, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesFfsGetFileInfo2, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesFfsGetVolumeInfo, 2, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesRegisterForShadow, 1, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesInstallFvInfoPpi, 5, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesInstallFvInfo2Ppi, 6, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockPeiServicesLib, PeiServicesResetSystem2, 4, EFIAPI);
diff --git a/MdePkg/Test/Mock/Library/GoogleTest/MockUefiLib/MockUefiLib.cpp b/MdePkg/Test/Mock/Library/GoogleTest/MockUefiLib/MockUefiLib.cpp
index 5339d040c999..2a0c9613eaa2 100644
--- a/MdePkg/Test/Mock/Library/GoogleTest/MockUefiLib/MockUefiLib.cpp
+++ b/MdePkg/Test/Mock/Library/GoogleTest/MockUefiLib/MockUefiLib.cpp
@@ -6,7 +6,7 @@
**/
#include <GoogleTest/Library/MockUefiLib.h>
-MOCK_INTERFACE_DEFINITION(MockUefiLib);
+MOCK_INTERFACE_DEFINITION (MockUefiLib);
-MOCK_FUNCTION_DEFINITION(MockUefiLib, GetVariable2, 4, EFIAPI);
-MOCK_FUNCTION_DEFINITION(MockUefiLib, GetEfiGlobalVariable2, 3, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockUefiLib, GetVariable2, 4, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockUefiLib, GetEfiGlobalVariable2, 3, EFIAPI);
diff --git a/MdePkg/Test/Mock/Library/GoogleTest/MockUefiRuntimeServicesTableLib/MockUefiRuntimeServicesTableLib.cpp b/MdePkg/Test/Mock/Library/GoogleTest/MockUefiRuntimeServicesTableLib/MockUefiRuntimeServicesTableLib.cpp
index ecd1ba82366c..14296b0ccb88 100644
--- a/MdePkg/Test/Mock/Library/GoogleTest/MockUefiRuntimeServicesTableLib/MockUefiRuntimeServicesTableLib.cpp
+++ b/MdePkg/Test/Mock/Library/GoogleTest/MockUefiRuntimeServicesTableLib/MockUefiRuntimeServicesTableLib.cpp
@@ -6,13 +6,13 @@
**/
#include <GoogleTest/Library/MockUefiRuntimeServicesTableLib.h>
-MOCK_INTERFACE_DEFINITION(MockUefiRuntimeServicesTableLib);
+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_GetVariable, 5, EFIAPI);
+MOCK_FUNCTION_DEFINITION (MockUefiRuntimeServicesTableLib, gRT_SetVariable, 5, EFIAPI);
-static EFI_RUNTIME_SERVICES localRt = {
- {0}, // EFI_TABLE_HEADER
+static EFI_RUNTIME_SERVICES localRt = {
+ { 0 }, // EFI_TABLE_HEADER
NULL, // EFI_GET_TIME
NULL, // EFI_SET_TIME
@@ -36,5 +36,5 @@ static EFI_RUNTIME_SERVICES localRt = {
};
extern "C" {
- EFI_RUNTIME_SERVICES* gRT = &localRt;
+ EFI_RUNTIME_SERVICES *gRT = &localRt;
}
--
2.41.0.windows.3
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#107813): https://edk2.groups.io/g/devel/message/107813
Mute This Topic: https://groups.io/mt/100788669/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-
next prev parent reply other threads:[~2023-08-16 21:15 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-16 21:15 [edk2-devel] [PATCH v2 0/7] Uncrustify GoogleTest update VivianNK
2023-08-16 21:15 ` [edk2-devel] [PATCH v2 1/7] .pytool: Set uncrustify check to audit only (temporary) VivianNK
2023-08-16 22:09 ` Michael Kubacki
2023-08-16 21:15 ` [edk2-devel] [PATCH v2 2/7] .pytool: Add cpp support to uncrustify plugin VivianNK
2023-08-16 21:15 ` [edk2-devel] [PATCH v2 3/7] MdeModulePkg: Apply uncrustify formatting to relevant files VivianNK
2023-08-16 21:15 ` VivianNK [this message]
2023-08-16 21:15 ` [edk2-devel] [PATCH v2 5/7] SecurityPkg: " VivianNK
2023-08-17 2:41 ` Yao, Jiewen
2023-08-16 21:15 ` [edk2-devel] [PATCH v2 6/7] UnitTestFrameworkPkg: " VivianNK
2023-08-16 21:15 ` [edk2-devel] [PATCH v2 7/7] .pytool: Undo uncrustify check change VivianNK
2023-08-16 22:09 ` Michael Kubacki
2023-09-12 1:08 ` 回复: [edk2-devel] [PATCH v2 0/7] Uncrustify GoogleTest update gaoliming via groups.io
2023-09-12 14:42 ` Michael D Kinney
2023-09-27 19:43 ` VivianNK
2023-10-24 20:34 ` VivianNK
2023-10-25 17:11 ` Michael D Kinney
2023-10-25 18:08 ` Michael D Kinney
2023-10-26 21:08 ` VivianNK
2023-10-27 2:41 ` Michael D Kinney
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230816211523.12-5-vnowkakeane@linux.microsoft.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox