fin-hub/tests/test_models.py
tegwick b6993d4a05 Bootstrap fin-hub scaffold from hub-core (CUST-WP-0025-T22/T23)
Add hub-core editable dependency, fin-specific SQLAlchemy models, and smoke tests.
2026-07-08 00:50:24 +02:00

21 lines
No EOL
812 B
Python

"""Smoke tests for fin-hub model registration."""
from fin_hub.models import Budget, BurnRate, Commitment, RunwayProjection, TokenSpend
from hub_core.models.base import Base
def test_fin_models_register_on_metadata():
tables = {table.name for table in Base.metadata.sorted_tables}
assert "fin_budgets" in tables
assert "fin_commitments" in tables
assert "fin_burn_rates" in tables
assert "fin_runway_projections" in tables
assert "fin_token_spends" in tables
def test_model_classes_importable():
assert Budget.__tablename__ == "fin_budgets"
assert Commitment.__tablename__ == "fin_commitments"
assert BurnRate.__tablename__ == "fin_burn_rates"
assert RunwayProjection.__tablename__ == "fin_runway_projections"
assert TokenSpend.__tablename__ == "fin_token_spends"