1
0
mirror of https://github.com/django/django.git synced 2025-10-24 22:26:08 +00:00

gis: Merged revisions 6021-6393 via svnmerge from [repos:django/trunk trunk].

git-svn-id: http://code.djangoproject.com/svn/django/branches/gis@6394 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Justin Bronn
2007-09-20 13:02:11 +00:00
parent 69452d6237
commit 7376474260
305 changed files with 33482 additions and 16938 deletions

View File

@@ -0,0 +1,21 @@
from django.db import models
class BoundaryModel(models.Model):
positive_integer = models.PositiveIntegerField(null=True, blank=True)
__test__ = {'API_TESTS': """
>>> from django.newforms import form_for_model
# Boundary conditions on a PostitiveIntegerField #########################
>>> BoundaryForm = form_for_model(BoundaryModel)
>>> f = BoundaryForm({'positive_integer':100})
>>> f.is_valid()
True
>>> f = BoundaryForm({'positive_integer':0})
>>> f.is_valid()
True
>>> f = BoundaryForm({'positive_integer':-100})
>>> f.is_valid()
False
"""}