Function paste values in scratch pad :param el:
(self, el=None)
| 1295 | return click_status |
| 1296 | |
| 1297 | def paste_values(self, el=None): |
| 1298 | """ |
| 1299 | Function paste values in scratch pad |
| 1300 | :param el: |
| 1301 | """ |
| 1302 | actions = ActionChains(self.driver) |
| 1303 | if "platform" in self.driver.capabilities: |
| 1304 | platform = (self.driver.capabilities["platform"]).lower() |
| 1305 | elif "platformName" in self.driver.capabilities: |
| 1306 | platform = (self.driver.capabilities["platformName"]).lower() |
| 1307 | if el: |
| 1308 | # Must step |
| 1309 | el.click() |
| 1310 | if 'mac' in platform: |
| 1311 | # Chrome Step |
| 1312 | if self.driver.capabilities['browserName'] == 'chrome': |
| 1313 | actions.key_down(Keys.SHIFT) |
| 1314 | actions.send_keys(Keys.INSERT) |
| 1315 | actions.key_up(Keys.SHIFT) |
| 1316 | actions.perform() |
| 1317 | else: |
| 1318 | # FF step |
| 1319 | el.send_keys(Keys.COMMAND + "v") |
| 1320 | else: |
| 1321 | el.send_keys(Keys.CONTROL + "v") |
| 1322 | |
| 1323 | def wait_for_element_to_be_visible(self, driver, xpath, time_value=20): |
| 1324 | """This will wait until an element is visible on page""" |
no outgoing calls