Auto IT
Auto IT
"Auto It is an open source automation language for Windows operating system. It is a BASIC-like
scripting computer language which is designed for automating the Microsoft Windows user
interface. AutoIt uses the combination of simulated keystrokes, mouse movement, and window
manipulation in order to perform user interface testing.”
Description
The scripts which are written using AutoIt can be converted into a compressed and stand-alone
executable which can be run on computers that do not have the AutoIt interpreter installed. AutoIt
also has IDE based on SciTE editor. The compiler and help text are integrated and it provides a
standard environment for developers. AutoIt has the following features which make it more
powerful:
STEP -1
▪
STEP -2
▪
STEP -3
▪
STEP -4
▪
STEP -5
▪
STEP -6
▪
STEP -7
▪
STEP -7
STEP -10
▪
STEP 11
▪
❖ Title = Open
❖
STEP -12
▪
❖ title = “Open”
❖ text = Blank (It is optional)
❖ controlID = Edit1 (Class + Instance)
❖ new text = “C:\Users\shashank.a.bansal\Documents\shashank.txt” (File Path)
STEP -13
❖ title – “Open”
❖ text – Blank (It is Optional)
❖ controlID – Button1 (Class + Instance)
❖ button – No Need (Optional)
❖ title - [CLASS: #32770] (Using Class) or “Open” (Using Title)
❖ text – Blank (It is Optional)
❖ timeout – It is Optional
STEP -14
▪
STEP -15
▪
STEP -16
▪
STEP -17
STEP -18
import java.io.IOException;
import java.util.concurrent.TimeUnit;
import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.chrome.ChromeDriver;
import org.openqa.selenium.firefox.FirefoxDriver;
import org.testng.annotations.Test;
@Test
public static void verifyTest() throws IOException, InterruptedException {
System.setProperty("Webdriver.chrome.driver", "C://chromerdriver.exe");
driver = new ChromeDriver();
driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
driver.get("https://upload.photobox.com/en/#computer");
driver.findElement(By.id("button_desktop")).click();
Runtime.getRuntime().exec("C:\\Users\\shashank.a.bansal\\Documents\\Downloading.exe")
;
Thread.sleep(5000);