All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.bouncycastle.PrintTestResult Maven / Gradle / Ivy

Go to download

The Bouncy Castle Crypto package is a Java implementation of cryptographic algorithms. This jar contains JCE provider and lightweight API for the Bouncy Castle Cryptography APIs for JDK 1.5 to JDK 1.8.

There is a newer version: 1.79
Show newest version
package org.bouncycastle;


import java.util.Enumeration;

import junit.framework.TestFailure;
import junit.framework.TestResult;

public class PrintTestResult
{
    public static void printResult(TestResult result)
    {
        Enumeration e = result.failures();
        if (e != null)
        {
            while (e.hasMoreElements())
            {
                System.out.println(e.nextElement());
            }
        }

        e = result.errors();
        if (e != null)
        {
            while (e.hasMoreElements())
            {
                System.out.println(e.nextElement());
            }
        }

        if (!result.wasSuccessful())
        {
            System.exit(1);
        }
    }
}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy