From 01507c54e3b0590356f4fdd2417285d6564905ec Mon Sep 17 00:00:00 2001 From: Uladzimir Asipchuk Date: Thu, 28 Apr 2022 14:48:54 +0300 Subject: [PATCH] Optimize jsoup buffer test There is no need in checking the issue for strings of length equal to 12, 13, ..., n We can check it for a string of length m, where m - is the length for which the issue can be reproduced. The change has been introduced in a view of a test failing on Android (30+ versions) DEVSIX-6565 --- .../jsoup/parser/ParserItTest.java | 24 ++++++++++++------- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/styled-xml-parser/src/test/java/com/itextpdf/styledxmlparser/jsoup/parser/ParserItTest.java b/styled-xml-parser/src/test/java/com/itextpdf/styledxmlparser/jsoup/parser/ParserItTest.java index ec2e616c4a..b0d6bb282d 100644 --- a/styled-xml-parser/src/test/java/com/itextpdf/styledxmlparser/jsoup/parser/ParserItTest.java +++ b/styled-xml-parser/src/test/java/com/itextpdf/styledxmlparser/jsoup/parser/ParserItTest.java @@ -35,17 +35,23 @@ This file is part of the iText (R) project. @Category(UnitTest.class) public class ParserItTest extends ExtendedITextTest { - @Test + public void testIssue1251() { // https://github.com/jhy/jsoup/issues/1251 - StringBuilder str = new StringBuilder("