Django

Code

Changeset 8160

Show
Ignore:
Timestamp:
07/31/08 04:24:16 (4 months ago)
Author:
russellm
Message:

Fixed #7978 -- Modified the contrib.sites tests to guarantee the initial conditions of the test match meet the requirements of the test. Thanks to Evan Schulz for the report and fix.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/trunk/django/contrib/sites/tests.py

    r7738 r8160  
    11""" 
     2>>> from django.contrib.sites.models import Site 
     3>>> from django.conf import settings 
     4>>> Site(id=settings.SITE_ID, domain="example.com", name="example.com").save() 
     5         
    26>>> # Make sure that get_current() does not return a deleted Site object. 
    3 >>> from django.contrib.sites.models import Site 
    47>>> s = Site.objects.get_current() 
    58>>> isinstance(s, Site)