Ticket #6200: test-login-url_r6917.diff

File test-login-url_r6917.diff, 1.1 KB (added by Jason Yan <tailofthesun@…>, 17 years ago)
  • tests/runtests.py

     
    9393    old_root_urlconf = settings.ROOT_URLCONF
    9494    old_template_dirs = settings.TEMPLATE_DIRS
    9595    old_use_i18n = settings.USE_I18N
     96    old_login_url = settings.LOGIN_URL
    9697    old_language_code = settings.LANGUAGE_CODE
    9798    old_middleware_classes = settings.MIDDLEWARE_CLASSES
    9899
     
    102103    settings.TEMPLATE_DIRS = (os.path.join(os.path.dirname(__file__), TEST_TEMPLATE_DIR),)
    103104    settings.USE_I18N = True
    104105    settings.LANGUAGE_CODE = 'en'
     106    settings.LOGIN_URL = '/accounts/login/'
    105107    settings.MIDDLEWARE_CLASSES = (
    106108        'django.contrib.sessions.middleware.SessionMiddleware',
    107109        'django.contrib.auth.middleware.AuthenticationMiddleware',
     
    153155    settings.TEMPLATE_DIRS = old_template_dirs
    154156    settings.USE_I18N = old_use_i18n
    155157    settings.LANGUAGE_CODE = old_language_code
     158    settings.LOGIN_URL = old_login_url
    156159    settings.MIDDLEWARE_CLASSES = old_middleware_classes
    157160
    158161if __name__ == "__main__":
Back to Top