Contents:
This API call is used internally for testing the system.
It creates a list of the loaded tests.
Each can be tested using apitesting.runtests or apitesting.runtest.
This example retrieves the list of tests:
https://api.cyclestreets.net/v2/apitesting.list
Result:
{ "Status v2": { "name": "Status v2", "call": "status", "note": false, "ordering": 10 }, "Cambridge really short journey": { "name": "Cambridge really short journey", "call": "journey.plan", "note": false, "ordering": 40 }, "Retrieve Cambridge really short journey": { "name": "Retrieve Cambridge really short journey", "call": "journey.retrieve", "note": false, "ordering": 50 }, "Photo location": { "name": "Photo location", "call": "photomap.location", "note": false, "ordering": 80 }, "Photomap categories": { "name": "Photomap categories", "call": "photomap.categories", "note": false, "ordering": 90 }, … }
None.
name=categories
would match the tests "Photomap categories" and "PhotomapCategories v1".call=journey
would match journey.plan, journey.retrieve, and others containing journey.Controls what information is returned for each test.
Available fields are:
If fields is not supplied, the default is used, which represents a sensible and useful set of fields.
The field name is always returned.
Fields are returned in the ordering specified by the caller.
Unrecognised fieldnames are simply ignored rather than an error being thrown.
JSON object as above, listing the test names.
JSON object containing an error key and a text string.
Example error (text string will vary):
{ "error": "An internal error occurred while obtaining the list of tests." }