mirror of
https://github.com/aljazceru/python-teos.git
synced 2025-12-17 14:14:22 +01:00
Dissables can_connect_to_bitcoind with a non-running backend
Until a better way of handling the stop of bitcoind the test is dissabled, it created issues with other tests.
This commit is contained in:
@@ -1,20 +1,16 @@
|
||||
import pytest
|
||||
from time import sleep
|
||||
from threading import Thread
|
||||
from multiprocessing import Process
|
||||
|
||||
from pisa.api import start_api
|
||||
from test.simulator.bitcoind_sim import run_simulator
|
||||
|
||||
bitcoind_process = Process(target=run_simulator)
|
||||
|
||||
|
||||
@pytest.fixture(scope='session')
|
||||
def run_bitcoind():
|
||||
global bitcoind_process
|
||||
|
||||
bitcoind_process.daemon = True
|
||||
bitcoind_process.start()
|
||||
bitcoind_thread = Thread(target=run_simulator)
|
||||
bitcoind_thread.daemon = True
|
||||
bitcoind_thread.start()
|
||||
|
||||
# It takes a little bit of time to start the API (otherwise the requests are sent too early and they fail)
|
||||
sleep(0.1)
|
||||
|
||||
Reference in New Issue
Block a user