From dc4f186bcc4d8af619df29040da998fc2fb1d2db Mon Sep 17 00:00:00 2001 From: kakaska Date: Tue, 12 Feb 2019 21:28:20 +0100 Subject: [PATCH] Fix mock configuration in ClientTest --- tests/Bitpay/Client/ClientTest.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tests/Bitpay/Client/ClientTest.php b/tests/Bitpay/Client/ClientTest.php index f366e9b..70376d7 100644 --- a/tests/Bitpay/Client/ClientTest.php +++ b/tests/Bitpay/Client/ClientTest.php @@ -259,6 +259,7 @@ class ClientTest extends \PHPUnit_Framework_TestCase $invoice->method('getItem')->willReturn($item); $invoice->method('getBuyer')->willReturn($buyer); $invoice->method('setId')->will($this->returnSelf()); + $invoice->method('setToken')->will($this->returnSelf()); $invoice->method('setUrl')->will($this->returnSelf()); $invoice->method('setStatus')->will($this->returnSelf()); //$invoice->method('setBtcPrice')->will($this->returnSelf()); @@ -292,6 +293,7 @@ class ClientTest extends \PHPUnit_Framework_TestCase $invoice->method('getItem')->willReturn($item); $invoice->method('getBuyer')->willReturn($buyer); $invoice->method('setId')->will($this->returnSelf()); + $invoice->method('setToken')->will($this->returnSelf()); $invoice->method('setUrl')->will($this->returnSelf()); $invoice->method('setStatus')->will($this->returnSelf()); //$invoice->method('setBtcPrice')->will($this->returnSelf()); @@ -615,7 +617,7 @@ class ClientTest extends \PHPUnit_Framework_TestCase $invoice = $this->getMockBuilder('Bitpay\InvoiceInterface') ->setMethods( array( - 'getPrice', 'getCurrency', 'getItem', 'getBuyer', 'getTransactionSpeed', + 'getPrice', 'getTaxIncluded', 'getCurrency', 'getItem', 'getBuyer', 'getTransactionSpeed', 'getNotificationEmail', 'getNotificationUrl', 'getRedirectUrl', 'getPosData', 'getStatus', 'isFullNotifications', 'getId', 'getUrl', 'getBtcPrice', 'getInvoiceTime', 'getExpirationTime', 'getCurrentTime', 'getOrderId', 'getItemDesc', 'getItemCode', @@ -623,7 +625,8 @@ class ClientTest extends \PHPUnit_Framework_TestCase 'getBuyerState', 'getBuyerZip', 'getBuyerCountry', 'getBuyerEmail', 'getBuyerPhone', 'getExceptionStatus', 'getBtcPaid', 'getRate', 'getToken', 'getRefundAddresses', 'setId', 'setUrl', 'setStatus', 'setBtcPrice', 'setPrice', 'setInvoiceTime', 'setExpirationTime', - 'setCurrentTime', 'setBtcPaid', 'setRate', 'setToken', 'setExceptionStatus', 'isExtendedNotifications' + 'setCurrentTime', 'setBtcPaid', 'setRate', 'setToken', 'setExceptionStatus', 'isExtendedNotifications', + 'setPosData', ) ) ->getMock(); @@ -701,6 +704,7 @@ class ClientTest extends \PHPUnit_Framework_TestCase 'getCode', 'getDescription', 'getPrice', + 'getTaxIncluded', 'getQuantity', 'isPhysical', )