"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "analysis/common/src/test/org/apache/lucene/analysis/charfilter/HTMLStripCharFilterTest.java" between
lucene-7.6.0-src.tgz and lucene-7.7.0-src.tgz

About: Lucene is a Java full-text search engine (not a complete application, but rather a code library and API; java source code).

HTMLStripCharFilterTest.java  (lucene-7.6.0-src.tgz):HTMLStripCharFilterTest.java  (lucene-7.7.0-src.tgz)
skipping to change at line 499 skipping to change at line 499
} }
public void testCDATA() throws Exception { public void testCDATA() throws Exception {
int maxNumElems = 100; int maxNumElems = 100;
String randomHtmlishString1 // Don't create a comment (disallow "<!--") and don't include a closing ">" String randomHtmlishString1 // Don't create a comment (disallow "<!--") and don't include a closing ">"
= TestUtil.randomHtmlishString(random(), maxNumElems).replaceAll(">", " ").replaceFirst("^--","__"); = TestUtil.randomHtmlishString(random(), maxNumElems).replaceAll(">", " ").replaceFirst("^--","__");
String closedAngleBangNonCDATA = "<!" + randomHtmlishString1 +"-[CDATA[&]]>" ; String closedAngleBangNonCDATA = "<!" + randomHtmlishString1 +"-[CDATA[&]]>" ;
String randomHtmlishString2 // Don't create a comment (disallow "<!--") and don't include a closing ">" String randomHtmlishString2 // Don't create a comment (disallow "<!--") and don't include a closing ">"
= TestUtil.randomHtmlishString(random(), maxNumElems).replaceAll(">", " ").replaceFirst("^--","__"); = TestUtil.randomHtmlishString(random(), maxNumElems).replaceAll(">", " ").replaceFirst("^--","__");
String unclosedAngleBangNonCDATA = "<!" + randomHtmlishString1 +"-[CDATA["; String unclosedAngleBangNonCDATA = "<!" + randomHtmlishString2 +"-[CDATA[";
String[] testGold = { String[] testGold = {
"one<![CDATA[<one><two>three<four></four></two></one>]]>two", "one<![CDATA[<one><two>three<four></four></two></one>]]>two",
"one<one><two>three<four></four></two></one>two", "one<one><two>three<four></four></two></one>two",
"one<![CDATA[two<![CDATA[three]]]]><![CDATA[>four]]>five", "one<![CDATA[two<![CDATA[three]]]]><![CDATA[>four]]>five",
"onetwo<![CDATA[three]]>fourfive", "onetwo<![CDATA[three]]>fourfive",
"<! [CDATA[&]]>", "", "<! [CDATA[&]]>", "",
"<! [CDATA[&] ] >", "", "<! [CDATA[&] ] >", "",
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)