mirror of
https://github.com/aljazceru/python-teos.git
synced 2025-12-18 14:44:21 +01:00
Properly sets conf for e2e on bitcoin-cli
bitcoin-cli on e2e tests was getting the conf straight from the default, but on circle-cli it should be data from the conf file. Setting it right.
This commit is contained in:
@@ -4,7 +4,7 @@ from multiprocessing import Process
|
|||||||
from decimal import Decimal, getcontext
|
from decimal import Decimal, getcontext
|
||||||
|
|
||||||
from teos.teosd import main
|
from teos.teosd import main
|
||||||
from teos import DEFAULT_CONF
|
from teos import DATA_DIR, CONF_FILE_NAME, DEFAULT_CONF
|
||||||
from teos.utils.auth_proxy import AuthServiceProxy
|
from teos.utils.auth_proxy import AuthServiceProxy
|
||||||
|
|
||||||
from common.config_loader import ConfigLoader
|
from common.config_loader import ConfigLoader
|
||||||
@@ -16,15 +16,17 @@ END_TIME_DELTA = 10
|
|||||||
|
|
||||||
@pytest.fixture(scope="session")
|
@pytest.fixture(scope="session")
|
||||||
def bitcoin_cli():
|
def bitcoin_cli():
|
||||||
btc_connect_params = {k: v["value"] for k, v in DEFAULT_CONF.items() if k.startswith("BTC")}
|
config = get_config(DATA_DIR, CONF_FILE_NAME, DEFAULT_CONF)
|
||||||
|
print(config)
|
||||||
|
# btc_connect_params = {k: v["value"] for k, v in DEFAULT_CONF.items() if k.startswith("BTC")}
|
||||||
|
|
||||||
return AuthServiceProxy(
|
return AuthServiceProxy(
|
||||||
"http://%s:%s@%s:%d"
|
"http://%s:%s@%s:%d"
|
||||||
% (
|
% (
|
||||||
btc_connect_params.get("BTC_RPC_USER"),
|
config.get("BTC_RPC_USER"),
|
||||||
btc_connect_params.get("BTC_RPC_PASSWD"),
|
config.get("BTC_RPC_PASSWD"),
|
||||||
btc_connect_params.get("BTC_RPC_CONNECT"),
|
config.get("BTC_RPC_CONNECT"),
|
||||||
18443,
|
config.get("BTC_RPC_PORT"),
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user