Skip to content

Commit ae7290a

Browse files
lakshmanadevarul
authored andcommitted
ACP2E-1294 : Fixed test case data
1 parent 3d3924a commit ae7290a

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

dev/tests/integration/testsuite/Magento/Sales/Plugin/Model/ResourceModel/Order/OrderGridCollectionFilterTest.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
namespace Magento\Sales\Plugin\Model\ResourceModel\Order;
99

10+
use DateTime;
11+
use DateTimeInterface;
1012
use Magento\Framework\ObjectManagerInterface;
1113
use Magento\Framework\Stdlib\DateTime\TimezoneInterface;
1214
use Magento\Framework\View\Element\UiComponent\DataProvider\SearchResult;
@@ -74,6 +76,11 @@ protected function setUp(): void
7476
public function testAroundAddFieldToFilter($mainTable, $resourceModel, $field): void
7577
{
7678
$filterDate = "2021-12-13 00:00:00";
79+
if ($mainTable == 'sales_order_grid') {
80+
$filterDate = new DateTime($filterDate);
81+
$filterDate->setTimezone(new \DateTimeZone($this->timeZone->getConfigTimezone()));
82+
$filterDate->format('Y-m-d H:i:s');
83+
}
7784
$convertedDate = $this->timeZone->convertConfigTimeToUtc($filterDate);
7885

7986
$this->searchResult = $this->objectManager->create(

0 commit comments

Comments
 (0)