feat: add fundamentals parity reporting

This commit is contained in:
2026-07-23 21:17:58 +02:00
parent 361cfd7883
commit ce8c60d957
26 changed files with 1331 additions and 8 deletions
@@ -104,6 +104,22 @@ def test_net_debt_leverage_and_share_dilution():
assert d.metrics["share_count_change_yoy"].value == pytest.approx(-10.0, abs=1e-6)
def test_split_suspect_share_move_suppresses_share_and_eps_comparisons():
rows = _two_years()
for row in rows:
if row.fiscal_year == 2026:
row.shares_outstanding = 2000 # +100% resembles an unadjusted 2-for-1 split
d = fd.derive(rows)
for key in ("share_count_change_yoy", "eps_growth_yoy"):
series = d.metrics[key]
assert series.value is None
assert series.history[-1].value is None
assert "possible split" in series.caveat
assert d.metrics["revenue_growth_yoy"].value == pytest.approx(10.0)
def test_valuation_inputs():
d = fd.derive(_two_years())
# TTM diluted EPS FY2026 = 1.1+1.21+1.32+1.43 = 5.06