class documentation

class CoreTests(TestCase): (source)

View In Hierarchy

Tests for Automat's (currently private, implementation detail) core.

Method test_initialState Automaton.initialState is a descriptor that sets the initial state if it's not yet set, and raises ValueError if it is.
Method test_noOutputForInput Automaton.outputForInput raises NoTransition if no transition for that input is defined.
Method test_NoTransition A NoTransition exception describes the state and input symbol that caused it.
Method test_oneTransition Automaton.addTransition adds its input symbol to Automaton.inputAlphabet, all its outputs to Automaton.outputAlphabet, and causes Automaton.outputForInput to start returning the new state and output symbols.
Method test_oneTransition_nonIterableOutputs Automaton.addTransition raises a TypeError when given outputs that aren't iterable and doesn't add any transitions.
Method test_unhandledTransition Automaton.unhandledTransition sets the outputs and end-state to be used for all unhandled transitions.
def test_initialState(self): (source)

Automaton.initialState is a descriptor that sets the initial state if it's not yet set, and raises ValueError if it is.

def test_noOutputForInput(self): (source)

Automaton.outputForInput raises NoTransition if no transition for that input is defined.

def test_NoTransition(self): (source)

A NoTransition exception describes the state and input symbol that caused it.

def test_oneTransition(self): (source)

Automaton.addTransition adds its input symbol to Automaton.inputAlphabet, all its outputs to Automaton.outputAlphabet, and causes Automaton.outputForInput to start returning the new state and output symbols.

def test_oneTransition_nonIterableOutputs(self): (source)

Automaton.addTransition raises a TypeError when given outputs that aren't iterable and doesn't add any transitions.

def test_unhandledTransition(self): (source)

Automaton.unhandledTransition sets the outputs and end-state to be used for all unhandled transitions.