Skip to content

Commit a7eb5cc

Browse files
committed
MAGETWO-75612: [FT] CreateShipmentEntityTest and CreateInvoiceEntityTest are failed on Jenkins
1 parent 2566f8d commit a7eb5cc

File tree

2 files changed

+1
-33
lines changed

2 files changed

+1
-33
lines changed

dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Shipments/Grid.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,6 @@ class Grid extends DataGrid
5252
public function getIds()
5353
{
5454
$this->waitLoader();
55-
$this->resetFilter();
5655
$result = [];
5756
$shipmentIds = $this->_rootElement->getElements($this->shipmentId);
5857
foreach ($shipmentIds as $shipmentId) {

dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/CreateInvoiceStep.php

Lines changed: 1 addition & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
namespace Magento\Sales\Test\TestStep;
88

9-
use Magento\Mtf\Fixture\FixtureInterface;
109
use Magento\Sales\Test\Fixture\OrderInjectable;
1110
use Magento\Sales\Test\Page\Adminhtml\OrderIndex;
1211
use Magento\Sales\Test\Page\Adminhtml\OrderInvoiceNew;
@@ -135,11 +134,8 @@ public function run()
135134
$this->data,
136135
$this->order->getEntityId()['products']
137136
);
138-
137+
$this->orderInvoiceNew->getFormBlock()->updateQty();
139138
$this->orderInvoiceNew->getFormBlock()->fillFormData($this->data);
140-
if ($this->compare($this->order->getEntityId()['products'], $this->data)) {
141-
$this->orderInvoiceNew->getFormBlock()->updateQty();
142-
}
143139
if (isset($this->isInvoicePartial)) {
144140
$this->orderInvoiceNew->getFormBlock()->submit();
145141
$this->salesOrderView->getPageActions()->invoice();
@@ -180,31 +176,4 @@ protected function getShipmentIds()
180176
$this->salesOrderView->getOrderForm()->openTab('shipments');
181177
return $this->salesOrderView->getOrderForm()->getTab('shipments')->getGridBlock()->getIds();
182178
}
183-
184-
/**
185-
* Compare items.
186-
*
187-
* @param FixtureInterface[] $products
188-
* @param array $data
189-
* @return bool
190-
*/
191-
private function compare(array $products, array $data)
192-
{
193-
if (empty($data['items_data'])) {
194-
return false;
195-
}
196-
197-
$count = 0;
198-
foreach ($data['items_data'] as $key => $item) {
199-
if (!isset($products[$key])) {
200-
continue;
201-
}
202-
203-
if (is_numeric($item['qty']) && $products[$key]->getData('qty') !== $item['qty']) {
204-
++$count;
205-
}
206-
}
207-
208-
return $count !== 0;
209-
}
210179
}

0 commit comments

Comments
 (0)