Revision 27a8a190 lib/rapi/testutils.py
b/lib/rapi/testutils.py | ||
---|---|---|
210 | 210 |
"""Mocking out the RAPI server parts. |
211 | 211 |
|
212 | 212 |
""" |
213 |
def __init__(self, user_fn, luxi_client): |
|
213 |
def __init__(self, user_fn, luxi_client, reqauth=False):
|
|
214 | 214 |
"""Initialize this class. |
215 | 215 |
|
216 | 216 |
@type user_fn: callable |
... | ... | |
219 | 219 |
|
220 | 220 |
""" |
221 | 221 |
self.handler = \ |
222 |
server.rapi.RemoteApiHandler(user_fn, _client_cls=luxi_client) |
|
222 |
server.rapi.RemoteApiHandler(user_fn, reqauth, _client_cls=luxi_client)
|
|
223 | 223 |
|
224 | 224 |
def FetchResponse(self, path, method, headers, request_body): |
225 | 225 |
"""This is a callback method used to fetch a response. |
Also available in: Unified diff