随笔分类 - selenium
摘要:1、全部文字 java:driver.findElement(By.xpath("// [text()=’退出’]"); python:browser.find_element_by_xpath("// [text()='花呗套现']").click() 2、部分文字 java:driver.fin
阅读全文
摘要:· 参考:https://www.cnblogs.com/desperado0807/p/4839502.html 写网页UI自动化遇到非select下拉框一直无法成功定位元素的问题,且前端代码没有id、name之类唯一标识。尝试过xpath以及文字等方式,最后用css能定位成功
阅读全文
摘要:allure+jenkins+pytest jenkins配置 1、jenkins → 系统管理 → 插件管理 → 可选插件中过滤Allure,勾选对应插件安装 2、安装完插件后,继续在jenkins-> Global Tool Configuration中安装Allure Commandline,
阅读全文
摘要:本地pytest+allure报告 安装python依赖库 pip install pytest==4.0.2 指定版本,装4.4.1执行用例报错 "pytest pluggy.manager.PluginValidationError: unknown hook 'pytest_namespace
阅读全文
摘要:# 去掉readonlypag = self.driver.find_element_by_xpath('//*[@id="app"]/div/div[2]/section/div/form/div[1]/div/div/div/input')self.driver.execute_script("
阅读全文
摘要:参考: https://blog.csdn.net/amric1212/article/details/85103989 https://blog.csdn.net/qq_36051316/article/details/83472659 https://blog.csdn.net/lilongsy
阅读全文
摘要:背景: 近期在写ui自动化用例时,遇到问题,元素定位不了。初步尝试直接在页面中获取svg中包含元素的xpath,直接利用selenium方法访问,无法捕获到相关元素信息。 解决: svgelementXpath = "//div[12]/*[name()='svg']/*[name()='g']/*
阅读全文

浙公网安备 33010602011771号