1234567891011121314151617181920212223242526272829303132333435 |
- <?php
- namespace OSInet\Testable;
- require_once "misc/psr0.php";
- spl_autoload_register('psr0_autoload');
- class FooTest extends \PHPUnit_Framework_TestCase{
- /**
- * @var \OSInet\Testable\Foo
- */
- public $foo;
- /**
- * @var \OSInet\Testable\Foo
- */
- public $foo2;
- /**
- * Prepares the environment before running a test.
- */
- protected function setUp() {
- parent::setUp();
- $this->foo = $this->getMock('OSInet\Testable\Foo', NULL, array('bar', 'qux'));
- $rc = new \ReflectionClass($this->foo);
- print_r($rc->getMethods());
- $this->foo2 = $this->getMockBuilder('OSInet\Testable\Foo')
- ->getMock();
- $rc = new \ReflectionClass($this->foo2);
- print_r($rc->getMethods());
- }
- public function testCall() {
- $this->foo->call('http://example.com', array('system.listMethods', array()));
- }
- }
|