summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/toaster
diff options
context:
space:
mode:
authorElliot Smith <elliot.smith@intel.com>2016-04-19 17:28:44 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-04-19 21:11:26 +0100
commite65c9808e9bb85ffd2b668bade4b8a50e470d050 (patch)
treed71ac8fa0c8f07cd1664116d974dcc2945310f2e /bitbake/lib/toaster
parent484cbf81cf46a9751d86f1587b7bf965c7008daf (diff)
downloadpoky-e65c9808e9bb85ffd2b668bade4b8a50e470d050.tar.gz
bitbake: toaster-tests: make helper click on input before entering text
The Selenium helper's enter_text() method doesn't cause keyup events to trigger unless the element where text is being entered has been clicked. Prefix all text entry with a click() on the element to ensure that keyup events fire. (Bitbake rev: cea34880ad3847bd0e24c9b650eb816e1757cf2b) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/toaster')
-rw-r--r--bitbake/lib/toaster/tests/browser/selenium_helpers.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/bitbake/lib/toaster/tests/browser/selenium_helpers.py b/bitbake/lib/toaster/tests/browser/selenium_helpers.py
index d3ab3ca72e..56dbe2b344 100644
--- a/bitbake/lib/toaster/tests/browser/selenium_helpers.py
+++ b/bitbake/lib/toaster/tests/browser/selenium_helpers.py
@@ -185,7 +185,11 @@ class SeleniumTestCase(StaticLiveServerTestCase):
185 185
186 def enter_text(self, selector, value): 186 def enter_text(self, selector, value):
187 """ Insert text into element matching selector """ 187 """ Insert text into element matching selector """
188 field = self.wait_until_present(selector) 188 # note that keyup events don't occur until the element is clicked
189 # (in the case of <input type="text"...>, for example), so simulate
190 # user clicking the element before inserting text into it
191 field = self.click(selector)
192
189 field.send_keys(value) 193 field.send_keys(value)
190 return field 194 return field
191 195