Skip to content
📔 阅读量:

Linux GUI ​

PyLinuxAuto 是专注于 Linux GUI 自动化测试的框架,提供丰富的键鼠控制及多种元素定位方案。

安装 ​

bash
pip3 install "youqu3[gui]"

使用说明 ​

导入 ​

python
from youqu3.gui import pylinuxauto

键鼠控制 ​

python
pylinuxauto.click()
pylinuxauto.double_click()

了解更多...

属性定位 ​

python
pylinuxauto.find_element_by_attr_path("/dde-dock/Btn_文件管理器").click()

了解更多...

图像识别 ​

python
pylinuxauto.find_element_by_image("~/Desktop/test.png").click()

了解更多...

OCR识别 ​

python
pylinuxauto.find_element_by_ocr("中国").click()

了解更多...

相对位移定位 ​

python
pylinuxauto.find_element_by_ui(
    appname="dde-file-manager",
    config_path="~/Desktop/ui.ini",
    btn_name="最大化按钮"
).click()

了解更多...