Merge "Add curly braces in oemcrypto_test.cpp"
This commit is contained in:
committed by
Android (Google) Code Review
commit
3b179876b8
@@ -466,7 +466,9 @@ TEST_F(OEMCryptoClientTest, CheckUsageTableSizeAPI16) {
|
|||||||
const size_t maximum = OEMCrypto_MaximumUsageTableHeaderSize();
|
const size_t maximum = OEMCrypto_MaximumUsageTableHeaderSize();
|
||||||
printf(" Max Usage Table Size: %zu.\n", maximum);
|
printf(" Max Usage Table Size: %zu.\n", maximum);
|
||||||
// A maximum of 0 means the table is constrained by dynamic memory allocation.
|
// A maximum of 0 means the table is constrained by dynamic memory allocation.
|
||||||
if (maximum > 0) ASSERT_GE(maximum, RequiredUsageSize());
|
if (maximum > 0) {
|
||||||
|
ASSERT_GE(maximum, RequiredUsageSize());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
@@ -5468,7 +5470,9 @@ TEST_F(OEMCryptoLoadsCertificateAlternates,
|
|||||||
OEMCryptoResult sts;
|
OEMCryptoResult sts;
|
||||||
LoadWithAllowedSchemes(kSign_PKCS1_Block1, false);
|
LoadWithAllowedSchemes(kSign_PKCS1_Block1, false);
|
||||||
// If the device is a cast receiver, then this scheme is required.
|
// If the device is a cast receiver, then this scheme is required.
|
||||||
if (global_features.cast_receiver) ASSERT_TRUE(key_loaded_);
|
if (global_features.cast_receiver) {
|
||||||
|
ASSERT_TRUE(key_loaded_);
|
||||||
|
}
|
||||||
if (key_loaded_) {
|
if (key_loaded_) {
|
||||||
Session s;
|
Session s;
|
||||||
ASSERT_NO_FATAL_FAILURE(s.open());
|
ASSERT_NO_FATAL_FAILURE(s.open());
|
||||||
@@ -5502,7 +5506,9 @@ TEST_F(OEMCryptoLoadsCertificateAlternates,
|
|||||||
OEMCryptoResult sts;
|
OEMCryptoResult sts;
|
||||||
LoadWithAllowedSchemes(kSign_PKCS1_Block1, false);
|
LoadWithAllowedSchemes(kSign_PKCS1_Block1, false);
|
||||||
// If the device is a cast receiver, then this scheme is required.
|
// If the device is a cast receiver, then this scheme is required.
|
||||||
if (global_features.cast_receiver) ASSERT_TRUE(key_loaded_);
|
if (global_features.cast_receiver) {
|
||||||
|
ASSERT_TRUE(key_loaded_);
|
||||||
|
}
|
||||||
if (key_loaded_) {
|
if (key_loaded_) {
|
||||||
Session s;
|
Session s;
|
||||||
ASSERT_NO_FATAL_FAILURE(s.open());
|
ASSERT_NO_FATAL_FAILURE(s.open());
|
||||||
@@ -5539,7 +5545,9 @@ TEST_F(OEMCryptoLoadsCertificateAlternates, TestSignaturePKCS1) {
|
|||||||
// scheme is used by cast receivers.
|
// scheme is used by cast receivers.
|
||||||
LoadWithAllowedSchemes(kSign_PKCS1_Block1, false);
|
LoadWithAllowedSchemes(kSign_PKCS1_Block1, false);
|
||||||
// If the device is a cast receiver, then this scheme is required.
|
// If the device is a cast receiver, then this scheme is required.
|
||||||
if (global_features.cast_receiver) ASSERT_TRUE(key_loaded_);
|
if (global_features.cast_receiver) {
|
||||||
|
ASSERT_TRUE(key_loaded_);
|
||||||
|
}
|
||||||
// If the key loaded with no error, then we will verify that it is not used
|
// If the key loaded with no error, then we will verify that it is not used
|
||||||
// for forbidden padding schemes.
|
// for forbidden padding schemes.
|
||||||
if (key_loaded_) {
|
if (key_loaded_) {
|
||||||
|
|||||||
Reference in New Issue
Block a user