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


PHP PHPUnit_Extensions_SeleniumTestCase::runDefaultAssertions方法代码示例

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


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

示例1: __call


//.........这里部分代码省略.........
                     break;
                 case 'store':
                     // store is a synonym of storeExpression
                     // and RC only understands storeExpression
                     $command = 'storeExpression';
                     break;
             }
             if (isset(self::$autoGeneratedCommands[$command]) && self::$autoGeneratedCommands[$command]['functionHelper']) {
                 $helperArguments = array($command, $arguments, self::$autoGeneratedCommands[$command]);
                 call_user_func_array(array($this, self::$autoGeneratedCommands[$command]['functionHelper']), $helperArguments);
             } else {
                 $this->doCommand($command, $arguments);
             }
             // Post-Command Actions
             switch ($command) {
                 case 'addLocationStrategy':
                 case 'allowNativeXpath':
                 case 'assignId':
                 case 'captureEntirePageScreenshot':
                 case 'captureScreenshot':
                     // intentionally empty
                     break;
                 default:
                     if ($wait) {
                         if ($this->useWaitForPageToLoad) {
                             $this->waitForPageToLoad($this->seleniumTimeout * 1000);
                         } else {
                             sleep($this->wait);
                         }
                     }
                     if ($this->sleep > 0) {
                         sleep($this->sleep);
                     }
                     $this->testCase->runDefaultAssertions($command);
             }
             break;
         case 'getWhetherThisFrameMatchFrameExpression':
         case 'getWhetherThisWindowMatchWindowExpression':
         case 'isAlertPresent':
         case 'isChecked':
         case 'isConfirmationPresent':
         case 'isCookiePresent':
         case 'isEditable':
         case 'isElementPresent':
         case 'isOrdered':
         case 'isPromptPresent':
         case 'isSomethingSelected':
         case 'isTextPresent':
         case 'isVisible':
             return $this->getBoolean($command, $arguments);
             break;
         case 'getCursorPosition':
         case 'getElementHeight':
         case 'getElementIndex':
         case 'getElementPositionLeft':
         case 'getElementPositionTop':
         case 'getElementWidth':
         case 'getMouseSpeed':
         case 'getSpeed':
         case 'getXpathCount':
             $result = $this->getNumber($command, $arguments);
             if ($wait) {
                 $this->waitForPageToLoad($this->seleniumTimeout * 1000);
             }
             return $result;
             break;
开发者ID:febryantosulistyo,项目名称:ClassicSocial,代码行数:67,代码来源:Driver.php

示例2: __call


//.........这里部分代码省略.........
         case 'uncheck':
         case 'windowFocus':
         case 'windowMaximize':
             // Pre-Command Actions
             switch ($command) {
                 case 'open':
                 case 'openWindow':
                     if ($this->collectCodeCoverageInformation) {
                         $this->deleteCookie('PHPUNIT_SELENIUM_TEST_ID', '/');
                         $this->createCookie('PHPUNIT_SELENIUM_TEST_ID=' . $this->testId, 'path=/');
                     }
                     break;
             }
             $this->doCommand($command, $arguments);
             // Post-Command Actions
             switch ($command) {
                 case 'addLocationStrategy':
                 case 'allowNativeXpath':
                 case 'assignId':
                 case 'captureScreenshot':
                     // intentionally empty
                     break;
                 default:
                     if ($wait) {
                         if ($this->useWaitForPageToLoad) {
                             $this->doCommand('waitForPageToLoad', array($this->timeout));
                         } else {
                             sleep($this->wait);
                         }
                     }
                     if ($this->sleep > 0) {
                         sleep($this->sleep);
                     }
                     $this->testCase->runDefaultAssertions($command);
             }
             break;
         case 'getWhetherThisFrameMatchFrameExpression':
         case 'getWhetherThisWindowMatchWindowExpression':
         case 'isAlertPresent':
         case 'isChecked':
         case 'isConfirmationPresent':
         case 'isEditable':
         case 'isElementPresent':
         case 'isOrdered':
         case 'isPromptPresent':
         case 'isSomethingSelected':
         case 'isTextPresent':
         case 'isVisible':
             return $this->getBoolean($command, $arguments);
             break;
         case 'getCursorPosition':
         case 'getElementHeight':
         case 'getElementIndex':
         case 'getElementPositionLeft':
         case 'getElementPositionTop':
         case 'getElementWidth':
         case 'getMouseSpeed':
         case 'getSpeed':
         case 'getXpathCount':
             $result = $this->getNumber($command, $arguments);
             if ($wait) {
                 $this->doCommand('waitForPageToLoad', array($this->timeout));
             }
             return $result;
             break;
         case 'getAlert':
开发者ID:xiplias,项目名称:pails,代码行数:67,代码来源:Driver.php


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