mirror of
https://github.com/dragonflydb/dragonfly.git
synced 2025-05-11 02:15:45 +02:00
fix: pytest warnings (#3497)
* fix truncating the timeout red dots on CI failures * fix deprecated use of with timeout warnings * remove @pytest.mark.dbg_only as it doesn't exist --------- Signed-off-by: kostas <kostas@dragonflydb.io>
This commit is contained in:
parent
c756023332
commit
d37c2ec85a
3 changed files with 5 additions and 4 deletions
2
.github/actions/regression-tests/action.yml
vendored
2
.github/actions/regression-tests/action.yml
vendored
|
@ -41,6 +41,8 @@ runs:
|
|||
|
||||
# timeout returns 124 if we exceeded the timeout duration
|
||||
if [[ $code -eq 124 ]]; then
|
||||
# Add an extra new line here because when tests timeout the first line below continues from the test failure name
|
||||
echo "\n"
|
||||
echo "🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑"
|
||||
echo "🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 TESTS TIMEDOUT 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑"
|
||||
echo "🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑 🛑"
|
||||
|
|
|
@ -47,7 +47,6 @@ def test_basic(memcached_client: MCClient):
|
|||
# Noreply (and pipeline) tests
|
||||
|
||||
|
||||
@pytest.mark.dbg_only
|
||||
@dfly_args(DEFAULT_ARGS)
|
||||
def test_noreply_pipeline(df_server: DflyInstance, memcached_client: MCClient):
|
||||
"""
|
||||
|
|
|
@ -3,7 +3,7 @@ import logging
|
|||
import os
|
||||
import glob
|
||||
import asyncio
|
||||
import async_timeout
|
||||
from async_timeout import timeout
|
||||
import redis
|
||||
from redis import asyncio as aioredis
|
||||
from pathlib import Path
|
||||
|
@ -169,7 +169,7 @@ async def test_cron_snapshot(tmp_dir: Path, async_client: aioredis.Redis):
|
|||
await StaticSeeder(**LIGHTWEIGHT_SEEDER_ARGS).run(async_client)
|
||||
|
||||
file = None
|
||||
with async_timeout.timeout(65):
|
||||
async with timeout(65):
|
||||
while file is None:
|
||||
await asyncio.sleep(1)
|
||||
file = find_main_file(tmp_dir, "test-cron-summary.dfs")
|
||||
|
@ -185,7 +185,7 @@ async def test_set_cron_snapshot(tmp_dir: Path, async_client: aioredis.Redis):
|
|||
await async_client.config_set("snapshot_cron", "* * * * *")
|
||||
|
||||
file = None
|
||||
with async_timeout.timeout(65):
|
||||
async with timeout(65):
|
||||
while file is None:
|
||||
await asyncio.sleep(1)
|
||||
file = find_main_file(tmp_dir, "test-cron-set-summary.dfs")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue