[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL v2 05/13] crypto: skip testing of unsupported cipher
From: |
Daniel P. Berrange |
Subject: |
[Qemu-devel] [PULL v2 05/13] crypto: skip testing of unsupported cipher algorithms |
Date: |
Thu, 17 Mar 2016 14:43:48 +0000 |
We don't guarantee that all crypto backends will support
all cipher algorithms, so we should skip tests unless
the crypto backend indicates support.
Reviewed-by: Fam Zheng <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Signed-off-by: Daniel P. Berrange <address@hidden>
---
tests/test-crypto-cipher.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/tests/test-crypto-cipher.c b/tests/test-crypto-cipher.c
index 9f912ec..7a073e9 100644
--- a/tests/test-crypto-cipher.c
+++ b/tests/test-crypto-cipher.c
@@ -380,7 +380,9 @@ int main(int argc, char **argv)
g_assert(qcrypto_init(NULL) == 0);
for (i = 0; i < G_N_ELEMENTS(test_data); i++) {
- g_test_add_data_func(test_data[i].path, &test_data[i], test_cipher);
+ if (qcrypto_cipher_supports(test_data[i].alg)) {
+ g_test_add_data_func(test_data[i].path, &test_data[i],
test_cipher);
+ }
}
g_test_add_func("/crypto/cipher/null-iv",
--
2.5.0
- [Qemu-devel] [PULL v2 00/13] Merge crypto code for LUKS encryption, Daniel P. Berrange, 2016/03/17
- [Qemu-devel] [PULL v2 01/13] crypto: add cryptographic random byte source, Daniel P. Berrange, 2016/03/17
- [Qemu-devel] [PULL v2 02/13] crypto: add support for PBKDF2 algorithm, Daniel P. Berrange, 2016/03/17
- [Qemu-devel] [PULL v2 07/13] crypto: add support for the serpent cipher algorithm, Daniel P. Berrange, 2016/03/17
- [Qemu-devel] [PULL v2 04/13] crypto: add support for anti-forensic split algorithm, Daniel P. Berrange, 2016/03/17
- [Qemu-devel] [PULL v2 08/13] crypto: add support for the twofish cipher algorithm, Daniel P. Berrange, 2016/03/17
- [Qemu-devel] [PULL v2 03/13] crypto: add support for generating initialization vectors, Daniel P. Berrange, 2016/03/17
- [Qemu-devel] [PULL v2 11/13] crypto: wire up XTS mode for cipher APIs, Daniel P. Berrange, 2016/03/17
- [Qemu-devel] [PULL v2 05/13] crypto: skip testing of unsupported cipher algorithms,
Daniel P. Berrange <=
- [Qemu-devel] [PULL v2 06/13] crypto: add support for the cast5-128 cipher algorithm, Daniel P. Berrange, 2016/03/17
- [Qemu-devel] [PULL v2 10/13] crypto: refactor code for dealing with AES cipher, Daniel P. Berrange, 2016/03/17
- [Qemu-devel] [PULL v2 09/13] crypto: import an implementation of the XTS cipher mode, Daniel P. Berrange, 2016/03/17
- [Qemu-devel] [PULL v2 13/13] crypto: implement the LUKS block encryption format, Daniel P. Berrange, 2016/03/17
- [Qemu-devel] [PULL v2 12/13] crypto: add block encryption framework, Daniel P. Berrange, 2016/03/17
- Re: [Qemu-devel] [PULL v2 00/13] Merge crypto code for LUKS encryption, Peter Maydell, 2016/03/17