code: def test_strings_dfa():
      strings = "able alfa alpha apple bar bear beat boom boot".split()
      dfa = fsa.strings_dfa(strings)
      output = list(dfa.generate_all())
      assert output == strings
  
      domain = "abcd"
      words = set()
      for i in xrange(1, len(domain) + 1):
          words.update("".join(p) for p in permutations(domain[:i]))
      words = sorted(words)
      dfa = fsa.strings_dfa(words)
      assert list(dfa.generate_all()) == words
  
imports: import gzip
  import os.path
  from bisect import bisect_left
  from whoosh.compat import permutations
  from whoosh.compat import xrange
  from whoosh.automata import fsa, glob, lev
  from whoosh.support.levenshtein import levenshtein
label_desc: Use image node_id 19 for calling a global function with example usage: test_strings_dfa() without return types