Initial commit: fx_quant_engine and options_quant_engine scaffold

This commit is contained in:
Pramit Dutta
2026-03-30 17:20:45 +05:30
commit bfd32becc7
114 changed files with 4974 additions and 0 deletions
@@ -0,0 +1,20 @@
import os
import pytest
from options_quant_engine.ingestion.credentials import load_credentials
def test_load_credentials_success(monkeypatch: pytest.MonkeyPatch) -> None:
monkeypatch.setenv("BREEZE_API_KEY", "k")
monkeypatch.setenv("BREEZE_API_SECRET", "s")
creds = load_credentials("BREEZE", required=["API_KEY", "API_SECRET"])
assert creds.get("api_key") == "k"
assert creds.get("api_secret") == "s"
def test_load_credentials_missing_required(monkeypatch: pytest.MonkeyPatch) -> None:
monkeypatch.delenv("ZERODHA_API_KEY", raising=False)
monkeypatch.delenv("ZERODHA_ACCESS_TOKEN", raising=False)
with pytest.raises(RuntimeError):
load_credentials("ZERODHA", required=["API_KEY", "ACCESS_TOKEN"])