Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
kongzii committed Oct 11, 2024
1 parent 95a7400 commit 173cfd5
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions tests/test_insights_cache.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,20 @@
from prediction_market_agent_tooling.gtypes import HexAddress, HexStr
from prediction_market_agent_tooling.tools.utils import utcnow

from labs_api.insights_cache import MarketInsightsResponse, MarketInsightsResponseCache
from labs_api.insights.insights_cache import (
MarketInsightsResponse,
MarketInsightsResponseCache,
)


@pytest.fixture
def market_insights_response_cache(
postgresql: psycopg.Connection,
) -> Generator[MarketInsightsResponseCache, None, None]:
sqlalchemy_db_url = f"postgresql+psycopg2://{postgresql.info.user}:@{postgresql.info.host}:{postgresql.info.port}/{postgresql.info.dbname}"
db_storage = MarketInsightsResponseCache(sqlalchemy_db_url=sqlalchemy_db_url)
db_storage = MarketInsightsResponseCache(
cache_expiry_days=3, sqlalchemy_db_url=sqlalchemy_db_url
)
yield db_storage


Expand Down

0 comments on commit 173cfd5

Please sign in to comment.