You are here

public function Framework_MockBuilderTest::testConstructorArgumentsCanBeSpecified in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/phpunit/phpunit-mock-objects/tests/MockBuilderTest.php \Framework_MockBuilderTest::testConstructorArgumentsCanBeSpecified()

File

vendor/phpunit/phpunit-mock-objects/tests/MockBuilderTest.php, line 55

Class

Framework_MockBuilderTest
@since File available since Release 1.0.0

Code

public function testConstructorArgumentsCanBeSpecified() {
  $spec = $this
    ->getMockBuilder('Mockable');
  $spec
    ->setConstructorArgs($expected = array(
    23,
    42,
  ));
  $mock = $spec
    ->getMock();
  $this
    ->assertEquals($expected, $mock->constructorArgs);
}