Files
OpenBB/tests/openbb_terminal/cryptocurrency/defi/test_substack_view.py
Colin Delahunty 5bc7bc070e Tests over API Best Practices (#2344)
* Started new tests

* Added special function

* Improved dict

* Finished new test

* Got bad functions to 75

* Got bad func to 73

* Bad func down to 60

* Bad func down to 50

* Bad func down to 35

* Got bad func to 30

* No more bad functions

* Added tests

* Added fix

* Fixed some tests

* Fixed some tests

* Fixed some tests

* Fixed some tests

* Added tests to CI

* Fixed CI tests

* Fixed CI tests

* Imrproved CI tests

* Fixed reports

* Fixed reports

* Added stuff

* Removed CI

* Fixed

* Fixed some typing'

Co-authored-by: minhhoang1023 <40023817+minhhoang1023@users.noreply.github.com>
2022-09-22 22:31:46 +01:00

23 lines
544 B
Python

# IMPORTATION STANDARD
# IMPORTATION THIRDPARTY
import pytest
# IMPORTATION INTERNAL
from openbb_terminal.cryptocurrency.defi import substack_view
@pytest.mark.vcr
@pytest.mark.record_stdout
def test_display_newsletters(mocker):
# MOCK EXPORT_DATA
mocker.patch(target="openbb_terminal.cryptocurrency.defi.substack_view.export_data")
# MOCK LEN
mocker.patch(
target="openbb_terminal.cryptocurrency.defi.substack_model.len",
return_value=1,
)
substack_view.display_newsletters(limit=None, export="")