@Test public void addTest() { AddMashine sut = new AddMashine(1L); sut.add(1L); sut.add(2L); assertThat(sut.getSum(), is(4L)); }
public void add(Long value) { this.value += value; this.addedNumbers++; }
AddMashine { public void add(Long value) { this.value += value; this.addedNumbers++; } }
AddMashine { public void add(Long value) { this.value += value; this.addedNumbers++; } AddMashine(Long initialValue); }
AddMashine { public void add(Long value) { this.value += value; this.addedNumbers++; } AddMashine(Long initialValue); void add(Long value); void sub(Long value); Long getSum(); BigDecimal getAverage(); }
AddMashine { public void add(Long value) { this.value += value; this.addedNumbers++; } AddMashine(Long initialValue); void add(Long value); void sub(Long value); Long getSum(); BigDecimal getAverage();  }