### Question:
LegAmounts implements FxConvertible<LegAmounts>, ImmutableBean, Serializable { @Override public LegAmounts convertedTo(Currency resultCurrency, FxRateProvider rateProvider) { List<LegAmount> convertedAmounts = amounts.stream() .map(amount -> amount.convertedTo(resultCurrency, rateProvider)) .collect(toImmutableList()); return of(convertedAmounts); } private  LegAmounts(
      List<LegAmount> amounts); static LegAmounts of(List<LegAmount> amounts); static LegAmounts of(LegAmount... amounts); @Override LegAmounts convertedTo(Currency resultCurrency, FxRateProvider rateProvider); static LegAmounts.Meta meta(); @Override LegAmounts.Meta metaBean(); ImmutableList<LegAmount> getAmounts(); @Override boolean equals(Object obj); @Override int hashCode(); @Override String toString();  }### Answer:
@Test public void convertedTo() { LegAmounts base = LegAmounts.of(LEG_AMOUNT_1, LEG_AMOUNT_2); LegAmounts test = base.convertedTo(Currency.GBP, FxRate.of(Currency.USD, Currency.GBP, 0.7)); assertThat(test.getAmounts().get(0).getAmount().getCurrency()).isEqualTo(Currency.GBP); assertThat(test.getAmounts().get(0).getAmount().getAmount()).isEqualTo(500d * 0.7d); assertThat(test.getAmounts().get(1).getAmount().getCurrency()).isEqualTo(Currency.GBP); assertThat(test.getAmounts().get(1).getAmount().getAmount()).isEqualTo(420d * 0.7d); }