You are here

public function Framework_MockObject_GeneratorTest::testGetMockForSingletonWithReflectionSuccess in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/phpunit/phpunit-mock-objects/tests/GeneratorTest.php \Framework_MockObject_GeneratorTest::testGetMockForSingletonWithReflectionSuccess()

@requires PHP 5.4.0

File

vendor/phpunit/phpunit-mock-objects/tests/GeneratorTest.php, line 159

Class

Framework_MockObject_GeneratorTest

Code

public function testGetMockForSingletonWithReflectionSuccess() {

  // Probably, this should be moved to tests/autoload.php
  require_once __DIR__ . '/_fixture/SingletonClass.php';
  $mock = $this->generator
    ->getMock('SingletonClass', array(
    'doSomething',
  ), array(), '', false);
  $this
    ->assertInstanceOf('SingletonClass', $mock);
}