blob: 1c1f87a7263c231246da4878b3292ddb8d1245ad (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
|
# `read last completed` - [Tests API](../README.md#tests-api)
The `read last completed` method of the tests API returns a list of test files, which most recently finished and have a result. The files are grouped by the status their respective result had.
## HTTP Request
`GET /api/tests/<session_token>/last_completed`
## Query Parameters
| Parameter | Desciption | Default | Example |
| --------- | ------------------------------------------------------------------------------------------------------------------------- | ------- | --------------------- |
| `count` | Number of files per status to return | 5 | `count=5` |
| `status` | The status the files results must have. Comma separated list. Possible values: `all`, `pass`, `fail` and `timeout` | `all` | `status=timeout,pass` |
## Response Payload
```json
{
"pass": "Array<String>",
"fail": "Array<String>",
"timeout": "Array<String>"
}
```
## Example
**Request:**
`GET /api/tests/7dafeec0-c351-11e9-84c5-3d1ede2e7d2e/last_completed?count=3&status=fail,timeout`
**Response:**
```json
{
"fail": [
"/apiTwo/test/four.html",
"/apiOne/test/twentyfour.html",
"/apiOne/test/nineteen.html"
],
"timeout": [
"/apiFive/test/eight.html",
"/apiThree/test/five.html",
"/apiThree/test/two.html"
]
}
```
|