You are here

public function Framework_MockObjectTest::testGetMockWithFixedClassNameCanProduceTheSameMockTwice in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/phpunit/phpunit-mock-objects/tests/MockObjectTest.php \Framework_MockObjectTest::testGetMockWithFixedClassNameCanProduceTheSameMockTwice()

@covers PHPUnit_Framework_MockObject_Generator::getMock

File

vendor/phpunit/phpunit-mock-objects/tests/MockObjectTest.php, line 351

Class

Framework_MockObjectTest
@since Class available since Release 3.0.0

Code

public function testGetMockWithFixedClassNameCanProduceTheSameMockTwice() {
  $mock = $this
    ->getMockBuilder('StdClass')
    ->setMockClassName('FixedName')
    ->getMock();
  $mock = $this
    ->getMockBuilder('StdClass')
    ->setMockClassName('FixedName')
    ->getMock();
  $this
    ->assertInstanceOf('StdClass', $mock);
}