equal
deleted
inserted
replaced
87 |
87 |
88 Class attributes: |
88 Class attributes: |
89 * `anonymous_allowed`: flag telling if anonymous browsing should be allowed |
89 * `anonymous_allowed`: flag telling if anonymous browsing should be allowed |
90 """ |
90 """ |
91 configcls = CubicWebServerConfig |
91 configcls = CubicWebServerConfig |
92 # anonymous is logged by default in cubicweb test cases |
|
93 anonymous_allowed = True |
|
94 |
92 |
95 def start_server(self): |
93 def start_server(self): |
96 # use a semaphore to avoid starting test while the http server isn't |
94 # use a semaphore to avoid starting test while the http server isn't |
97 # fully initilialized |
95 # fully initilialized |
98 semaphore = threading.Semaphore(0) |
96 semaphore = threading.Semaphore(0) |
183 self.stop_server() |
181 self.stop_server() |
184 except error.ReactorNotRunning as err: |
182 except error.ReactorNotRunning as err: |
185 # Server could be launched manually |
183 # Server could be launched manually |
186 print err |
184 print err |
187 super(CubicWebServerTC, self).tearDown() |
185 super(CubicWebServerTC, self).tearDown() |
188 |
|
189 @classmethod |
|
190 def init_config(cls, config): |
|
191 config.set_anonymous_allowed(cls.anonymous_allowed) |
|
192 super(CubicWebServerTC, cls).init_config(config) |
|