tests for session_controller

This commit is contained in:
hjoaquim
2023-02-03 13:14:55 +00:00
parent 10aafd139d
commit 4622e30ce8
3 changed files with 28 additions and 1 deletions

View File

@@ -14,7 +14,7 @@ from openbb_terminal.rich_config import console
def display_welcome_message():
"""Display welcome message"""
with open(PACKAGE_DIRECTORY / "session" / "banner.txt") as f:
console.print(f.read(), style="menu")
console.print(f"[menu]{f.read()}[/menu]")
def get_user_input() -> Tuple[str, str, bool]:

View File

@@ -0,0 +1,8 @@
import pytest
from openbb_terminal.session import session_controller
@pytest.mark.record_stdout
def test_display_welcome_message():
session_controller.display_welcome_message()

View File

@@ -0,0 +1,19 @@
[menu] ___ ____ ____ _____ _ _
/ _ \ _ __ ___ _ __ | __ )| __ )_ _|__ _ __ _ __ ___ (_)_ __ __ _| |
| | | | '_ \ / _ \ '_ \| _ \| _ \ | |/ _ \ '__| '_ ` _ \| | '_ \ / _` | |
| |_| | |_) | __/ | | | |_) | |_) || | __/ | | | | | | | | | | | (_| | |
\___/| .__/ \___|_| |_|____/|____/ |_|\___|_| |_| |_| |_|_|_| |_|\__,_|_|
|_|
@@@
@@@
@@@@@@@@@@@@@@@@@@@@@@@ @@@@@@@@@@@@@@@@@@@@@@@
@@@ @@@ @@@ @@@
@@@@@@@@@@@@@@@@@@@@@@@ @@@@@@@@@@@@@@@@@@@@@@@
@@@ @@@
%%%%%%%%%%%%%%%%%@@@ @@@%%%%%%%%%%%%%%%%%
@@@@@@@@@@@@@@@@@@@@ @@@@@@@@@@@@@@@@@@@@
@@@ @@@ @@@ @@@
@@@@@@@@@@@@@@@@@@@@ @@@@@@@@@@@@@@@@@@@@
Investment research for Everyone, Anywhere.
[/menu]