Skip to content

Commit a941541

Browse files
committed
Testing on PHP v8.0
1 parent 0de20c3 commit a941541

13 files changed

+30
-27
lines changed

Diff for: .travis.yml

+4-1
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,15 @@ php:
66
- 5.6
77
- 7.0
88
- 7.1
9+
- 7.3
10+
- 7.4
11+
- 8.0
912

1013
sudo: false
1114

1215
before_script:
1316
- composer install --prefer-dist
1417

1518
script:
16-
- phpunit test-runner.php .
19+
- phpunit TestRunner.php .
1720

Diff for: CustomerProfiles/create-customer-payment-profile.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,6 @@ function createCustomerPaymentProfile($existingcustomerprofileid, $phoneNumber)
7979
}
8080

8181
if (!defined('DONT_RUN_SAMPLES')) {
82-
createCustomerPaymentProfile("1807545561", "000-000-0009");
82+
createCustomerPaymentProfile("1929905607", "000-000-0009");
8383
}
8484
?>

Diff for: CustomerProfiles/create-customer-shipping-address.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
define("AUTHORIZENET_LOG_FILE", "phplog");
88

9-
function createCustomerShippingAddress($existingcustomerprofileid = "36152127",
9+
function createCustomerShippingAddress($existingcustomerprofileid = "1929905607",
1010
$phoneNumber="000-000-0000"
1111
) {
1212
/* Create a merchantAuthenticationType object with authentication details

Diff for: CustomerProfiles/delete-customer-payment-profile.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66

77
define("AUTHORIZENET_LOG_FILE", "phplog");
88

9-
function deleteCustomerPaymentProfile($customerProfileId= "36152127",
10-
$customerpaymentprofileid = "32689274"
9+
function deleteCustomerPaymentProfile($customerProfileId= "1929905607",
10+
$customerpaymentprofileid = "1842074814"
1111
) {
1212
/* Create a merchantAuthenticationType object with authentication details
1313
retrieved from the constants file */

Diff for: CustomerProfiles/delete-customer-profile.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -39,5 +39,5 @@ function deleteCustomerProfile($customerProfileId)
3939
}
4040

4141
if(!defined('DONT_RUN_SAMPLES'))
42-
deleteCustomerProfile("38958129");
42+
deleteCustomerProfile("1929905651");
4343
?>

Diff for: CustomerProfiles/delete-customer-shipping-address.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
define("AUTHORIZENET_LOG_FILE", "phplog");
88

9-
function deleteCustomerShippingAddress($customerprofileid = "36731856", $customeraddressid = "36976434")
9+
function deleteCustomerShippingAddress($customerprofileid = "1929905607", $customeraddressid = "901116911")
1010
{
1111
/* Create a merchantAuthenticationType object with authentication details
1212
retrieved from the constants file */

Diff for: CustomerProfiles/get-customer-payment-profile.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77

88
define("AUTHORIZENET_LOG_FILE", "phplog");
99

10-
function getCustomerPaymentProfile($customerProfileId="36731856",
11-
$customerPaymentProfileId= "33211899"
10+
function getCustomerPaymentProfile($customerProfileId="1929905607",
11+
$customerPaymentProfileId= "1842074814"
1212
) {
1313
/* Create a merchantAuthenticationType object with authentication details
1414
retrieved from the constants file */

Diff for: CustomerProfiles/update-customer-shipping-address.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,5 +54,5 @@ function updateCustomerShippingAddress($customerprofileid, $customeraddressid)
5454
return $response;
5555
}
5656
if(!defined('DONT_RUN_SAMPLES'))
57-
updateCustomerShippingAddress( "36152127","36976566");
57+
updateCustomerShippingAddress( "1929905607","901116911");
5858
?>

Diff for: CustomerProfiles/validate-customer-payment-profile.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66

77
define("AUTHORIZENET_LOG_FILE", "phplog");
88

9-
function validateCustomerPaymentProfile($customerProfileId= "36731856",
10-
$customerPaymentProfileId= "33211899"
9+
function validateCustomerPaymentProfile($customerProfileId= "1929905607",
10+
$customerPaymentProfileId= "1842074814"
1111
) {
1212
/* Create a merchantAuthenticationType object with authentication details
1313
retrieved from the constants file */

Diff for: RecurringBilling/cancel-subscription.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,6 @@ function cancelSubscription($subscriptionId)
4545
}
4646

4747
if(!defined('DONT_RUN_SAMPLES'))
48-
cancelSubscription("3056945");
48+
cancelSubscription("7087965");
4949

5050
?>

Diff for: RecurringBilling/create-subscription.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ function createSubscription($intervalLength)
2828

2929
$paymentSchedule = new AnetAPI\PaymentScheduleType();
3030
$paymentSchedule->setInterval($interval);
31-
$paymentSchedule->setStartDate(new DateTime('2020-08-30'));
31+
$paymentSchedule->setStartDate(new DateTime('2035-12-30'));
3232
$paymentSchedule->setTotalOccurrences("12");
3333
$paymentSchedule->setTrialOccurrences("1");
3434

Diff for: test-runner.php renamed to TestRunner.php

File renamed without changes.

Diff for: TransactionReporting/get-transaction-list.php

+13-13
Original file line numberDiff line numberDiff line change
@@ -30,19 +30,19 @@ function getTransactionList()
3030

3131
if (($response != null) && ($response->getMessages()->getResultCode() == "Ok"))
3232
{
33-
echo "SUCCESS: Get Transaction List for BatchID : " . $batchId . "\n\n";
34-
if ($response->getTransactions() == null) {
35-
echo "No Transaction to display in this Batch.";
36-
return ;
37-
}
38-
//Displaying the details of each transaction in the list
39-
foreach ($response->getTransactions() as $transaction) {
40-
echo " ->Transaction Id : " . $transaction->getTransId() . "\n";
41-
echo " Submitted on (Local) : " . date_format($transaction->getSubmitTimeLocal(), 'Y-m-d H:i:s') . "\n";
42-
echo " Status : " . $transaction->getTransactionStatus() . "\n";
43-
echo " Settle amount : " . number_format($transaction->getSettleAmount(), 2, '.', '') . "\n";
44-
}
45-
}
33+
echo "SUCCESS: Get Transaction List for BatchID : " . $batchId . "\n\n";
34+
if ($response->getTransactions() == null) {
35+
echo "No Transaction to display in this Batch.";
36+
return $response;
37+
}
38+
//Displaying the details of each transaction in the list
39+
foreach ($response->getTransactions() as $transaction) {
40+
echo " ->Transaction Id : " . $transaction->getTransId() . "\n";
41+
echo " Submitted on (Local) : " . date_format($transaction->getSubmitTimeLocal(), 'Y-m-d H:i:s') . "\n";
42+
echo " Status : " . $transaction->getTransactionStatus() . "\n";
43+
echo " Settle amount : " . number_format($transaction->getSettleAmount(), 2, '.', '') . "\n";
44+
}
45+
}
4646
else
4747
{
4848
echo "ERROR : Invalid response\n";

0 commit comments

Comments
 (0)