diff options
Diffstat (limited to 'python/tests/test_scenarios.py')
| -rw-r--r-- | python/tests/test_scenarios.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/python/tests/test_scenarios.py b/python/tests/test_scenarios.py index b7f5f9f0..4e695864 100644 --- a/python/tests/test_scenarios.py +++ b/python/tests/test_scenarios.py @@ -3,7 +3,7 @@ import datetime import numpy as np import pandas as pd -from analytics import Index, BlackSwaption, Portfolio, VolatilitySurface +from analytics import Index, BlackSwaption, Portfolio, BlackSwaptionVolSurface from pandas.tseries.offsets import BDay from analytics.scenarios import run_portfolio_scenarios, run_swaption_scenarios, run_index_scenarios @@ -18,8 +18,8 @@ class TestSenarios(unittest.TestCase): """ check that run_portfolio_scenarios match the sum of the individual pieces""" vol_shock = np.arange(-0.15, 0.3, 0.01) spread_shock = np.arange(-0.2, 0.3, 0.01) - vs = VolatilitySurface("IG", 28, trade_date=self.option_delta.trade_date) - vol_surface = vs[vs.list(model="black", source="BAML")[-1]] + vs = BlackSwaptionVolSurface("IG", 28, trade_date=self.option_delta.trade_date) + vol_surface = vs[vs.list(source="BAML")[-1]] df = run_portfolio_scenarios(self.portf, self.date_range, spread_shock, vol_shock, vol_surface) df = df.set_index(['spread', 'vol_shock'], append=True) |
