Пример #1
0
        public virtual void test_of_quotedSpread()
        {
            CdsIndexIsdaCreditCurveNode test = CdsIndexIsdaCreditCurveNode.ofQuotedSpread(TEMPLATE, QUOTE_ID, INDEX_ID, LEGAL_ENTITIES, 0.01);

            assertEquals(test.Label, LABEL_AUTO);
            assertEquals(test.CdsIndexId, INDEX_ID);
            assertEquals(test.LegalEntityIds, LEGAL_ENTITIES);
            assertEquals(test.ObservableId, QUOTE_ID);
            assertEquals(test.Template, TEMPLATE);
            assertEquals(test.date(VAL_DATE, REF_DATA), date(2025, 6, 20));
        }
Пример #2
0
        public virtual void test_of_pardSpread()
        {
            CdsIndexIsdaCreditCurveNode test = CdsIndexIsdaCreditCurveNode.ofParSpread(TEMPLATE_NS, QUOTE_ID, INDEX_ID, LEGAL_ENTITIES);

            assertEquals(test.Label, END_DATE.ToString());
            assertEquals(test.CdsIndexId, INDEX_ID);
            assertEquals(test.LegalEntityIds, LEGAL_ENTITIES);
            assertEquals(test.ObservableId, QUOTE_ID);
            assertEquals(test.Template, TEMPLATE_NS);
            assertEquals(test.date(VAL_DATE, REF_DATA), END_DATE);
        }
Пример #3
0
        public virtual void test_builder()
        {
            CdsIndexIsdaCreditCurveNode test = CdsIndexIsdaCreditCurveNode.builder().label(LABEL).template(TEMPLATE).observableId(QUOTE_ID).quoteConvention(CdsQuoteConvention.PAR_SPREAD).cdsIndexId(INDEX_ID).legalEntityIds(LEGAL_ENTITIES).build();

            assertEquals(test.Label, LABEL);
            assertEquals(test.CdsIndexId, INDEX_ID);
            assertEquals(test.LegalEntityIds, LEGAL_ENTITIES);
            assertEquals(test.ObservableId, QUOTE_ID);
            assertEquals(test.Template, TEMPLATE);
            assertEquals(test.date(VAL_DATE, REF_DATA), date(2025, 6, 20));
        }