I have a very simple acceptance test using codeaptions and WebDriver (it's a hybridath ("login through some" * some) Social network).
Code:
$ i = $ i = new acceptor ($ scenario); $ I- & gt; ('Register using VK account (hybridauth) and check the list of friends loaded'); $ I- & gt; AmOnPage ('/'); $ I- & gt; See ('VKontakte'); $ I- & gt; Click ("VKontakte"); $ __ Handles = Faucet; $ I- & gt; ExecuteInSelenium (Function (\ WebDriver $ webdriver) {Global handles $ __, $ __ handles = $ webdriver- & gt; getWindowHandles (); $ webdriver-> switchTo () - & gt; window (end ($ __ handles ));}); // VK popup load codecept_debug ($ I-> grabTextFrom ('# install_allow')); $ I- & gt; SeeElement ('box_login.'); $ I- & gt; Bharfeld ('email', '******'); $ I- & gt; Bharfeld ('Pass', '******'); $ I- & gt; ($ I- & gt; grabTextFrom ('# install_allow')); $ I- & gt; DontSeeElement ('oauth_error.'); The line is successfully implemented in this test, but at the end, Codeception throws a "no window" complaint about an exception:
[NoSuchWindowException] window found. The browser window may close. Create information: Version: '2.45.0', Modification: '5017cb8', Time: '2015-02-26 23:59:50' System Information: Host: '***', IP: '***', Os.name: 'linux', os.arch: 'amd64', os.version: '3.2.0-4-amd64', java.version: '1.7.0_65' driver information: driver.version: unknown
No comments:
Post a Comment