This is a very interesting failure. When we do prototype, say with 10 testcases,Webdriver seems to have behave correctly. All testcases passes. Now when we put out test suite,after execution of 10-12 testcases,It starts failing/Skipping or erroring out. The trace we get is listed below: Traceback (most recent call last): File"C:\Users\avraciu\workspace\AutomationTesting_v2.0src\Home\IPSEC\CreateIPSEC\Create_IPSEC_GW_Term_Monthly.py", line 21, in setUpself.driver = webdriver.Firefox() File "C:\Python34\lib\site-packages\selenium\webdriver\firefox\webdriver.py", line 64, in __init__self.binary, timeout), File "C:\Python34\lib\site-packages\selenium\webdriver\firefox\extension_connection.py", line 51, in __init__self.binary.launch_browser(self.profile) File "C:\Python34\lib\site-packages\selenium\webdriver\firefox\firefox_binary.py", line 69, in launch_browser self._start_from_profile_path(self.profile.path) File "C:\Python34\lib\site-packages\selenium\webdriver\firefox\firefox_binary.py", line 92, in _start_from_profile_path env=self._firefox_env) File "C:\Python34\lib\subprocess.py", line 754, in __init___cleanup() File "C:\Python34\lib\subprocess.py", line 474, in _cleanup res = inst._internal_poll(_deadstate=sys.maxsize) File "C:\Python34\lib\subprocess.py", line 1146, in _internal_poll if _WaitForSingleObject(self._handle, 0) == _WAIT_OBJECT_0: OSError: [WinError 6] The handle is invalid |
Checkout the configuration may be that is wrong.Mostly the latest browser version and Webdriver Version do not match. Downgrade one level down for browser. It should work. On the next step downgrade the Webdriver version as well.
Next is to check the version of the OS as well as the version of the installed software's. Like-the eclipse,phython,webDriver etc. They should be as per OS. I mean if your’s is a 64 bit OS. Please use same 64 bit application as well.