EODTradingStrategy implements Level1QuoteListener, OrderEventListener, BrokerErrorListener { protected int getOrderSize(Ticker ticker) { double lastPrice = lastPriceMap.get(ticker); return (int) Math.round(orderSizeInDollars / lastPrice); }  void start(String propFile); synchronized void placeMOCOrders(Ticker longTicker, Ticker shortTicker, ZonedDateTime lastReportedTime); @Override void orderEvent(OrderEvent event); @Override void quoteRecieved(ILevel1Quote quote); ZonedDateTime getNextBusinessDay(ZonedDateTime date); @Override void brokerErrorFired(BrokerError error); static void main(String[] args);  }
@Test public void testGetOrderSize() { strategy.start(propFile); strategy.lastPriceMap.put(longTicker, 50.00); int expectedSize = 20; assertEquals(expectedSize, strategy.getOrderSize(longTicker)); }