EndpointQueryBuilder.start()
.setDynamicPath(httpMethodTest[0])
.setHttpMethod(httpMethodTest[1])
.generateQuery();
Endpoint result = db.findBestMatch(query);
String currentQuery = httpMethodTest[0] + ": " + httpMethodTest[1];
if (result == null) {
assertTrue("No result was found, but line " + httpMethodTest[2] + " was expected for " + currentQuery,
httpMethodTest[2] == null);
} else {
//String currentQuery = httpMethodTest[0] + ": " + httpMethodTest[1];
assertTrue("Got an endpoint, but was not expecting one with " + currentQuery,
httpMethodTest[2] != null);
Integer value = Integer.valueOf(httpMethodTest[2]);
assertTrue("Got " + result.getStartingLineNumber() + " but was expecting " + value + " with " + currentQuery,
value.equals(result.getStartingLineNumber()));
}
}
}