}
@Test
public void testAdaptUpdate() throws IOException, InvalidMessage, FieldNotFound {
Ticker oldTicker = getTicker();
String messageData = getMessageData("X.txt");
MarketDataIncrementalRefresh message = new MarketDataIncrementalRefresh();
message.fromString(messageData, dataDictionary, true);
log.debug(message.toXML(dataDictionary));
Ticker ticker = BTCChinaFIXAdapters.adaptUpdate(oldTicker, message);
assertEquals(CurrencyPair.BTC_CNY, ticker.getCurrencyPair());
assertEquals(1413482716000L, ticker.getTimestamp().getTime());
assertEquals(new BigDecimal("2328.08"), ticker.getBid());
assertEquals(new BigDecimal("2325.53"), ticker.getAsk());
assertEquals(new BigDecimal("2328.09"), ticker.getLast());
assertEquals(new BigDecimal("2447.87"), ticker.getHigh());
assertEquals(new BigDecimal("2316"), ticker.getLow());
assertEquals(new BigDecimal("53826.1999"), ticker.getVolume());
}