Fix test_x509_store
authorRichard Levitte <levitte@openssl.org>
Fri, 17 Feb 2017 13:59:44 +0000 (14:59 +0100)
committerRichard Levitte <levitte@openssl.org>
Fri, 17 Feb 2017 13:59:44 +0000 (14:59 +0100)
Don't run this test unless 'openssl rehash' works properly.

Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/2664)

test/recipes/60-test_x509_store.t

index b084ed956fca82a273f240b8672ea8f0fb7dd0f0..041aa097dfbd7a086c557860244cb426c9ae36f0 100644 (file)
@@ -16,6 +16,11 @@ use OpenSSL::Test qw/:DEFAULT srctop_file/;
 
 setup("test_x509_store");
 
+#If "openssl rehash -help" fails it's most likely because we're on a platform
+#that doesn't support the rehash command (e.g. Windows)
+plan skip_all => "test_rehash is not available on this platform"
+    unless run(app(["openssl", "rehash", "-help"]));
+
 # We use 'openssl verify' for these tests, as it contains everything
 # we need to conduct these tests.  The tests here are a subset of the
 # ones found in 25-test_verify.t