Part of lp.services.salesforce.tests.proxy View In Hierarchy
This transport contains a small amount of sample data and intercepts requests that would normally be sent via XML-RPC but instead directly provides responses based on the sample data. This transport does not simulate network errors or timeouts.
| Method | __init__ | Undocumented |
| Method | getServerStatus | Get the server status. If it responds it is healthy. |
| Method | getUnredeemedVouchers | Return the list of unredeemed vouchers for a given id. |
| Method | getAllVouchers | Return the complete list of vouchers for a given id. |
| Method | getVoucher | Return the voucher. |
| Method | redeemVoucher | Redeem the voucher. |
| Method | updateProjectName | Set the project name for the given project id. |
| Method | grantVoucher | Grant a new voucher to the user. |
| Method | request | Call the corresponding XML-RPC method. |
| Method | _createVoucher | Create a new voucher with the given term and owner. |
| Method | _findVoucher | Find a voucher by id. |
Included here for completeness though it is never called by Launchpad.
The returned value is a list of dictionaries, each having a 'voucher' and 'status' keys.
The returned value is a list of dictionaries, each having a 'voucher', 'status', and 'project_id' keys.
| Parameters | voucher_id | string representing the unique voucher id. |
| lp_openid | string representing the Launchpad user's OpenID. | |
| lp_project_id | Launchpad project id | |
| lp_project_name | Launchpad project name | |
| Returns | Boolean representing the success or failure of the operation. | |
Returns the number of vouchers that were updated.
The method name and arguments are extracted from request. The
method on this class with the same name as the XML-RPC method is
called, with the extracted arguments passed on to it.