added test unit to test_automata.rb