Built something? We create video reels & spotlights for GitHub projects.Promote your project →
Catalog / himanshu03 / test01
Public GitHub Catalog Discovered Sep 28, 2026

himanshu03 / test01

import java.io.IOException; import java.util.concurrent.TimeUnit; import org.junit.Ignore; import org.junit.Test; import org.openqa.selenium.Alert; import org.openqa.selenium.By; import org.openqa.selenium.WebDriver; import org.openqa.selenium.htmlunit.HtmlUnitDriver; public class login { @Test public void login1() throws InterruptedException { WebDriver driver = new HtmlUnitDriver(); driver.manage().timeouts().implicitlyWait(30L, TimeUnit.SECONDS); driver.get("https://ignite.where2stageit.com/login.html"); driver.findElement(By.xpath("//*[@id='loginid']")).sendKeys("qa_tester"); driver.findElement(By.xpath("//*[@id='password']")).sendKeys("Where2getit!"); Thread.sleep(3000L); driver.findElement(By.xpath("//*[@id='submit']")).click(); driver.close(); } @Ignore @Test public void logout() throws InterruptedException { WebDriver driver = new HtmlUnitDriver(); //driver.manage().window().maximize(); driver.manage().timeouts().implicitlyWait(30L, TimeUnit.SECONDS); driver.get("https://ignite.where2stageit.com"); driver.findElement(By.xpath("//*[@id='loginid']")).sendKeys("qa_tester"); driver.findElement(By.xpath("//*[@id='password']")).sendKeys("Where2getit!"); Thread.sleep(3000L); driver.findElement(By.xpath("//*[@id='submit']")).click(); Thread.sleep(3000L); driver.findElement(By.xpath("//*[@id='logout-button']")).click(); Thread.sleep(5000L); //File scrFile = ((TakesScreenshot)driver).getScreenshotAs(OutputType.FILE); //FileUtils.copyFile(scrFile, new File("E://logout.jpg"),true); driver.close(); } @Ignore @Test public void forgot_password() throws InterruptedException { WebDriver driver = new HtmlUnitDriver(); driver.get("https://ignite.where2stageit.com"); driver.manage().timeouts().implicitlyWait(30L, TimeUnit.SECONDS); driver.findElement(By.xpath("//*[@id='authenticate']/p/a")).click(); Thread.sleep(3000L); String s1 = driver.findElement(By.xpath("//*[@id='authenticate']/div[1]/p[1]")).getText(); System.out.println(s1); driver.findElement(By.xpath("//*[@id='username']")).sendKeys("qa_tester"); driver.findElement(By.xpath("//*[@id='submit']")).click(); Thread.sleep(5000L); String s2 = driver.findElement(By.xpath("//*[@id='authenticate']/div")).getText(); System.out.println(s2); driver.close(); } @Ignore @Test public void forgot_passwordwithAlert() throws InterruptedException { WebDriver driver = new HtmlUnitDriver(); driver.get("https://ignite.where2stageit.com"); driver.manage().timeouts().implicitlyWait(30L, TimeUnit.SECONDS); driver.findElement(By.xpath("//*[@id='authenticate']/p/a")).click(); Thread.sleep(3000L); String s1 = driver.findElement(By.xpath("//*[@id='authenticate']/div[1]/p[1]")).getText(); System.out.println(s1); driver.findElement(By.xpath("//*[@id='username']")).sendKeys(""); Thread.sleep(5000L); driver.findElement(By.xpath("//*[@id='submit']")).click(); Thread.sleep(3000L); Alert alert = driver.switchTo().alert(); alert.getText(); Thread.sleep(3000L); alert.accept(); driver.findElement(By.xpath("//*[@id='username']")).sendKeys("qa_tester"); driver.findElement(By.xpath("//*[@id='submit']")).click(); Thread.sleep(3000L); String s2 = driver.findElement(By.xpath("//*[@id='authenticate']/div")).getText(); System.out.println(s2); driver.close(); } @Ignore @Test public void select_account() throws IOException, InterruptedException { WebDriver driver = new HtmlUnitDriver(); driver.manage().timeouts().implicitlyWait(30L, TimeUnit.SECONDS); //driver.manage().window().maximize(); driver.get("https://ignite.where2stageit.com"); driver.manage().timeouts().implicitlyWait(30L, TimeUnit.SECONDS); driver.findElement(By.xpath("//*[@id='loginid']")).sendKeys("qa_tester"); driver.findElement(By.xpath("//*[@id='password']")).sendKeys("Where2getit!"); Thread.sleep(3000L); driver.findElement(By.xpath("//*[@id='submit']")).click(); Thread.sleep(3000L); driver.findElement(By.xpath("//*[@id='accounts_chzn']/a/span")).sendKeys("chickfila"); Thread.sleep(3000L); driver.findElement(By.xpath("//*[@id='btn-select-account']")).click(); //Thread.sleep(10000L); //File scrFile = ((TakesScreenshot)driver).getScreenshotAs(OutputType.FILE); //FileUtils.copyFile(scrFile, new File("E://account selection.jpg"),true); driver.close(); } }

View repository on GitHub ↗ View creator profile Browse directory

About this discovery

This repository is cataloged as part of our automated global GitHub synchronization. Full telemetry, velocity snapshots, and code summaries are scheduled for continuous enrichment.

#12968367GitHub System ID
himanshu03Organization / User
PublicVisibility
ActiveCatalog Status

More from himanshu03

↗

himanshu03/q

A tool for making and composing asynchronous promises in JavaScript

Discovered
FOR MAINTAINERS

Built something? Put it in front of millions of developers.

We make a short reel about your project and post it across YouTube, Instagram, Threads, and X. Send a link, we do the rest.