views:

54

answers:

0

I'am trying to process simple selenium test with python driver.

sel = self.selenium
sel.open(login_url)
#print sel.get_html_source()
sel.type("email", username)
sel.type("password", password)
sel.click("//input[@type='submit']")
self.wait_for_page()

self.assertFalse(sel.get_location().endswith(login_url))

Everything works fine while get_html_source line is commented. When I call get_html_source, slenenium rc hangs up. Python script is trying to receive data from server by reading from socket, but server is responseless.

Same stuff happens with:

sel.get_eval('selenium.browserbot.getCurrentWindow().document.body.innerHTML;')

On the other hand:

sel.get_eval('selenium.browserbot.getCurrentWindow().document.body.scrollTop;')

works just fine.

Update. Mb problem in response size, because:

print sel.get_eval("this.browserbot.findElement('id=block-id').innerHTML")

also works for small html blocks.