This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/main by this push:
new 9e99ed8435 Disable test for Java 16 onwards since performance is
comparable
9e99ed8435 is described below
commit 9e99ed84350529bd63fcdf10a05f0d136a687b82
Author: Mark Thomas <[email protected]>
AuthorDate: Mon Nov 14 11:42:53 2022 +0000
Disable test for Java 16 onwards since performance is comparable
---
test/org/apache/tomcat/util/buf/TestMessageBytes.java | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/test/org/apache/tomcat/util/buf/TestMessageBytes.java
b/test/org/apache/tomcat/util/buf/TestMessageBytes.java
index 3311996394..4abc1b6374 100644
--- a/test/org/apache/tomcat/util/buf/TestMessageBytes.java
+++ b/test/org/apache/tomcat/util/buf/TestMessageBytes.java
@@ -23,8 +23,11 @@ import java.nio.charset.CodingErrorAction;
import java.nio.charset.StandardCharsets;
import org.junit.Assert;
+import org.junit.Assume;
import org.junit.Test;
+import org.apache.tomcat.util.compat.JreCompat;
+
public class TestMessageBytes {
private static final String CONVERSION_STRING =
@@ -100,6 +103,10 @@ public class TestMessageBytes {
*/
@Test
public void testConversionPerformance() {
+
+ // ISO_8859_1 conversion appears to be optimised in Java 16 onwards
+ Assume.assumeFalse(JreCompat.isJre16Available());
+
long optimized = -1;
long nonOptimized = -1;
@@ -110,7 +117,7 @@ public class TestMessageBytes {
* once to run the test and once more in case of unexpected CI /GC
* slowness. The test will exit early if possible.
*
- * MeesageBytes only optimises conversion for ISO_8859_1
+ * MessageBytes only optimises conversion for ISO_8859_1
*/
for (int i = 0; i < 3; i++) {
optimized = doTestOptimisedConversionPerformance();
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]