Logo
Fully annotated reference manual - version 1.8.12
Loading...
Searching...
No Matches
Functions
currency.cpp File Reference
#include "toplevelfixture.hpp"
#include <boost/test/unit_test.hpp>
#include <ql/currencies/all.hpp>
#include <ql/currency.hpp>
#include <qle/currencies/africa.hpp>
#include <qle/currencies/america.hpp>
#include <qle/currencies/asia.hpp>
#include <qle/currencies/europe.hpp>
#include <qle/currencies/metals.hpp>

Go to the source code of this file.

Functions

 BOOST_AUTO_TEST_CASE (testCurrency)
 

Function Documentation

◆ BOOST_AUTO_TEST_CASE()

BOOST_AUTO_TEST_CASE ( testCurrency  )

Definition at line 75 of file currency.cpp.

75 {
76
77 BOOST_TEST_MESSAGE("Testing QuantExt currencies");
78
79 Size size = sizeof(currencyData) / sizeof(currencyData[0]);
80
81 for (Size i = 0; i < size; i++) {
82 BOOST_CHECK_EQUAL(currencyData[i].ccy.name(), currencyData[i].name);
83 BOOST_CHECK_EQUAL(currencyData[i].ccy.code(), currencyData[i].code);
84 BOOST_CHECK_EQUAL(currencyData[i].ccy.numericCode(), currencyData[i].numCode);
85 }
86}