selenium-webdriver

Click on check box after confirming text in html table which is dynamic

﹥>﹥吖頭↗ 提交于 2021-01-28 08:38:22
问题 I need to click on the check box in the HTML table after asserting the text. Below is the html. <div class="k-widget k-grid "> <div class="k-grid-header" style="padding: 0px 16px 0px 0px;"> <div class="k-grid-header-wrap"> <table> <colgroup> <col width="50px"> <col> <col> </colgroup> <thead> <tr> <th aria-sort="" colspan="1" rowspan="1" class="k-header checkbox-grid-column"><input id="c3c07f7e-5119-4a36-9f67-98fa4d21fa07" type="checkbox" class="k-checkbox"><label class="k-checkbox-label" for=

DeprecationWarning: use options instead of chrome_options error using Brave Browser With Python Selenium and Chromedriver on Windows

梦想与她 提交于 2021-01-28 07:11:46
问题 I want to use Selenium (installed: ver 3.141.0.dist-info) on Python (3.8) which is installed on my Windows 7 64, I Use Brave Browser Version 1.17.73 Chromium: 87.0.4280.67 (Official Build) (64-bit) and Chromedriver (chromedriver_win32-87.0.4280.20) for it, when running the following Py file which I got the code from here, new Brave browser opens up, but I get errors. Any solution to make this works? Appreciate your help. when running this file: from selenium import webdriver driver_path = 'C:

Java - drag and drop not working on selenium 3.8

走远了吗. 提交于 2021-01-28 06:18:27
问题 drag and drop not working on selenium 3.8. Here is the JS code for the element This is what I have tried. But it is only selecting the element. Hold and drop is not happening. WebElement source = driver.findElement(By.xpath("//tbody[@class ='lt-body']//tr[@data-test-id='table-row-id-20']//td[contains(@id,'ember')]//div[contains(@id,'ember')]//*[name()='svg']//*[name()='ellipse']")); WebElement destination = driver.findElement(By.xpath("//tbody[@class ='lt-body']//tr[@data-test-id='table-row

Python Selenium unable to click() button

偶尔善良 提交于 2021-01-28 06:12:39
问题 I'm trying to automate the scraping of links from here: https://thegoodpubguide.co.uk/pubs/?paged=1&order_by=category&search=pubs&pub_name=&postal_code=&region=london Once I have the first page, I want to click the right chevron at the bottom, in order to move to the second, the third and so on. Scraping the links in between. Unfortunately nothing I try will allow me to send chrome to the next page. from selenium import webdriver from selenium.webdriver.common.keys import Keys import time

How to click on open application alert using Selenium

末鹿安然 提交于 2021-01-28 05:30:37
问题 I am trying to click on open application alert using Selenium, and I am getting this error NoAlertPresentException: Message: no such alert So basically I am trying to open zoom application from the browser And here is my code: from selenium import webdriver from selenium.webdriver.support.ui import WebDriverWait from selenium.webdriver.support import expected_conditions as EC from selenium.common.exceptions import TimeoutException driver = webdriver.Chrome(executable_path='chromedriver

Сhromedriver: how to add support of Chromium-based browsers

倾然丶 夕夏残阳落幕 提交于 2021-01-28 04:36:01
问题 What is required to add a browser to the list of available browsers for UI-automation frameworks/wrappers to successfully running of autotests through the appropriate browser? For example, I want to adding browser "Sputnik", which using Chromium core. 回答1: TL;DR: Use Selenium + Codeception (or any other chrome-supported framework), add to configuration a special enviroment for "non-valid" browser as Sputnik, wherein path to binary is equivalent to your chrome-binary. Recompile chromedriver

InvalidArgumentException: Message: binary is not a Firefox executable error using GeckoDriver Firefox Selenium and Python

萝らか妹 提交于 2021-01-28 04:35:53
问题 I am having trouble with a selenium error related to a FireFox binary. I added C:/Users/Mack/AppData/Local/Programs/Python/ to PATH using backslashes and rebooted. I downloaded what I thought is the correct file here https://github.com/mozilla/geckodriver/releases I put the file in the directory connected to PATH. To remedy this: I tried using two backslashes binary = FirefoxBinary("C:\\Users\Mack\AppData\Local\Programs\Python\Python38-32\geckodriver-v0.27.0-win64\geckodriver.exe") which

Сhromedriver: how to add support of Chromium-based browsers

蹲街弑〆低调 提交于 2021-01-28 04:25:44
问题 What is required to add a browser to the list of available browsers for UI-automation frameworks/wrappers to successfully running of autotests through the appropriate browser? For example, I want to adding browser "Sputnik", which using Chromium core. 回答1: TL;DR: Use Selenium + Codeception (or any other chrome-supported framework), add to configuration a special enviroment for "non-valid" browser as Sputnik, wherein path to binary is equivalent to your chrome-binary. Recompile chromedriver

Spring SimpleThreadScope does not support descruction callbacks

不羁岁月 提交于 2021-01-28 04:02:19
问题 I would like to run parallel selenium tests (using webriver and the Spring JUnit runner). Webdriver is a spring bean with the custom thread scope. But I get a following warning SimpleThreadScope does not support descruction callbacks So the browsers are not closed. Any idea how to close them (more precisely call the quit method)? spring config <bean id="threadScope" class="org.springframework.context.support.SimpleThreadScope" /> <bean class="org.springframework.beans.factory.config

How to extract text segments from a paragraph when separated by icon image in WebDriver

本秂侑毒 提交于 2021-01-28 03:28:05
问题 I am writing a selenium test on our web page. There is one label field that has one to many text segments separated by a right-caret icon. I am trying to extract the individual text segments from the label into a list. This is what the html looks like in the DOM. In this case there are 3 individual text segments: "MainSchedule", "Container1", and "Container1.2". <p class="MuiTypography-root MuiTypography-body1" style="word-break: break-all;"> "MainSchedule" <svg aria-hidden="true" focusable=