1
0
mirror of https://github.com/django/django.git synced 2025-10-31 09:41:08 +00:00

[1.9.x] Fixed #25745 -- Promoted RuntimeWarnings to errors in the test suite.

Backport of 1c5f4e86bc from master
This commit is contained in:
Simon Charette
2015-11-13 15:54:05 -05:00
parent cfa3d4a256
commit ef78aec222
6 changed files with 19 additions and 34 deletions

View File

@@ -197,6 +197,7 @@ class GraphTests(SimpleTestCase):
leaf = expected[-1]
with warnings.catch_warnings(record=True) as w:
warnings.simplefilter('always', RuntimeWarning)
forwards_plan = graph.forwards_plan(leaf)
self.assertEqual(len(w), 1)
@@ -205,6 +206,7 @@ class GraphTests(SimpleTestCase):
self.assertEqual(expected, forwards_plan)
with warnings.catch_warnings(record=True) as w:
warnings.simplefilter('always', RuntimeWarning)
backwards_plan = graph.backwards_plan(root)
self.assertEqual(len(w), 1)