@Test public void testFirstNPrime() { Map<Boolean, List<Integer>> result = prt.firstNPrime(10); assertEquals(4, result.get(Boolean.TRUE).size()); }
@Test public void testMaxTransMorePerGrp() { Map<Boolean, Transaction> trans = prt.maxTransMorePerGrp(transactions); assertEquals(4000, trans.get(Boolean.TRUE).getTradeAmount()); assertEquals(1000, trans.get(Boolean.FALSE).getTradeAmount()); }
@Test public void testNumberOfTransMorePerGrp() { Map<Boolean, Long> trans = prt.numberOfTransMorePerGrp(transactions); assertEquals(4, trans.get(Boolean.TRUE).intValue()); assertEquals(4, trans.get(Boolean.FALSE).intValue()); }
@Test public void testTransactionMoreThan100() { Map<Boolean, List<Transaction>> trans = prt.transactionMoreThan100(transactions); assertEquals(4, trans.get(Boolean.TRUE).size()); assertEquals(4, trans.get(Boolean.FALSE).size()); }