Skip to content

Commit 681e761

Browse files
author
Vidya Raghavan
committed
Update calculator_test.php
1 parent 96d755d commit 681e761

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/calculator_test.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public function testAdd(){
1717
public function testSubtract(){
1818
$calc = new Calculator();
1919
$difference = $calc->subtract(5,2);
20-
$this->assertEquals(2, $difference); //check if 5 - 2 is equal to 3
20+
$this->assertEquals(3, $difference); //check if 5 - 2 is equal to 3
2121
}
2222

2323
//test if the multiply() method in our calculator class
@@ -26,7 +26,7 @@ public function testSubtract(){
2626
public function testMultiply(){
2727
$calc = new Calculator();
2828
$product = $calc->multiply(array(1,3,5,6));
29-
$this->assertEquals(91, $product); //check if 1*3*5*6 is equal to 90
29+
$this->assertEquals(90, $product); //check if 1*3*5*6 is equal to 90
3030
}
3131

3232
//test if the divide() method in our calculator class
@@ -35,7 +35,7 @@ public function testMultiply(){
3535
public function testDivide(){
3636
$calc = new Calculator();
3737
$quotient = $calc->divide(10,2);
38-
$this->assertEquals(15, $quotient); //check if 10/2 is equal to 5
38+
$this->assertEquals(5, $quotient); //check if 10/2 is equal to 5
3939
}
4040
}
4141
?>

0 commit comments

Comments
 (0)