Package org.djutils.exceptions
Class TryTest
- java.lang.Object
-
- org.djutils.exceptions.TryTest
-
public class TryTest extends Object
Test the methods in the Try class.- Author:
- Peter Knoppers
-
-
Constructor Summary
Constructors Constructor Description TryTest()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static void
main(String[] args)
Can we get our intermittent test result to show up without the JUnit test harness?protected void
setResult(String newResult)
setter for the value to be called from execute() method.void
tryAssignTest()
Test the assign methods in the Try class.void
tryExecuteTest()
Test the execute methods in the Try class.void
trySucceedFailTestAssign()
Test the fail / succeed methods in the Try class using assignments.void
trySucceedFailTestExecute()
Test the fail / succeed methods in the Try class using executions.
-
-
-
Field Detail
-
value
protected String value
value to test for change by execute() method.
-
-
Method Detail
-
tryAssignTest
public void tryAssignTest() throws RuntimeException
Test the assign methods in the Try class.- Throws:
RuntimeException
- if that happens (uncaught); this test has failed.
-
setResult
protected void setResult(String newResult)
setter for the value to be called from execute() method.- Parameters:
newResult
- String; the value to set
-
tryExecuteTest
public void tryExecuteTest() throws RuntimeException
Test the execute methods in the Try class.- Throws:
RuntimeException
- if that happens (uncaught); this test has failed.
-
trySucceedFailTestAssign
public void trySucceedFailTestAssign() throws RuntimeException
Test the fail / succeed methods in the Try class using assignments.- Throws:
RuntimeException
- if that happens (uncaught); this test has failed.
-
trySucceedFailTestExecute
public void trySucceedFailTestExecute() throws RuntimeException
Test the fail / succeed methods in the Try class using executions.- Throws:
RuntimeException
- if that happens (uncaught); this test has failed.
-
main
public static void main(String[] args)
Can we get our intermittent test result to show up without the JUnit test harness?- Parameters:
args
- String[]; the command line arguments
-
-