Ejemplo n.º 1
0
 def __init__(self, *args, **kargs):
     TestWSGIController.__init__(self, *args, **kargs)
     self.baseenviron = {}
     app = ControllerWrap(FilteredWSGIController)
     app = self.sap = SetupCacheGlobal(app, self.baseenviron)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 2
0
 def __init__(self, *args, **kargs):
     TestWSGIController.__init__(self, *args, **kargs)
     self.baseenviron = {}
     app = ControllerWrap(BasicWSGIController)
     app = self.sap = SetupCacheGlobal(app, self.baseenviron)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 3
0
 def setUp(self):
     TestWSGIController.setUp(self)
     app = ControllerWrap(ProtectedController)
     app = SetupCacheGlobal(app, self.environ, setup_session=True)
     app = SessionMiddleware(app, {}, data_dir=session_dir)
     app = RegistryManager(app)
     self.app = TestApp(app)
 def setUp(self):
     TestWSGIController.setUp(self)
     app = ControllerWrap(ProtectedController)
     app = SetupCacheGlobal(app, self.environ, setup_session=True)
     app = SessionMiddleware(app, {}, data_dir=session_dir)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 5
0
 def __init__(self, *args, **kargs):
     TestWSGIController.__init__(self, *args, **kargs)
     self.baseenviron = {}
     self.baseenviron['pylons.routes_dict'] = {}
     app = ControllerWrap(BaseXMLRPCController)
     app = self.sap = SetupCacheGlobal(app, self.baseenviron)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 6
0
 def __init__(self, *args, **kargs):
     TestWSGIController.__init__(self, *args, **kargs)
     self.baseenviron = {}
     self.baseenviron['pylons.routes_dict'] = {}
     app = ControllerWrap(BaseXMLRPCController)
     app = self.sap = SetupCacheGlobal(app, self.baseenviron)
     app = RegistryManager(app)
     self.app = TestApp(app)
 def setUp(self):
     from pylons.testutil import ControllerWrap, SetupCacheGlobal
     ProtectedController = make_protected()
     TestWSGIController.setUp(self)
     app = ControllerWrap(ProtectedController)
     app = SetupCacheGlobal(app, self.environ, setup_session=True)
     app = SessionMiddleware(app, {}, data_dir=session_dir)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 8
0
 def setUp(self):
     from pylons.testutil import ControllerWrap, SetupCacheGlobal
     ValidatingController = make_validating_controller()
     
     TestWSGIController.setUp(self)
     app = SetupCacheGlobal(ControllerWrap(ValidatingController),
                            self.environ)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 9
0
 def __init__(self, *args, **kargs):
     from pylons.testutil import ControllerWrap, SetupCacheGlobal
     BasicWSGIController, FilteredWSGIController = make_controllers()
     TestWSGIController.__init__(self, *args, **kargs)
     self.baseenviron = {}
     app = ControllerWrap(FilteredWSGIController)
     app = self.sap = SetupCacheGlobal(app, self.baseenviron)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 10
0
 def __init__(self, *args, **kargs):
     from pylons.testutil import ControllerWrap, SetupCacheGlobal
     HelpersController = make_helperscontroller()
     TestWSGIController.__init__(self, *args, **kargs)
     self.baseenviron = {}
     app = ControllerWrap(HelpersController)
     app = self.sap = SetupCacheGlobal(app, self.baseenviron)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 11
0
    def setUp(self):
        from pylons.testutil import ControllerWrap, SetupCacheGlobal
        ValidatingController = make_validating_controller()

        TestWSGIController.setUp(self)
        app = SetupCacheGlobal(ControllerWrap(ValidatingController),
                               self.environ)
        app = RegistryManager(app)
        self.app = TestApp(app)
 def setUp(self):
     from pylons.testutil import ControllerWrap, SetupCacheGlobal
     ProtectedController = make_protected()
     TestWSGIController.setUp(self)
     app = ControllerWrap(ProtectedController)
     app = SetupCacheGlobal(app, self.environ, setup_session=True)
     app = SessionMiddleware(app, {}, data_dir=session_dir)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 13
0
 def __init__(self, *args, **kargs):
     from pylons.testutil import ControllerWrap, SetupCacheGlobal
     BasicWSGIController, FilteredWSGIController = make_controllers()
     TestWSGIController.__init__(self, *args, **kargs)
     self.baseenviron = {}
     app = ControllerWrap(BasicWSGIController)
     app = self.sap = SetupCacheGlobal(app, self.baseenviron)
     app = TestMiddleware(app)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 14
0
 def setUp(self):
     TestWSGIController.setUp(self)
     from routes import Mapper
     map = Mapper()
     map.connect('/:action/:id')
     map.connect('/:controller/:action/:id')
     app = ControllerWrap(HttpsController)
     app = SetupCacheGlobal(app, self.environ, setup_cache=False)
     app = RoutesMiddleware(app, map)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 15
