コード例 #1
0
    def setUp(self):
        LoadEnvironment("testing")
        from wsgi import application

        self.application = application

        self.application.bind(
            "router",
            RouteCapsule(
                Route.set_controller_module_location(
                    "tests.integrations.controllers").get(
                        "/", "WelcomeController@show"),
                Route.set_controller_module_location(
                    "tests.integrations.controllers").post(
                        "/", "WelcomeController@show"),
            ),
        )
        self.original_class_mocks = {}
        self._test_cookies = {}
        self._test_headers = {}
        if hasattr(self, "startTestRun"):
            self.startTestRun()
コード例 #2
0
 def setUp(self):
     Route.set_controller_module_location("tests.integrations.controllers")
     pass