Skip to content

Commit c21609f

Browse files
committed
MAGETWO-85998: [2.3] Refunded order still in Processing Order status
1 parent 3adb0ac commit c21609f

File tree

3 files changed

+8
-6
lines changed

3 files changed

+8
-6
lines changed

app/code/Magento/Sales/Model/Order/CreditmemoFactory.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
class CreditmemoFactory
1515
{
1616
/**
17-
* Order convert object
17+
* Order convert object.
1818
*
1919
* @var \Magento\Sales\Model\Convert\Order
2020
*/
@@ -214,7 +214,7 @@ protected function initData($creditmemo, $data)
214214
* @param int $parentQty
215215
* @return int
216216
*/
217-
private function calculateProductOptions(Item $orderItem, $parentQty)
217+
private function calculateProductOptions(Item $orderItem, int $parentQty): int
218218
{
219219
$qty = $parentQty;
220220
$productOptions = $orderItem->getProductOptions();

dev/tests/integration/testsuite/Magento/Sales/Model/Order/CreditmemoFactoryTest.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ public function testCreateByOrder(array $creditmemoData, $expectedQty)
6060
/**
6161
* @return array
6262
*/
63-
public function createByOrderDataProvider()
63+
public function createByOrderDataProvider(): array
6464
{
6565
return [
6666
[
@@ -89,6 +89,8 @@ public function createByOrderDataProvider()
8989
* Checks a case when creditmemo created from the invoice.
9090
*
9191
* @magentoDataFixture Magento/Sales/_files/invoice_with_bundle.php
92+
*
93+
* @return void
9294
*/
9395
public function testCreateByInvoice()
9496
{
@@ -104,7 +106,7 @@ public function testCreateByInvoice()
104106
* @param array $creditmemoData
105107
* @return array
106108
*/
107-
private function prepareCreditMemoData(Order $order, array $creditmemoData)
109+
private function prepareCreditMemoData(Order $order, array $creditmemoData): array
108110
{
109111
$result = [];
110112
$orderItems = $order->getAllItems();

dev/tests/integration/testsuite/Magento/Sales/_files/order_with_bundle_and_invoiced.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
OrderItemInterface::ROW_TOTAL => 102,
2929
OrderItemInterface::PRODUCT_TYPE => 'bundle',
3030
'product_options' => [
31-
'product_calculations' => 0
31+
'product_calculations' => 0,
3232
],
3333
'children' => [
3434
[
@@ -42,7 +42,7 @@
4242
OrderItemInterface::PRODUCT_TYPE => 'simple',
4343
'product_options' => [
4444
'bundle_selection_attributes' => [
45-
'qty' => 2
45+
'qty' => 2,
4646
],
4747
],
4848
],

0 commit comments

Comments
 (0)