mirror of
https://github.com/ethauvin/JSON-java.git
synced 2025-06-17 07:50:52 -07:00
19 lines
No EOL
584 B
Java
19 lines
No EOL
584 B
Java
package org.json.junit;
|
|
|
|
import org.junit.runner.JUnitCore;
|
|
import org.junit.runner.Result;
|
|
import org.junit.runner.notification.Failure;
|
|
|
|
/**
|
|
* Invoke this class main method if you want to run unit tests from the
|
|
* command line. If successful, will print "true" to stdout.
|
|
*/
|
|
public class TestRunner {
|
|
public static void main(String[] args) {
|
|
Result result = JUnitCore.runClasses(JunitTestSuite.class);
|
|
for (Failure failure : result.getFailures()) {
|
|
System.out.println(failure.toString());
|
|
}
|
|
System.out.println(result.wasSuccessful());
|
|
}
|
|
} |