From 122ea851de77f761d7bc0ec5f3a7fc23e3a5d8be Mon Sep 17 00:00:00 2001 From: Richard Levitte Date: Tue, 22 Nov 2022 15:05:45 +0100 Subject: [PATCH] test/recipes/80-test_cms.t: Fix the "CAdES ko" test This test had commands that assumes that runner_loop() is used to perform the tests. These tests still run fine because Unix accepts braces in file names, but other operating systems might not. Reviewed-by: Dmitry Belyavskiy Reviewed-by: Tomas Mraz (Merged from https://github.com/openssl/openssl/pull/19731) (cherry picked from commit 20d3731006c9d29cbe17c2aedeba5e2abccfcd57) --- test/recipes/80-test_cms.t | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/test/recipes/80-test_cms.t b/test/recipes/80-test_cms.t index e10e086005..f9d19df6b9 100644 --- a/test/recipes/80-test_cms.t +++ b/test/recipes/80-test_cms.t @@ -451,10 +451,10 @@ my @smime_cms_cades_tests = ( my @smime_cms_cades_ko_tests = ( [ "sign content DER format, RSA key, not CAdES-BES compatible", [ @prov, "-sign", "-in", $smcont, "-outform", "DER", "-nodetach", - "-certfile", $smroot, "-signer", $smrsa1, "-out", "{output}.cms" ], + "-certfile", $smroot, "-signer", $smrsa1, "-out", "cades-ko.cms" ], "fail to verify token since requiring CAdES-BES compatibility", - [ @prov, "-verify", "-cades", "-in", "{output}.cms", "-inform", "DER", - "-CAfile", $smroot, "-out", "{output}.txt" ], + [ @prov, "-verify", "-cades", "-in", "cades-ko.cms", "-inform", "DER", + "-CAfile", $smroot, "-out", "cades-ko.txt" ], \&final_compare ] ); @@ -800,6 +800,7 @@ subtest "CAdES ko tests\n" => sub { SKIP: { my $skip_reason = check_availability($$_[0]); skip $skip_reason, 1 if $skip_reason; + 1 while unlink "cades-ko.txt"; ok(run(app(["openssl", "cms", @{$$_[1]}])), $$_[0]); ok(!run(app(["openssl", "cms", @{$$_[3]}])), $$_[2]); -- 2.34.1