File: 0002-Skip-tests-failing-on-32-bit-architectures.patch

package info (click to toggle)
php-nrk-predis 2.4.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 7,068 kB
  • sloc: php: 59,571; xml: 42; makefile: 5
file content (40 lines) | stat: -rw-r--r-- 1,531 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
From: =?utf-8?q?David_Pr=C3=A9vot?= <david@tilapin.org>
Date: Wed, 21 Jun 2023 08:00:15 +0200
Subject: Skip tests failing on 32-bit architectures

---
 tests/Predis/Command/Redis/GEOSEARCH_Test.php   | 5 +++++
 tests/Predis/Command/Redis/PEXPIRETIME_Test.php | 4 ++++
 2 files changed, 9 insertions(+)

diff --git a/tests/Predis/Command/Redis/GEOSEARCH_Test.php b/tests/Predis/Command/Redis/GEOSEARCH_Test.php
index 9d173da..6cd30bf 100644
--- a/tests/Predis/Command/Redis/GEOSEARCH_Test.php
+++ b/tests/Predis/Command/Redis/GEOSEARCH_Test.php
@@ -94,6 +94,11 @@ class GEOSEARCH_Test extends PredisCommandTestCase
         bool $withHash,
         array $expectedResponse
     ): void {
+
+        if (PHP_INT_SIZE == 4) {
+            self::markTestSkipped('Skip test failing on 32-bit architectures');
+        }
+
         $redis = $this->getClient();
 
         $redis->geoadd(...$firstCoordinates);
diff --git a/tests/Predis/Command/Redis/PEXPIRETIME_Test.php b/tests/Predis/Command/Redis/PEXPIRETIME_Test.php
index b264053..2e39678 100644
--- a/tests/Predis/Command/Redis/PEXPIRETIME_Test.php
+++ b/tests/Predis/Command/Redis/PEXPIRETIME_Test.php
@@ -63,6 +63,10 @@ class PEXPIRETIME_Test extends PredisCommandTestCase
      */
     public function testReturnsCorrectExpirationTimeForGivenKey(): void
     {
+        if (PHP_INT_SIZE == 4) {
+            self::markTestSkipped('Skip test failing on 32-bit architectures');
+        }
+
         $redis = $this->getClient();
         $expirationTime = time() * 1000 + 1000;