@Test public void testParseInputToCommand13() { List<Double> list = new ArrayList<Double>(); list.add(1.0); list.add(2.0); String vaildInput = "add 1 !0 2 3"; History.addToHistory(new AddCmd(list).calculate()); Command output = Parser.parseInputToCommand(vaildInput); assertEquals(AddCmd.class, output.getClass()); }
@Test public void testparseInputToSubCommand() { String validInput = "sub 1 2 3"; Command cmd = Parser.parseInputToCommand(validInput); assertEquals(SubCmd.class, cmd.getClass()); }
@Test public void testparseInputToHistCommand() { String validInput = "hist"; Command cmd = Parser.parseInputToCommand(validInput); assertEquals(HistCmd.class, cmd.getClass()); }
@Test public void testparseInputToAddSquaresCommand() { String validInput = "addsquares 1 2 3"; Command cmd = Parser.parseInputToCommand(validInput); assertEquals(AddSquaresCmd.class, cmd.getClass()); }
@Test public void testparseInputToCommand10() { String validInput = "div 1 2 3"; Command output = Parser.parseInputToCommand(validInput); assertEquals(DivCmd.class, output.getClass()); }
@Test public void testparseInputToCommand9() { String validInput = "mul 1 2 3 4"; Command output = Parser.parseInputToCommand(validInput); assertEquals(MulCmd.class, output.getClass()); }