### Question:
AskOrderServiceImpl implements OrderService<AskOrder, ColoredCoinsAskOrderPlacement> { @Override public AskOrder getNextOrder(long assetId) { final TransactionalDataSource dataSource = databaseManager.getDataSource(); return askOrderTable.getNextOrder(dataSource, assetId); } AskOrderServiceImpl(
        final DatabaseManager databaseManager,
        final AskOrderTable orderAskTable,
        final Blockchain blockchain,
        final IteratorToStreamConverter<AskOrder> converter
    ); @Inject  AskOrderServiceImpl(
        final DatabaseManager databaseManager,
        final AskOrderTable orderAskTable,
        final Blockchain blockchain
    ); @Override int getCount(); @Override AskOrder getOrder(long orderId); @Override Stream<AskOrder> getAll(int from, int to); @Override Stream<AskOrder> getOrdersByAccount(long accountId, int from, int to); @Override Stream<AskOrder> getOrdersByAccountAsset(final long accountId, final long assetId, int from, int to); @Override Stream<AskOrder> getSortedOrders(long assetId, int from, int to); @Override AskOrder getNextOrder(long assetId); @Override void addOrder(Transaction transaction, ColoredCoinsAskOrderPlacement attachment); @Override void removeOrder(long orderId); @Override void updateQuantityATU(long quantityATU, AskOrder orderAsk);  }### Answer:
@Test void shouldGetNextOrder() { final long assetId = 10L; final TransactionalDataSource dataSource = mock(TransactionalDataSource.class); final AskOrder order = mock(AskOrder.class); when(databaseManager.getDataSource()).thenReturn(dataSource); when(askOrderTable.getNextOrder(dataSource, assetId)).thenReturn(order); final AskOrder orderActual = orderService.getNextOrder(assetId); assertEquals(order, orderActual); }