0
    def __init__(self, *args, **kwargs):
        from pylons.testutil import ControllerWrap, SetupCacheGlobal

        BaseJSONRPCController = make_basejsonrpc()
        TestWSGIController.__init__(self, *args, **kwargs)
        self.baseenviron = {}
        self.baseenviron['pylons.routes_dict'] = {}
        app = ControllerWrap(BaseJSONRPCController)
        app = self.sap = SetupCacheGlobal(app, self.baseenviron)
        app = RegistryManager(app)
        self.app = TestApp(app)
Ejemplo n.º 16
0
    def setUp(self):
        TestWSGIController.setUp(self)
        from routes import Mapper

        map = Mapper()
        map.connect("/:action/:id")
        map.connect("/:controller/:action/:id")
        app = ControllerWrap(HttpsController)
        app = SetupCacheGlobal(app, self.environ, setup_cache=False)
        app = RoutesMiddleware(app, map)
        app = RegistryManager(app)
        self.app = TestApp(app)
Ejemplo n.º 17
0
 def setUp(self):
     from pylons.testutil import ControllerWrap, SetupCacheGlobal
     HttpsController = make_httpscontroller()
     TestWSGIController.setUp(self)
     from routes import Mapper
     map = Mapper()
     map.connect('/:action')
     map.connect('/:action/:id')
     map.connect('/:controller/:action/:id')
     map.connect('/:controller/:action')
     app = ControllerWrap(HttpsController)
     app = SetupCacheGlobal(app, self.environ, setup_cache=False)
     app = RoutesMiddleware(app, map)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 18
0
    def __init__(self, *args, **kargs):
        TestWSGIController.__init__(self, *args, **kargs)

        class Callable(object):
            def __init__(self): self.called = False
            def __call__(self, *args, **kargs): self.called = True

        self.before_callable = Callable()
        self.after_callable = Callable()

        from pylons.controllers import WSGIController
        class Controller(WSGIController):
            def index(self): return 'index'
            __before__ = self.before_callable
            __after__ = self.after_callable

        from pylons.testutil import ControllerWrap, SetupCacheGlobal
        self.baseenviron = {}
        app = ControllerWrap(Controller)
        app = self.sap = SetupCacheGlobal(app, self.baseenviron)
        app = RegistryManager(app)
        self.app = TestApp(app)
Ejemplo n.º 19
0
 def setUp(self):
     TestWSGIController.setUp(self)
     self.baseenviron.update(self.environ)
Ejemplo n.º 20
0
 def setUp(self):
     self.app = app
     TestWSGIController.setUp(self)
     environ.update(self.environ)
Ejemplo n.º 21
0
 def setUp(self):
     TestWSGIController.setUp(self)
     self.baseenviron.update(self.environ)
     warnings.simplefilter('error', DeprecationWarning)
Ejemplo n.º 22
0
 def setUp(self):
     self.app, environ = make_cache_controller_app()
     TestWSGIController.setUp(self)
     environ.update(self.environ)
     warnings.simplefilter('error', Warning)
Ejemplo n.º 23
0
 def setUp(self):
     app, bad_app = make_cache_controller()
     self.app = app
     TestWSGIController.setUp(self)
     environ.update(self.environ)
Ejemplo n.º 24
0
 def setUp(self):
     TestWSGIController.setUp(self)
     self.baseenviron.update(self.environ)
Ejemplo n.º 25
0
 def setUp(self):
     TestWSGIController.setUp(self)
     app = SetupCacheGlobal(ControllerWrap(ValidatingController),
                            self.environ)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 26
0
 def setUp(self):
     self.app, environ = make_cache_controller_app()
     TestWSGIController.setUp(self)
     environ.update(self.environ)
     warnings.simplefilter('error', Warning)
Ejemplo n.º 27
0
 def setUp(self):
     self.app = app
     TestWSGIController.setUp(self)
     environ.update(self.environ)
Ejemplo n.º 28
0
 def setUp(self):
     app, bad_app = make_cache_controller()
     self.app = app
     TestWSGIController.setUp(self)
     environ.update(self.environ)
Ejemplo n.º 29
0
 def setUp(self):
     TestWSGIController.setUp(self)
     app = SetupCacheGlobal(ControllerWrap(ValidatingController),
                            self.environ)
     app = RegistryManager(app)
     self.app = TestApp(app)
Ejemplo n.º 30
0
 def setUp(self):
     self.app = app
     TestWSGIController.setUp(self)
     environ.update(self.environ)
     warnings.simplefilter('error', Warning)
Ejemplo n.º 31
0
 def setUp(self):
     self.app = app
     TestWSGIController.setUp(self)
     environ.update(self.environ)
     warnings.simplefilter('error', Warning)
Ejemplo n.º 32
0
 def setUp(self):
     TestWSGIController.setUp(self)
     self.baseenviron.update(self.environ)
     warnings.simplefilter('error', DeprecationWarning)