Beispiel #1
0
 /**
  * @dataProvider mockProvider
  * @param Wallet $obj
  * @param $mockApiContext
  */
 public function testGenerateAddress($obj, $mockApiContext)
 {
     $mockBlockCypherRestCall = $this->getMockBuilder('\\BlockCypher\\Transport\\BlockCypherRestCall')->disableOriginalConstructor()->getMock();
     $mockBlockCypherRestCall->expects($this->any())->method('execute')->will($this->returnValue(WalletGenerateAddressResponseTest::getJson()));
     /** @noinspection PhpParamsInspection */
     $result = $obj->generateAddress(array(), $mockApiContext, $mockBlockCypherRestCall);
     $this->assertNotNull($result);
 }
 /**
  * @dataProvider mockProvider
  * @param WalletClient $obj
  * @param PHPUnit_Framework_MockObject_MockObject|ApiContext $mockApiContext
  * @param PHPUnit_Framework_MockObject_MockObject|BlockCypherRestCall $mockBlockCypherRestCall
  */
 public function testGenerateAddress($obj, $mockApiContext, $mockBlockCypherRestCall)
 {
     $mockBlockCypherRestCall->expects($this->any())->method('execute')->will($this->returnValue(WalletGenerateAddressResponseTest::getJson()));
     $result = $obj->generateAddress(WalletTest::getObject()->getName(), array(), $mockApiContext, $mockBlockCypherRestCall);
     $this->assertNotNull($result);
 }