if (urlPattern == null) return; //some other test takes care of this.
// In Ascii table, Line Feed (LF) decimal value is 10 and Carriage Return (CR) decimal value is 13
final int LF = 10, CR = 13;
if (urlPattern.indexOf(CR)!=-1 || urlPattern.indexOf(LF)!=-1) {
oneFailed=true;
result.failed(smh.getLocalString
("tests.componentNameConstructor",
"For [ {0} ]",
new Object[] {compName.toString()}));
result.addErrorDetails (smh.getLocalString
(getClass().getName() + ".failed",
"url-pattern [ {0} ] within [ {1} ] contains a carriage return or line feed char",
new Object[] {urlPattern, descriptor.getName()}));
} else {
result.passed(smh.getLocalString
("tests.componentNameConstructor",
"For [ {0} ]",
new Object[] {compName.toString()}));
result.addGoodDetails (smh.getLocalString
(getClass().getName() + ".passed",
"url-pattern [ {0} ] within [ {1} ] does not contain carriage return or line feed char",
new Object[] {urlPattern, descriptor.getName()}));
}