@Test
public void testConvertCurrencyLoadingError() {

    when(rateLoader.loadRate()).thenReturn(Observable.<Float>error(new RuntimeException()));
    CurrencyConverterModel model = viewModel.initAndResume();
    model.input.set("123");
    viewModel.calculate();
    verify(messageManager).showMessage(any(ActivityHolder.class), eq(R.string.error_loading_rate));
}