forked from pool/python-fakeredis
Compare commits
2 Commits
Author | SHA256 | Date | |
---|---|---|---|
|
79f241e038 | ||
0aae007ffc |
29
fix-tests.patch
Normal file
29
fix-tests.patch
Normal file
@ -0,0 +1,29 @@
|
||||
From b6c0140e17fb571906251e0fb300a52735427bf7 Mon Sep 17 00:00:00 2001
|
||||
From: Daniel M <daniel.maruani@gmail.com>
|
||||
Date: Fri, 27 Sep 2024 14:14:53 -0400
|
||||
Subject: [PATCH] fix:tests for redis 5.1.0
|
||||
|
||||
---
|
||||
test/test_asyncredis.py | 5 +--
|
||||
test/test_mixins/test_set_commands.py | 50 +++++++++++++++++----------
|
||||
2 files changed, 35 insertions(+), 20 deletions(-)
|
||||
|
||||
diff --git a/test/test_asyncredis.py b/test/test_asyncredis.py
|
||||
index 9f623d38..c98bb515 100644
|
||||
--- a/test/test_asyncredis.py
|
||||
+++ b/test/test_asyncredis.py
|
||||
@@ -165,11 +165,12 @@ async def test_failed_script_error7(self, async_redis):
|
||||
await async_redis.eval('return redis.call("ZCOUNT", KEYS[1])', 1, "foo")
|
||||
|
||||
|
||||
+@fake_only
|
||||
@testtools.run_test_if_redispy_ver("gte", "5.1")
|
||||
async def test_repr_redis_51(async_redis: redis.asyncio.Redis):
|
||||
assert re.fullmatch(
|
||||
- r"<redis.asyncio.connection.ConnectionPool("
|
||||
- r"<fakeredis.aioredis.FakeConnection(server=<fakeredis._server.FakeServer object at .*>,db=0)>)>",
|
||||
+ r"<redis.asyncio.connection.ConnectionPool\("
|
||||
+ r"<fakeredis.aioredis.FakeConnection\(server=<fakeredis._server.FakeServer object at .*>,db=0\)>\)>",
|
||||
repr(async_redis.connection_pool),
|
||||
)
|
||||
|
@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Tue Oct 8 16:14:14 UTC 2024 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- Add upstream fix-tests.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jul 31 02:16:56 UTC 2024 - Martin Schreiner <martin.schreiner@suse.com>
|
||||
|
||||
|
@ -24,6 +24,9 @@ Summary: Fake implementation of redis API for testing purposes
|
||||
License: BSD-3-Clause AND MIT
|
||||
URL: https://github.com/cunla/fakeredis-py
|
||||
Source: https://github.com/cunla/fakeredis-py/archive/refs/tags/v%{version}.tar.gz#/fakeredis-%{version}-gh.tar.gz
|
||||
# PATCH-FIX-UPSTREAM https://github.com/cunla/fakeredis-py/commit/b6c0140e17fb571906251e0fb300a52735427bf7 fix:tests for redis 5.1.0
|
||||
# there is a new version, but the update failed for me
|
||||
Patch: fix-tests.patch
|
||||
BuildRequires: %{python_module base >= 3.7}
|
||||
BuildRequires: %{python_module pip}
|
||||
BuildRequires: %{python_module poetry-core}
|
||||
@ -35,8 +38,7 @@ Requires: python-typing_extensions >= 4.7
|
||||
Suggests: python-lupa >= 1.14
|
||||
BuildArch: noarch
|
||||
# SECTION test requirements
|
||||
# technically requires hypothesis >= 6.56, but we don't have it yet
|
||||
BuildRequires: %{python_module hypothesis}
|
||||
BuildRequires: %{python_module hypothesis >= 6.56}
|
||||
BuildRequires: %{python_module pytest >= 7.1.2}
|
||||
BuildRequires: %{python_module pytest-asyncio >= 0.19.0}
|
||||
BuildRequires: %{python_module pytest-mock >= 3.7.0}
|
||||
|
Loading…
Reference in New Issue
Block a user