summaryrefslogtreecommitdiff
path: root/tests/vb2_common2_tests.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/vb2_common2_tests.c')
-rw-r--r--tests/vb2_common2_tests.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/vb2_common2_tests.c b/tests/vb2_common2_tests.c
index 6c3a3e48..2afa9f9e 100644
--- a/tests/vb2_common2_tests.c
+++ b/tests/vb2_common2_tests.c
@@ -36,6 +36,9 @@ static void test_unpack_key(const VbPublicKey *orig_key)
TEST_SUCC(vb2_unpack_key(&rsa, buf, size), "vb2_unpack_key() ok");
TEST_EQ(rsa.algorithm, key2->algorithm, "vb2_unpack_key() algorithm");
+ TEST_EQ(rsa.hash_alg, vb2_crypto_to_hash(key2->algorithm),
+ "vb2_unpack_key() hash_alg");
+
PublicKeyCopy(key, orig_key);
key2->algorithm = VB2_ALG_COUNT;