Set an application's test quarantine settings
import requests
url = "https://platform.ankra.app/api/v1/org/applications/{application_id}/pipeline-tests/quarantine/settings"
payload = {
"enabled": True,
"min_flaky_rate": 0,
"min_samples": 501,
"release_after_passes": 50
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({enabled: true, min_flaky_rate: 0, min_samples: 501, release_after_passes: 50})
};
fetch('https://platform.ankra.app/api/v1/org/applications/{application_id}/pipeline-tests/quarantine/settings', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request PUT \
--url https://platform.ankra.app/api/v1/org/applications/{application_id}/pipeline-tests/quarantine/settings \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"enabled": true,
"min_flaky_rate": 0,
"min_samples": 501,
"release_after_passes": 50
}
'{
"enabled": true,
"min_flaky_rate": 0,
"min_samples": 501,
"release_after_passes": 50
}Pipelines
Set an application's test quarantine settings
Turns the repository’s flaky test quarantine on or off and sets its thresholds. Every field is optional and an omitted one keeps its stored value. The change is audited with the values before and after. Requires pipelines.manage.
PUT
/
api
/
v1
/
org
/
applications
/
{application_id}
/
pipeline-tests
/
quarantine
/
settings
Set an application's test quarantine settings
import requests
url = "https://platform.ankra.app/api/v1/org/applications/{application_id}/pipeline-tests/quarantine/settings"
payload = {
"enabled": True,
"min_flaky_rate": 0,
"min_samples": 501,
"release_after_passes": 50
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({enabled: true, min_flaky_rate: 0, min_samples: 501, release_after_passes: 50})
};
fetch('https://platform.ankra.app/api/v1/org/applications/{application_id}/pipeline-tests/quarantine/settings', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request PUT \
--url https://platform.ankra.app/api/v1/org/applications/{application_id}/pipeline-tests/quarantine/settings \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"enabled": true,
"min_flaky_rate": 0,
"min_samples": 501,
"release_after_passes": 50
}
'{
"enabled": true,
"min_flaky_rate": 0,
"min_samples": 501,
"release_after_passes": 50
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Body
application/json
Response
The stored settings.
Whether a failing run step whose only failed tests are quarantined settles as a success. Off by default.
The share of observed default-branch runs a test must have been flaky in to be quarantined.
Required range:
x <= 1How many observed default-branch runs that rate must rest on.
Required range:
3 <= x <= 1000How many consecutive default-branch passes release a quarantine on their own.
Required range:
1 <= x <= 100