]> source.dussan.org Git - poi.git/commitdiff
Add more output for a failure that we saw once in CI
authorDominik Stadler <centic@apache.org>
Wed, 6 Dec 2023 19:49:56 +0000 (19:49 +0000)
committerDominik Stadler <centic@apache.org>
Wed, 6 Dec 2023 19:49:56 +0000 (19:49 +0000)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1914405 13f79535-47bb-0310-9956-ffa450edef68

poi-ooxml/src/test/java/org/apache/poi/poifs/crypt/dsig/TestSignatureInfo.java

index 932195193eaa5c874737402cec74ad2d6151dfbc..3a7e4eb5ed7ee7f33410b5ea92196b2c9b73b0cc 100644 (file)
@@ -252,7 +252,11 @@ class TestSignatureInfo {
             si.setOpcPackage(pkg);
             si.setSignatureConfig(sic);
             boolean isValid = si.verifySignature();
-            assertTrue(isValid);
+
+            assertTrue(isValid,
+                    // add some details to find out why "verifySignature()" returns false sometimes
+                    "Verifying signature failed, hasNext: " + si.getSignatureParts().iterator().hasNext() + ": " +
+                            (si.getSignatureParts().iterator().hasNext() ? si.getSignatureParts().iterator() : ""));
         }
     }