Repository: ManageIQ/integration_tests

Issue:
Filling forms with dropdowns takes a long time
Picking an option from a dropdown menu can take a couple minutes. Automation just waiting for something. Below you can see the log  with form  filling.

```
2016-08-16 13:53:55,987 [I] Beginning to fill in form... (cfme/web_ui/__init__.py:1489)
2016-08-16 13:55:56,169 [E] Couldn't complete Any of the elements '(Select('select#chosen_typ', multi=False),)' did not appear as expected. at /home/dmisharo/cfme/cfme_tests/cfme/fixtures/pytest_selenium.py:275 in time, took 120.16, 200 tries (/home/dmisharo/cfme/lib/python2.7/site-packages/wait_for/__init__.py:143)
2016-08-16 13:55:56,171 [E] The last result of the call was: False (/home/dmisharo/cfme/lib/python2.7/site-packages/wait_for/__init__.py:144)
2016-08-16 13:55:56,173 [W] This element [Select('select#chosen_typ', multi=False)] couldn't be waited for (cfme/web_ui/__init__.py:1503)
2016-08-16 13:55:56,178 [D]   Filling in Select('select#chosen_typ', multi=False) with value Field (cfme/web_ui/__init__.py:1309)
2016-08-16 13:57:58,506 [E] Couldn't complete Any of the elements '(Select('select#chosen_field', multi=False),)' did not appear as expected. at /home/dmisharo/cfme/cfme_tests/cfme/fixtures/pytest_selenium.py:275 in time, took 120.69, 161 tries (/home/dmisharo/cfme/lib/python2.7/site-packages/wait_for/__init__.py:143)
2016-08-16 13:57:58,509 [E] The last result of the call was: False (/home/dmisharo/cfme/lib/python2.7/site-packages/wait_for/__init__.py:144)
2016-08-16 13:57:58,512 [W] This element [Select('select#chosen_field', multi=False)] couldn't be waited for (cfme/web_ui/__init__.py:1503)
2016-08-16 13:57:58,518 [D]   Filling in Select('select#chosen_field', multi=False) with value VM and Instance : Name (cfme/web_ui/__init__.py:1309)
2016-08-16 14:00:00,815 [E] Couldn't complete Any of the elements '(Select('select#chosen_key', multi=False),)' did not appear as expected. at /home/dmisharo/cfme/cfme_tests/cfme/fixtures/pytest_selenium.py:275 in time, took 120.37, 160 tries (/home/dmisharo/cfme/lib/python2.7/site-packages/wait_for/__init__.py:143)
2016-08-16 14:00:00,817 [E] The last result of the call was: False (/home/dmisharo/cfme/lib/python2.7/site-packages/wait_for/__init__.py:144)
2016-08-16 14:00:00,820 [W] This element [Select('select#chosen_key', multi=False)] couldn't be waited for (cfme/web_ui/__init__.py:1503)
2016-08-16 14:00:00,824 [D]   Filling in Select('select#chosen_key', multi=False) with value INCLUDES (cfme/web_ui/__init__.py:1309)
2016-08-16 14:00:03,086 [D]   Filling in [<cfme.web_ui.Input _names=('chosen_value',), _use_id=False>], with value long-test_act-vsphere55-tccwkhbumb (cfme/web_ui/__init__.py:1267)
2016-08-16 14:00:04,309 [D] Finished filling in form (cfme/web_ui/__init__.py:1516)
```



Discussion:
We need to shorten the timeout for form waiting


Resolving patch:
diff --git a/cfme/web_ui/__init__.py b/cfme/web_ui/__init__.py
--- a/cfme/web_ui/__init__.py
+++ b/cfme/web_ui/__init__.py
@@ -1494,7 +1494,7 @@ def _fill_form_list(form, values, action=None, action_always=False):
         if value is not None and form.field_valid(field):
             loc = form.locators[field]
             try:
-                sel.wait_for_element(loc)
+                sel.wait_for_element(loc, timeout=10)
             except TypeError:
                 # TypeError - when loc is not resolvable to an element, elements() will yell
                 # vvv An alternate scenario when element is not resolvable, just wait a bit.


Test patch: