'Loads the Django application\'s settings. You can
override this method to provide your own loading
mechanism. Simply return an instance of your settings module.'

def load_settings(self):

    name = os.environ['DJANGO_SETTINGS_MODULE']
    (package, mod) = name.rsplit('.', 1)
    (fd, path, description) = imp.find_module(mod, [package.replace('.', '/')])
    try:
        return imp.load_module(mod, fd, path, description)
    finally:
        if fd:
            fd.close()
