pywinauto测试

来源:互联网 发布:python numpy 矩阵 编辑:程序博客网 时间:2024/06/09 15:45

from pywinauto import application
app = application.Application.start("notepad.exe")
import time
time.sleep(2)
app.notepad.TypeKeys("abc")
app.Notepad.MenuSelect(u"文件(&F)->另存为(&A)")
time.sleep(2)
ie = app.window_(title_re = u"另存为")
ie.ComboBox2.TypeKeys('abc')
ie.ComboBox3.Select(1)
ie.ComboBox4.Select(2)
##ie.Button2.Click()

原创粉丝点击