3 import junit.framework.TestCase;
4 import org.apidesign.apifest08.currency.Convertor;
5 import org.apidesign.apifest08.currency.CurrencyValue;
6 //import static org.apidesign.apifest08.test.Currencies.CZK;
7 //import static org.apidesign.apifest08.test.Currencies.SKK;
8 //import static org.apidesign.apifest08.test.Currencies.USD;
10 /** Write a test that works with version from task A and fails with version B.
12 public class CurrencyTest extends TestCase {
13 public CurrencyTest(String n) {
17 public void testCompatibility() throws Exception {
19 Convertor c = Convertor.getConvertorIntegerString(
20 CurrencyValue.getCurrencyValue(1, "CZK"),
21 CurrencyValue.getCurrencyValue(1, "CZK")
23 c.convert("CZK", CurrencyValue.getCurrencyValue(10, "CZK"));
24 fail("Should throw exception");
25 } catch (IllegalArgumentException e) {