@Test(expectedExceptions = NullPointerException.class) public void shouldReturnErrorWhenNumberIsNull() { producer.create(currency, null); }
@Override public MonetaryAmount create(CurrencyUnit currency, Number number) { return Money.of(Objects.requireNonNull(number), Objects.requireNonNull(currency)); }
MoneyProducer implements MonetaryAmountProducer { @Override public MonetaryAmount create(CurrencyUnit currency, Number number) { return Money.of(Objects.requireNonNull(number), Objects.requireNonNull(currency)); } }
MoneyProducer implements MonetaryAmountProducer { @Override public MonetaryAmount create(CurrencyUnit currency, Number number) { return Money.of(Objects.requireNonNull(number), Objects.requireNonNull(currency)); }  }
MoneyProducer implements MonetaryAmountProducer { @Override public MonetaryAmount create(CurrencyUnit currency, Number number) { return Money.of(Objects.requireNonNull(number), Objects.requireNonNull(currency)); }  @Override MonetaryAmount create(CurrencyUnit currency, Number number); }
MoneyProducer implements MonetaryAmountProducer { @Override public MonetaryAmount create(CurrencyUnit currency, Number number) { return Money.of(Objects.requireNonNull(number), Objects.requireNonNull(currency)); }  @Override MonetaryAmount create(CurrencyUnit currency, Number number);  }