This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from django.contrib.sites.models import Site | |
from django.core.urlresolvers import set_script_prefix | |
class ScriptPrefixMiddleware(object): | |
""" Sets up url resolvers to return absolute urls | |
""" | |
def process_request(self, request): | |
set_script_prefix("http://%s" % Site.objects.get_current().domain) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Unit testing for AppEngine | |
import os | |
import sys | |
import unittest | |
# Path to AppEngine library (platform specific) | |
SDK_PATH = os.path.realpath('/usr/local/google_appengine/') | |
EXTRA_PATHS = [ | |
SDK_PATH, |
NewerOlder