Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
AssertCmsPageNotInGrid.php
Go to the documentation of this file.
1 <?php
8 
10 use Magento\Cms\Test\Page\Adminhtml\CmsPageIndex;
11 use Magento\Mtf\Constraint\AbstractConstraint;
12 
16 class AssertCmsPageNotInGrid extends AbstractConstraint
17 {
25  public function processAssert(CmsPageIndex $cmsIndex, CmsPage $cmsPage)
26  {
27  $filter = [
28  'title' => $cmsPage->getTitle(),
29  ];
30  \PHPUnit\Framework\Assert::assertFalse(
31  $cmsIndex->getCmsPageGridBlock()->isRowVisible($filter),
32  'Cms page \'' . $cmsPage->getTitle() . '\' is present in pages grid.'
33  );
34  }
35 
41  public function toString()
42  {
43  return 'Cms page is not present in pages grid.';
44  }
45 }
processAssert(CmsPageIndex $cmsIndex, CmsPage $cmsPage)