SubtractAdding { public int subtract(int inputA, int inputB) { return inputA + negate(inputB); }  int subtract(int inputA, int inputB);  }
@Test public void shouldReturnZeroIfInputsAreZero() { int inputA = 0; int inputB = 0; int result = subtractAdding.subtract(inputA, inputB); assertEquals(0, result); }
@Test public void shouldReturnZeroIfInputsAreEquals() { int inputA = 30; int inputB = 30; int result = subtractAdding.subtract(inputA, inputB); assertEquals(0, result); }
@Test public void shouldReturnAPositiveResultIfFirstInputIsGreaterThanTheSecondOne() { int inputA = 33; int inputB = 30; int result = subtractAdding.subtract(inputA, inputB); assertEquals(3, result); }
@Test public void shouldReturnANegativeResultIfFirstInputIsLessThanTheSecondOne() { int inputA = 30; int inputB = 35; int result = subtractAdding.subtract(inputA, inputB); assertEquals(-5, result); }
@Test public void shouldCalculateTheCorrectSubtractionIfOneOfTheIntegersIsNegative() { int inputA = 30; int inputB = -35; int result = subtractAdding.subtract(inputA, inputB); assertEquals(65, result); }
@Test public void shouldCalculateTheCorrectSubttractionIfBothIntegersAreNegative() { int inputA = -30; int inputB = -35; int result = subtractAdding.subtract(inputA, inputB); assertEquals(5, result); }