Take the 2-minute tour ×
Software Quality Assurance & Testing Stack Exchange is a question and answer site for software quality control experts, automation engineers, and software testers. It's 100% free, no registration required.

We have recently encountered a bug that we are able to reproduce manually in Internet Explorer, without any significant effort.

Same bug we have tried to reproduce also automatically, with WebDriver on Internet Explorer 8. However, even after looping the test and repeating it 100 times does not reproduce the bug, the test goes green.

I wonder what caused such a difference?

Possible reasons:

  • timing of GUI events in automated tests is different than in our manual tests (to fast, to slow, etc.)
  • WebDriver is operating on a different level of a browser API and than a user, making WebDriver less credible in simulating user behavior.
share|improve this question
    
I know that WebDriver makes direct calls to the the browse using each browser's native support for automation, while Selenium 1 "injects" javascript functions into when the browser is loaded and then uses its javascript to drive AUT within the browser. I just wonder whether IE 8 provides such native support for test automation? –  dzieciou Jul 7 at 9:49
2  
Same version of IE? No compatibility mode? No user-specific settings? If you pause the test and complete it manually using the exact browser window Selenium was driving, do you get the bug? –  Yamikuronue Jul 7 at 16:02
1  
Can you give a little more information about the specific scenario that fails manually? How does it fail? What is the failing behavior? –  Sam Woods Jul 7 at 16:19
1  
You would have to show us your test code as well, it may be an error with what you have written... –  Ardesco Jul 11 at 17:04

2 Answers 2

I have seen this sort of thing before and the problem ended up being in how the page was coded: onmouseover vs onchange in our case.

You may want to look at the the javascript events for the page, as it sounds very possible that the human interaction is causing some method to run whereas the web driver is changing objects in the DOM, and allowing web driver to push through the page without triggering the rogue javascript.

share|improve this answer

You can link up your WebDriver tests to use PhantomJSDriver and catch those pesky JavaScript errors that might cause a manual test to fail, as well.

share|improve this answer
2  
Could you give some more information on how this works? There really isn't enough in your response to answer the OP's question. –  Kate Paulk Sep 3 at 10:58
    
Can you give an example how using PhantomJSDriver allows catching those JavaScript errors? Does it report those JavaScript errors? I also wonder whether PhantomJS is not yet another incarnation of Web browser, just headless ;-), so the fact I got errors in IE doesn't mean those errors will appear in PhantomJS. –  dzieciou Sep 4 at 15:58

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.