public function testAdd()
 {
     $abcd = new Calculator(2, 4);
     $addition = $abcd->add();
     $this->assertEquals(6, $addition, 'addition failed!');
 }
示例#2
0
 public function testAdd()
 {
     $c = new Calculator();
     $result = $c->add(5, 10);
     $this->assertEquals(15, $result);
 }
示例#3
0
 public function testTrue()
 {
     $calculator = new Calculator();
     $actual = $calculator->add(3, 4);
     $this->assertEquals(7, $actual);
 }