To test some apex functionality, we wanted to update the conversion rates of currencies in a test class. It doesn't work since DML operations aren't allowed on CurrencyType via apex.
Here is more information about the whole sitation: A custom object holds a certain amount and a currency. There is another field which holds the amount in euros. We wrote a (before insert/before update) trigger on the custom object to calculate the amount in euros based on the conversion rates of the currencies and the 2 fields on the custom object.
Every month the conversion rates will be adjusted, so the euro field also needs to be updated. We wrote a batch process to accomplish this. Now we want to write a test class for the batch process. To write a good test for the functionality, we need to update the conversion rates of the currencies, but it seems it isn't possible through apex.
Does anyone know a solution for this? Many thanks