DataProviderTest.php (407B)
1 <?php 2 class DataProviderTest extends PHPUnit_Framework_TestCase 3 { 4 /** 5 * @dataProvider providerMethod 6 */ 7 public function testAdd($a, $b, $c) 8 { 9 $this->assertEquals($c, $a + $b); 10 } 11 12 public static function providerMethod() 13 { 14 return array( 15 array(0, 0, 0), 16 array(0, 1, 1), 17 array(1, 1, 3), 18 array(1, 0, 1) 19 ); 20 } 21 }