ps6.test
Class PublicTextUITest
java.lang.Object
ps6.test.PublicTextUITest
public class PublicTextUITest
- extends Object
Public (Specification) TextUI Test Suite
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
INPUT_PROMPTS
public static final String INPUT_PROMPTS
- See Also:
- Constant Field Values
END_PROMPT
public static final String END_PROMPT
- See Also:
- Constant Field Values
EOL
public static String EOL
PublicTextUITest
public PublicTextUITest(String description,
String[] mainParams,
Class<?> mainClass,
InputStream testInput,
String expected)
- When instantiated, serves as an immutable TextUI test case for
PS6. Runs the TextUI main method on a given input and compared
the actual output to the expected output
- Parameters:
mainClass
- class that defines a main() that reads from System.in and
writes to System.outtestInput
- test input for the filterexpected
- expected test output
TextUiTestCase
public void TextUiTestCase()
getTestParameters
public static List<Object[]> getTestParameters()
- Constructs a list of parameters for each instance of PublicTextUITest.
The test runner Parameterized will instantiate a PublicTextUITest for every Object[] in the
returned list. Since this call to the constructor is done through reflection, we can (and must)
pass around opaque arrays of objects here.
makeUiTest
public static Object[] makeUiTest(TestRecord record)