Add unit tests for LevenshteinAutomaton.

The unit tests rely on QuickCheck-like randomization to generate
test instances.