Home | History | Annotate | Download | only in test
      1 """Whimpy test script for the al module
      2    Roger E. Masse
      3 """
      4 from test.test_support import verbose, import_module
      5 al = import_module('al', deprecated=True)
      6 
      7 alattrs = ['__doc__', '__name__', 'getdefault', 'getminmax', 'getname', 'getparams',
      8            'newconfig', 'openport', 'queryparams', 'setparams']
      9 
     10 # This is a very unobtrusive test for the existence of the al module and all its
     11 # attributes.  More comprehensive examples can be found in Demo/al
     12 
     13 def test_main():
     14     # touch all the attributes of al without doing anything
     15     if verbose:
     16         print 'Touching al module attributes...'
     17     for attr in alattrs:
     18         if verbose:
     19             print 'touching: ', attr
     20         getattr(al, attr)
     21 
     22 
     23 if __name__ == '__main__':
     24     test_main()
     25