Skip to content

Commit 564da01

Browse files
committed
Add description to AIM request and update related tests
1 parent 4cef58d commit 564da01

File tree

3 files changed

+8
-1
lines changed

3 files changed

+8
-1
lines changed

src/Message/AIMAbstractRequest.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,8 @@ protected function addBillingData(\SimpleXMLElement $data)
210210
$req->customer->id = $customer;
211211
}
212212

213+
$req->order->description = $this->getDescription();
214+
213215
/** @var CreditCard $card */
214216
if ($card = $this->getCard()) {
215217
// A card is present, so include billing and shipping details

tests/AIMGatewayTest.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,21 +22,25 @@ public function setUp()
2222
$this->purchaseOptions = array(
2323
'amount' => '10.00',
2424
'card' => $this->getValidCard(),
25+
'description' => 'purchase',
2526
);
2627

2728
$this->captureOptions = array(
2829
'amount' => '10.00',
2930
'transactionReference' => '12345',
31+
'description' => 'capture',
3032
);
3133

3234
$this->voidOptions = array(
3335
'transactionReference' => '12345',
36+
'description' => 'void',
3437
);
3538

3639
$this->refundOptions = array(
3740
'amount' => '10.00',
3841
'transactionReference' => '12345',
39-
'card' => $this->getValidCard()
42+
'card' => $this->getValidCard(),
43+
'description' => 'refund',
4044
);
4145
}
4246

tests/Message/AIMAuthorizeRequestTest.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ public function testGetData()
4141
"amount",
4242
"payment",
4343
"customer",
44+
"order",
4445
"billTo",
4546
"shipTo",
4647
"customerIP",

0 commit comments

Comments
 (0)