当前位置: 首页>>代码示例>>PHP>>正文


PHP BrowserInterface::selectWindow方法代码示例

本文整理汇总了PHP中Magento\Mtf\Client\BrowserInterface::selectWindow方法的典型用法代码示例。如果您正苦于以下问题:PHP BrowserInterface::selectWindow方法的具体用法?PHP BrowserInterface::selectWindow怎么用?PHP BrowserInterface::selectWindow使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Magento\Mtf\Client\BrowserInterface的用法示例。


在下文中一共展示了BrowserInterface::selectWindow方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: processAssert

 /**
  * Assert that created CMS page with 'Status' - Disabled displays with '404 Not Found' message on Frontend.
  *
  * @param CmsPage $cms
  * @param FrontCmsIndex $frontCmsIndex
  * @param CmsPageIndex $cmsIndex
  * @param BrowserInterface $browser
  * @return void
  */
 public function processAssert(CmsPage $cms, FrontCmsIndex $frontCmsIndex, CmsPageIndex $cmsIndex, BrowserInterface $browser)
 {
     $cmsIndex->open();
     $filter = ['title' => $cms->getTitle()];
     $cmsIndex->getCmsPageGridBlock()->searchAndPreview($filter);
     $browser->selectWindow();
     \PHPUnit_Framework_Assert::assertEquals(self::NOT_FOUND_MESSAGE, $frontCmsIndex->getTitleBlock()->getTitle(), 'Wrong page is displayed.');
 }
开发者ID:pradeep-wagento,项目名称:magento2,代码行数:17,代码来源:AssertCmsPageDisabledOnFrontend.php

示例2: processAssert

 /**
  * Assert that content of created cms page displayed in section 'maincontent' and equals passed from fixture.
  *
  * @param CmsPageIndex $cmsIndex
  * @param FrontCmsIndex $frontCmsIndex
  * @param FrontCmsPage $frontCmsPage
  * @param CmsPage $cms
  * @param BrowserInterface $browser
  * @return void
  */
 public function processAssert(CmsPageIndex $cmsIndex, FrontCmsIndex $frontCmsIndex, FrontCmsPage $frontCmsPage, CmsPage $cms, BrowserInterface $browser)
 {
     $cmsIndex->open();
     $filter = ['title' => $cms->getTitle()];
     $cmsIndex->getCmsPageGridBlock()->searchAndPreview($filter);
     $browser->selectWindow();
     $fixtureContent = $cms->getContent();
     \PHPUnit_Framework_Assert::assertContains($fixtureContent['content'], $frontCmsPage->getCmsPageBlock()->getPageContent(), 'Wrong content is displayed.');
     if (isset($fixtureContent['widget'])) {
         foreach ($fixtureContent['widget']['preset'] as $widget) {
             \PHPUnit_Framework_Assert::assertTrue($frontCmsPage->getCmsPageBlock()->isWidgetVisible($widget['widget_type'], $widget['anchor_text']), 'Widget \'' . $widget['widget_type'] . '\' is not displayed.');
         }
     }
     if ($cms->getContentHeading()) {
         \PHPUnit_Framework_Assert::assertEquals($cms->getContentHeading(), $frontCmsIndex->getTitleBlock()->getTitle(), 'Wrong title is displayed.');
     }
 }
开发者ID:shabbirvividads,项目名称:magento2,代码行数:27,代码来源:AssertCmsPagePreview.php

示例3: run

 /**
  * Click on "Print Order" button.
  *
  * @return void
  */
 public function run()
 {
     $this->salesGuestView->getActionsToolbar()->clickLink('Print Order');
     $this->browser->selectWindow();
 }
开发者ID:cewolf2002,项目名称:magento,代码行数:10,代码来源:PrintOrderOnFrontendStep.php

示例4: processAssert

 /**
  * Assert that newsletter preview opened in new window and template content correct
  *
  * @param BrowserInterface $browser
  * @param TemplatePreview $templatePreview
  * @param Template $newsletter
  * @return void
  */
 public function processAssert(BrowserInterface $browser, TemplatePreview $templatePreview, Template $newsletter)
 {
     $browser->selectWindow();
     $content = $templatePreview->getContent()->getPageContent();
     $browser->closeWindow();
     \PHPUnit_Framework_Assert::assertEquals($newsletter->getText(), $content, 'Template content not correct information.');
 }
开发者ID:kidaa30,项目名称:magento2-platformsh,代码行数:15,代码来源:AssertNewsletterPreview.php


注:本文中的Magento\Mtf\Client\BrowserInterface::selectWindow方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。