8 use Magento\Mtf\Constraint\AbstractConstraint;
9 use Magento\Sales\Test\Page\Adminhtml\OrderIndex;
10 use Magento\Sales\Test\Page\Adminhtml\SalesOrderView;
24 private static $message =
'Denied the payment online';
34 public function processAssert(SalesOrderView $salesOrderView, OrderIndex $orderIndex, $orderId)
37 $orderIndex->getSalesOrderGrid()->searchAndOpen([
'id' => $orderId]);
40 $infoTab = $salesOrderView->getOrderForm()->openTab(
'info')->getTab(
'info');
41 $latestComment = $infoTab->getCommentsHistoryBlock()->getLatestComment();
43 \PHPUnit\Framework\Assert::assertContains(
self::$message, $latestComment[
'comment']);
53 return 'Message about denied payment is available in Comments History section.';