wangwt123

2022年6月28日

UI自动化测试-ActionChains类的方法

摘要: ActionChains类的方法 ActionChains主要是针对鼠标事件的处理,在鼠标事件中常用的交互为悬浮,双击,以及右键等操作。如果想使用ActionChains的类,首先需要导入它,导入的命令为: from selenium.webdriver.common.action_chains i 阅读全文

posted @ 2022-06-28 20:01 DOUBLE快乐 阅读(200) 评论(0) 推荐(0)

UI自动化测试-Alert类的方法

摘要: Alert类的方法 1、我们为什么要使用Alert类来定位? 因为,在UI的自动化测试实战中,页面有时会弹出框,这时候我们右击鼠标,并进行检查,我们是无法进行检查这一操作,因而也就无法用我们之前的方法进行定位,这时我们就要使用的是Alert的类这部分。 我们要使用Alert类,首先要导入它,它的命令 阅读全文

posted @ 2022-06-28 19:26 DOUBLE快乐 阅读(161) 评论(0) 推荐(0)

UI自动化测试-Select类的方法

摘要: Select类的方法 在UI的自动化测试实战中,如果遇到下拉框的选择,我们可以使用Select类里面的方法来具体进行定位和解决。如果想使用Select的类,首先需要导入它,导入的命令为: from selenium.webdriver.support.select import Select 方法1 阅读全文

posted @ 2022-06-28 18:47 DOUBLE快乐 阅读(287) 评论(0) 推荐(0)

UI自动化测试-WebElement类的方法

摘要: WebElement类的方法 方法1:clear:清空 1 from selenium import webdriver #包:selenium,模块:webdriver 2 from selenium.webdriver.common.by import By 3 import time as t 阅读全文

posted @ 2022-06-28 17:31 DOUBLE快乐 阅读(81) 评论(0) 推荐(0)

UI自动化测试-WebDriver类的方法

摘要: WebDriver类的方法 方法1:获取当前的网址 方法2:获取当前页面的源代码 方法3:获取当前title 1 from selenium import webdriver #包:selenium,模块:webdriver 2 from selenium.webdriver.common.by i 阅读全文

posted @ 2022-06-28 16:53 DOUBLE快乐 阅读(51) 评论(0) 推荐(0)

导航