def test_bad_module_all():
 testsdir = os.path.dirname(__file__)
 sys.path.insert(0, testsdir)
 try:
  results = module_completion('from bad_all import ')
  nt.assert_in('puppies', results)
  for r in results:
   nt.assert_is_instance(r, str)
 finally:
  sys.path.remove(testsdir)

def test_bad_module_all ( ) : testsdir = os . path . dirname ( __file__ ) sys . path . insert ( 0 , testsdir ) try : results = module_completion ( 'from bad_all import ' ) nt . assert_in ( 'puppies' , results ) for r in results : nt . assert_is_instance ( r , str ) finally : sys . path . remove ( testsdir )
test module with invalid __all__ URL .