We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6761cf8 commit c67551cCopy full SHA for c67551c
tests/test_ticker.py
@@ -127,10 +127,14 @@ def test_bad_financials_arg():
127
128
129
def test_get_financial_data(ticker):
130
- assert (
131
- ticker.get_financial_data("GrossProfit NetIncome TotalAssets ForwardPeRatio")
132
- is not None
+ result = ticker.get_financial_data(
+ "GrossProfit NetIncome TotalAssets ForwardPeRatio"
133
)
+ assert result is not None
134
+ if isinstance(result, str):
135
+ assert "unavailable" in result.lower()
136
+ else:
137
+ assert isinstance(result, pd.DataFrame)
138
139
140
def test_p_get_financial_data(ticker):
0 commit comments