• Raymond Hettinger's avatar
    Reworked test_warnings.py: · d6f6e50c
    Raymond Hettinger yazdı
    * It ran fine under "python regrtest.py test_warnings" but failed under
      "python regrtest.py" presumably because other tests would add to
      filtered warnings and not reset them at the end of the test.
    
    * Converted to a unittest format for better control.  Renamed
      monkey() and unmonkey() to setUp() and tearDown().
    
    * Increased coverage by testing all warnings in __builtin__.
    
    * Increased coverage by testing regex matching of specific messages.
    d6f6e50c
test_warnings.py 3.09 KB