pytest-plugins icon indicating copy to clipboard operation
pytest-plugins copied to clipboard

Redis server not launched - hangs waiting for connection

Open rcarrington opened this issue 8 years ago • 0 comments

Steps to reproduce:

virtualenv -p python3.6 test_dummy_env
source test_dummy_env/bin/activate
pip install pytest-server-fixtures redis
# testit.py
def test_it(redis_server):
    redis_server.api.set('key', 1)
    assert redis_server.api.get('key') == 1
$ pytest testit.py --fulltrace -s
======================================================================================================================== test session starts =========================================================================================================================
platform linux -- Python 3.6.1, pytest-3.1.3, py-1.4.34, pluggy-0.4.0
rootdir: /home/rob/code/observer, inifile: pytest.ini
plugins: shutil-1.2.11, server-fixtures-1.2.11
collected 1 item s

testit.py pinging Redis at 127.75.17.85:20407 db 0
server not up yet (Error 111 connecting to 127.75.17.85:20407. Connection refused.)
pinging Redis at 127.75.17.85:20407 db 0
server not up yet (Error 111 connecting to 127.75.17.85:20407. Connection refused.)
pinging Redis at 127.75.17.85:20407 db 0
server not up yet (Error 111 connecting to 127.75.17.85:20407. Connection refused.)
pinging Redis at 127.75.17.85:20407 db 0
server not up yet (Error 111 connecting to 127.75.17.85:20407. Connection refused.)
pinging Redis at 127.75.17.85:20407 db 0
server not up yet (Error 111 connecting to 127.75.17.85:20407. Connection refused.)
pinging Redis at 127.75.17.85:20407 db 0
server not up yet (Error 111 connecting to 127.75.17.85:20407. Connection refused.)
pinging Redis at 127.75.17.85:20407 db 0
server not up yet (Error 111 connecting to 127.75.17.85:20407. Connection refused.)

redis-server --version

Redis server v=3.0.6 sha=00000000:0 malloc=jemalloc-3.6.0 bits=64 build=687a2a319020fa42

lsb_release -a

No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 16.04.2 LTS
Release:	16.04
Codename:	xenial

While pytest is running, if I check the process list, there's no redis-server process present.

rcarrington avatar Jul 24 '17 19:07 rcarrington