Class DFANonJUnitTest

java.lang.Object
  extended by DFANonJUnitTest

public final class DFANonJUnitTest
  extends Object

Standalone unit tests for the DFA class. Uses Java's assert statement.

Version:
CSTheory (5)
Author:
Dr. Jody Paul
See Also:
Programming With Assertions


Method Summary
static void assignmentStatementDFATest()
          Construct and test a simple assignment statement checker.
static void astar_bDFATest()
          Construct and test a string validator for regular expression a*b.
static void astar_c_abstar_c_cstarDFATest()
          Construct and test a string validator for regular expression a*c(ab)*cc*.
static void main(String[] args)
          Driver for unit tests of DFA.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

assignmentStatementDFATest

public static void assignmentStatementDFATest()
Construct and test a simple assignment statement checker. All variables are a single lower-case letter. Expression operators are +, -, *, and /. Assignment operator is =. Blanks are not in the alphabet. The assignment statement must end with ; (a semicolon).


astar_bDFATest

public static void astar_bDFATest()
Construct and test a string validator for regular expression a*b. Includes tests of state activity counter.


astar_c_abstar_c_cstarDFATest

public static void astar_c_abstar_c_cstarDFATest()
Construct and test a string validator for regular expression a*c(ab)*cc*.


main

public static void main(String[] args)
Driver for unit tests of DFA.

Parameters:
args - ignored