Commit 6c2a78b2 authored by Adrian Holovaty's avatar Adrian Holovaty
Browse files

Changed pagination tests to suppress the DeprecationWarning

git-svn-id: http://code.djangoproject.com/svn/django/trunk@7308 bcc190cf-cafb-0310-a4f2-bffc1f526a37
parent 08d4910d
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -144,6 +144,10 @@ True
# Legacy API (ObjectPaginator) #
################################

# Don't print out the deprecation warnings during testing.
>>> from warnings import filterwarnings
>>> filterwarnings("ignore")

>>> from django.core.paginator import ObjectPaginator, InvalidPage
>>> paginator = ObjectPaginator(Article.objects.all(), 5)
>>> paginator.hits