diff options
Diffstat (limited to 'python/tests/test_cds.py')
| -rw-r--r-- | python/tests/test_cds.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/python/tests/test_cds.py b/python/tests/test_cds.py index 44832dea..350f722a 100644 --- a/python/tests/test_cds.py +++ b/python/tests/test_cds.py @@ -10,12 +10,12 @@ from quantlib.time.api import Date import sys sys.path.append('..') -from analytics import Index +from analytics import CreditIndex from yieldcurve import YC, ql_to_jp, get_curve class TestUpfront(unittest.TestCase): - index = Index.from_name("ig", 26, "5yr", - value_date=datetime.date(2016, 9, 21)) + index = CreditIndex("ig", 26, "5yr", + value_date=datetime.date(2016, 9, 21)) index.notional = 50e6 index.spread = 70 @@ -73,5 +73,5 @@ class TestSpreadCurve(unittest.TestCase): b = cl.pv(trade_date, step_in_date, cash_settle_date, yc, sc, True) self.assertAlmostEqual(a - b, upf) -if __name__=="__main__": +if __name__ == "__main__": unittest.main() |
