mirror of
https://github.com/OpenBB-finance/OpenBB.git
synced 2026-10-29 21:42:22 +00:00
* Expanding bot tests * expanded tests * Added tests * Added stock test * Fix filepath * Attempted mock * Bots : test_run_telegram * Enhance tests * Fixed black * Expanded tests * Added fix * Ingore interactive files * Removed bot dependency installation from tests * Fix one black * Fixed black * Added init.py * Added pylint disables * Added skip Co-authored-by: Chavithra PARANA <chavithra@gmail.com>
28 lines
610 B
Python
28 lines
610 B
Python
import pytest
|
|
|
|
try:
|
|
from bots.stocks.candle import candle_command
|
|
except ImportError:
|
|
pytest.skip(allow_module_level=True)
|
|
|
|
|
|
@pytest.fixture(scope="module")
|
|
def vcr_config():
|
|
return {
|
|
"filter_headers": [("User-Agent", None)],
|
|
"filter_query_parameters": [
|
|
("period1", "MOCK_PERIOD_1"),
|
|
("period2", "MOCK_PERIOD_2"),
|
|
("date", "MOCK_DATE"),
|
|
],
|
|
}
|
|
|
|
|
|
@pytest.mark.bots
|
|
@pytest.mark.vcr
|
|
def test_candle_command(recorder):
|
|
value = candle_command("TSLA")
|
|
|
|
value["imagefile"] = str(type(value["imagefile"]))
|
|
recorder.capture(value)
|