Created
November 29, 2019 13:15
-
-
Save sf-shivang/ea701b54fb7fa6e8fa72ddf0d6fdcdb2 to your computer and use it in GitHub Desktop.
Automation python script for notepad testing, used pywinauto library.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pywinauto.application import Application | |
app = Application().start("notepad.exe") | |
app.UntitledNotepad.Edit.type_keys("Hello people, this is sample automation testing python script for testing desktop application ie notepad. If you want to have fun just run this script on your desktop and have goosebumps.", with_spaces =True) | |
app.UntitledNotepad.menu_select("File->SaveAs") | |
app.SaveAs.exit1.set_text("Tst_pywinauto.txt") | |
app.SaveAs.Save.click() | |
app.Tst_pywinauto.close() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment