Your e-Business Quality Partner eValid™ -- Automated Web Quality Solution
Browser-Based, Client-Side, Functional Testing & Validation,
Load & Performance Tuning, Page Timing, Website Analysis,
and Rich Internet Application Monitoring.

eValid -- Testing Notepad -- Simple Example
eValid Home

Summary
This example script demonstrates eValid interacting with Notepad, a Windows desktop utility.

The test plan summary is as follows:

  1. Start on THIS page.
  2. Confirm that this is the correct page by validating THIS SELECTED TEXT.
  3. Open a NOTEPAD.EXE instance with a SystemCall command.
  4. Type a short message into the Notepad window using eValid's desktop mode commands.
  5. Quit the Notepad instance and discard the typed in material.
  6. Note total time with an ElapsedTime command.

Scenario
The example script below was created using a Windows Vista Home Basic SP1 environment and demonstrates eValid interacting with the defaulted "notepad.exe" found.

Sample Script
Here is a sample script that includes typical instances of these commands, plus screenshots of how they appear on the desktop.

# Recording by eValid V9 
# Copyright © 2011 by Software Research, Inc. 
# Recording made on: Microsoft Windows Vista 
# 

ProjectID "Support"
GroupID "Demos"
TestID "notepad"
LogID "AUTO"

ScreenSize 1280 1024
FontSize 0
DeleteCache
DeleteCookies

InitLink "http://www.e-valid.com/Products/Documentation.9/Support/" \
	"Desktop/notepad.html"	
Wait 2000
SyncOnText 0 "THIS SELECTED TEXT" ""

# Open your Notepad application...
SystemCall "NOTEPAD.EXE"


#Breakpoint
Delay 2000 

# # Insert-Recording started.
# Application Mode ON
Wait 2327
# Await matching window title...
DWindowSet 1 "Untitled - Notepad" 154 154 1080 636
Wait 2563
ResetTimer "Start type-in"
KeyText 1 "This is a test"
Wait 1000
KeySys 1 13 0 1
Wait 5203
KeyText 1 "Hello WORLD"
Wait 1000
KeySys 1 13 0 1
Wait 1937
KeySys 1 70 4 1
Wait 4028
KeyText -1 "x"
KeySys -1 9 0 1
Wait 1324
KeySys -1 13 0 1
Wait 517
#WindowClose 1
ElapsedTime "End type-in"
# # Insert-Recording stopped.
# End of script.

Click Here to download the above script so you can try it out in your copy of eValid.

Sample Screenshots
Here are the resulting windows from playback of the above script.

Top Part of This Page
Top Part of This Page

Part to Notepad's Working Area Showing Type-ins Done By Script
Part of Notepad's Working Area Showing Type-ins Done By Script

Screenshot of Top Part of This Page with Green Screen Playback Summary
Screenshot of Top Part of This Page with Green Screen Playback Summary

Notes

  1. The notepad.exe application will normally reside at ..\Windows\System32\.. by default.
  2. If necessary, please re-map any path differences accordingly. Depending on the version of Notepad that you have you may also need to modify the expected window title in the DWindowSet command.
  3. Alternatively, please try the example scripts for MS Word or WordPad if your system doesn't have the above neccessary playback application.

Cautionary Note
Windows desktops vary significantly and there is a chance that the above script may not play back correctly on your desktop. In that case you may need to re-record the script, using the one above as the pattern, to get all of the desktop geometry data correct.