I use ajax jquery call to fetch data about tests from Jenkins test report's REST API. However, I want only those tests for which 'status' is not PASSED and FIXED. Now, can I configure my Ajax call such that this filtering is already done on the server side, so that passed tests are not returned as a part of the response ? My Ajax call so far :
function getTestResultsForJob(jobTestResultsUrl){
var listOfFailures = {};
$.ajax({
type: 'GET',
dataType: 'json',
url: jobTestResultsUrl,
async: false,
error: function() {
alert("Request has failed for " + jobTestResultsUrl);
},
success: function(data){
console.log('Request is success for ' + jobTestResultsUrl);
listOfFailures = data;
}
});
return listOfFailures;
}