delete() public method

Delete the Credit Card resource for the given identifier.
public delete ( ApiContext $apiContext = null, PayPalRestCall $restCall = null ) : boolean
$apiContext PayPal\Rest\ApiContext is the APIContext for this call. It can be used to pass dynamic configuration and credentials.
$restCall PayPal\Transport\PayPalRestCall is the Rest Call Service that is used to make rest calls
return boolean
コード例 #1
0
 /**
  * @dataProvider mockProvider
  * @param CreditCard $obj
  */
 public function testDelete($obj, $mockApiContext)
 {
     $mockPPRestCall = $this->getMockBuilder('\\PayPal\\Transport\\PayPalRestCall')->disableOriginalConstructor()->getMock();
     $mockPPRestCall->expects($this->any())->method('execute')->will($this->returnValue(true));
     $result = $obj->delete($mockApiContext, $mockPPRestCall);
     $this->assertNotNull($result);
 }