[jruby-joni] 23/31: enable tests for 7 bit matching

Hideki Yamane henrich at moszumanska.debian.org
Sat Feb 24 10:44:59 UTC 2018


This is an automated email from the git hooks/post-receive script.

henrich pushed a commit to branch debian/sid
in repository jruby-joni.

commit 248caea8ca43264df61533c98d524bb087febd63
Author: Marcin Mielzynski <lopx at gazeta.pl>
Date:   Fri Feb 2 20:59:22 2018 +0100

    enable tests for 7 bit matching
---
 test/org/joni/test/Test.java | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/test/org/joni/test/Test.java b/test/org/joni/test/Test.java
index 992b758..88c1a88 100644
--- a/test/org/joni/test/Test.java
+++ b/test/org/joni/test/Test.java
@@ -125,9 +125,11 @@ public abstract class Test {
             return Matcher.FAILED;
         }
 
-        int result = check(reg, pattern, str, option, from, to, mem, not);
+        if (encoding().isAsciiCompatible() && is7bit(str, 0, str.length)) {
+            check(reg, pattern, str, option | Option.CR_7_BIT, from, to, mem, not);
+        }
 
-        return result;
+        return check(reg, pattern, str, option, from, to, mem, not);
     }
 
     private int check(Regex reg, byte[]pattern, byte[]str, int option, int from, int to, int mem, boolean not) throws InterruptedException {

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/jruby-joni.git



More information about the pkg-java-commits mailing list