summaryrefslogtreecommitdiffstats
path: root/php-patchwork-utf8-pull-request-64.patch
diff options
context:
space:
mode:
Diffstat (limited to 'php-patchwork-utf8-pull-request-64.patch')
-rw-r--r--php-patchwork-utf8-pull-request-64.patch24
1 files changed, 24 insertions, 0 deletions
diff --git a/php-patchwork-utf8-pull-request-64.patch b/php-patchwork-utf8-pull-request-64.patch
new file mode 100644
index 0000000..f52675c
--- /dev/null
+++ b/php-patchwork-utf8-pull-request-64.patch
@@ -0,0 +1,24 @@
+From de6f3d43ad6a2a4f15b457c5db5ccd9439576de2 Mon Sep 17 00:00:00 2001
+From: Shawn Iwinski <siwinski@redhat.com>
+Date: Sat, 25 Feb 2017 11:15:45 -0500
+Subject: [PATCH] Fix tests for PHP 7.1 negative string offsets (fixes #61)
+
+---
+ tests/PHP/Shim/MbstringTest.php | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/tests/PHP/Shim/MbstringTest.php b/tests/PHP/Shim/MbstringTest.php
+index fe3cfbe..bdb1a7d 100644
+--- a/tests/PHP/Shim/MbstringTest.php
++++ b/tests/PHP/Shim/MbstringTest.php
+@@ -158,6 +158,10 @@ public function testmb_strpos_empty_delimiter()
+ */
+ public function testmb_strpos_negative_offset()
+ {
++ if (version_compare(PHP_VERSION, '7.1', '>=')) {
++ $this->markTestSkipped('PHP >= 7.1 supports negative string offsets');
++ }
++
+ try {
+ mb_strpos('abc', 'a', -1);
+ $this->assertFalse(true, 'The previous line should trigger a warning (Offset not contained in string)');