Test Steps
This chapter focuses on services for the test steps.
Get a test step
A GET to /test-steps/{id} returns the test step with the given id.
Path parameters
| Parameter | Description |
|---|---|
|
the id of the step (optional) |
HTTP request
GET /api/rest/latest/test-steps/235 HTTP/1.1
Accept: application/json
Host: localhost:8080
Request parameters
| Parameter | Description |
|---|---|
|
which fields of the elements should be returned (optional) |
HTTP response
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 727
{
"_type" : "action-step",
"id" : 235,
"test_case" : {
"_type" : "test-case",
"id" : 120,
"name" : "Door opening system",
"_links" : {
"self" : {
"href" : "http://localhost:8080/api/rest/latest/test-cases/120"
}
}
},
"action" : "<p>Wave your hand</p>",
"expected_result" : "<p>The door opens</p>",
"custom_fields" : [ {
"code" : "cuf_txt_note",
"label" : "note",
"value" : "Star Trek style welcomed but not mandatory"
}, {
"code" : "cuf_tags_see_also",
"label" : "see also",
"value" : [ "smart home", "sensors", "hand gesture" ]
} ],
"_links" : {
"self" : {
"href" : "http://localhost:8080/api/rest/latest/test-steps/235"
}
}
}
Response fields
| Path | Type | Description |
|---|---|---|
|
|
the id of the step |
|
|
the type of step |
|
|
the action to be accomplished, format is html |
|
|
the state or behavior that should be observable when the action has been performed, format is html) |
|
|
the test case this step is part of |
|
|
the custom fields of that test step |
|
|
the label of the custom field |
|
|
the code of the custom field |
|
|
the value of the custom field. The value is either a string (for most custom fields), or an array of strings (for multivalued custom fields eg a tag list) |
|
|
related links |
Links
| Relation | Description |
|---|---|
|
link to this step |