我在Windows 7计算机上运行我的代码验收测试,导致下面提到的问题。
Signature: somethingSearchCept
Test: tests\acceptance\test\tstCases_somethingSearch\somethingSearchCept.php
Scenario --
WebDriver::debugWebDriverLogs method has been called when webDriver is not set
WebDriver::_saveScreenshot method has been called when webDriver is not set
WebDriver::_savePageSource method has been called when webDriver is not set
Screenshot and page source were saved into 'D:\Training\codeception\tests/_out
put\' dir
ERROR
/
Codeception\Test\Cept: test
I am on page "/"
[GET] https://www.google.com/
PHP Fatal error: Call to a member function get() on null in phar://D:/Training/
codeception/codecept.phar/src/Codeception/Module/WebDriver.php on line 729
Fatal error: Call to a member function get() on null in phar://D:/Training/codec
eption/codecept.phar/src/Codeception/Module/WebDriver.php on line 729
FATAL ERROR. TESTS NOT FINISHED.
Call to a member function get() on null
in phar://D:/Training/codeception/codecept.phar/src/Codeception/Module/WebDriver
.php:729
this is the error on debug mode
当我从Windows 10计算机运行它时,它运行正常并执行验收测试。下面是我正在使用的配置。
actor: Tester
paths:
tests: tests
log: tests/_output
data: tests/_data
support: tests/_support
envs: tests/_envs
settings:
bootstrap: _bootstrap.php
colors: false
memory_limit: 1024M
extensions:
enabled:
- Codeception\Extension\RunFailed
我使用的Selenium Web驱动程序版本是3.4.0。 PHP版本是5.6。我已经下载了最新的Chrome驱动程序版本2.30。我在这做错了什么?任何帮助将不胜感激。
acceptance.suite.yml的内容如下。
# Codeception Test Suite Configuration
#
# Suite for acceptance tests.
# Perform tests in browser using the WebDriver or PhpBrowser.
# If you need both WebDriver and PHPBrowser tests - create a separate suite.
class_name: AcceptanceTester
modules:
enabled:
- WebDriver:
url: https://www.google.com/
browser: 'chrome'
- \Helper\Acceptance