Kaydet (Commit) 9347f748 authored tarafından Adrian Holovaty's avatar Adrian Holovaty

Added an EmailField to the many_to_one API tests

git-svn-id: http://code.djangoproject.com/svn/django/trunk@1315 bcc190cf-cafb-0310-a4f2-bffc1f526a37
üst 928318fa
......@@ -9,6 +9,7 @@ from django.core import meta
class Reporter(meta.Model):
first_name = meta.CharField(maxlength=30)
last_name = meta.CharField(maxlength=30)
email = meta.EmailField()
def __repr__(self):
return "%s %s" % (self.first_name, self.last_name)
......@@ -23,7 +24,7 @@ class Article(meta.Model):
API_TESTS = """
# Create a Reporter.
>>> r = reporters.Reporter(first_name='John', last_name='Smith')
>>> r = reporters.Reporter(first_name='John', last_name='Smith', email='john@example.com')
>>> r.save()
# Create an Article.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment