<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Big Show</title>
    <description>The latest articles on DEV Community by Big Show (@big_shiw_d828acaaa5932383).</description>
    <link>https://dev.to/big_shiw_d828acaaa5932383</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4055534%2F151f1899-0bcb-42fb-8ec2-978c340a5514.png</url>
      <title>DEV Community: Big Show</title>
      <link>https://dev.to/big_shiw_d828acaaa5932383</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/big_shiw_d828acaaa5932383"/>
    <language>en</language>
    <item>
      <title>Co educator</title>
      <dc:creator>Big Show</dc:creator>
      <pubDate>Wed, 14 Oct 2026 09:54:55 +0000</pubDate>
      <link>https://dev.to/big_shiw_d828acaaa5932383/co-educator-5b8m</link>
      <guid>https://dev.to/big_shiw_d828acaaa5932383/co-educator-5b8m</guid>
      <description>&lt;p&gt;Following selectors are allowed in this scenario:&lt;/p&gt;

&lt;p&gt;id&lt;/p&gt;

&lt;p&gt;name&lt;/p&gt;

&lt;p&gt;xpath (absolute and relative only, dynarnic(axes) xpath is not allowed)&lt;/p&gt;

&lt;p&gt;linkText (partialLink Text is not allowed)&lt;/p&gt;

&lt;p&gt;Scenario:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Use Before Method annotated Setup method named as&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;beforeMethod() to:&lt;/p&gt;

&lt;p&gt;vaasuki.g&lt;/p&gt;

&lt;p&gt;The driver property can be set by using geckodriver as follows:&lt;/p&gt;

&lt;p&gt;System.setProperty('webdriver.gecko.driver', '/home/pg_user/Desktop/geckodriver');&lt;/p&gt;

&lt;p&gt;Launch the application using the url:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://localhost:8080/application/index.html" rel="noopener noreferrer"&gt;http://localhost:8080/application/index.html&lt;/a&gt; (If not loaded, refer the Table1: Common issues and their resolutions)&lt;/p&gt;

&lt;p&gt;Maximize the browser.&lt;/p&gt;

&lt;p&gt;Give an implicit wait of 10 seconds.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;test1() test method:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Click on Add a Member.&lt;/p&gt;

&lt;p&gt;Get the data for each member from Data.xls and enter it in the designated field. After adding each member, write the success message in the "status" column of Data.xls and refresh the page. (Data.xls is present at /home/pg_user/Desktop/Additional Supplied Files)&lt;/p&gt;

&lt;p&gt;Verify whether the Home link is hidden.&lt;/p&gt;

&lt;p&gt;If hidden print "Home link is not available."&lt;/p&gt;

&lt;p&gt;else click on it&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;test2() test method:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Click on Already a Member?&lt;/p&gt;

&lt;p&gt;Login using the below credentials.&lt;/p&gt;

&lt;p&gt;Username: ivs kevin&lt;/p&gt;

&lt;p&gt;Password: illumination&lt;/p&gt;

&lt;p&gt;Verify if "Welcome ivs_kevin" is present in the page by using TestNG Soft Assertions.&lt;/p&gt;

&lt;p&gt;If the role is "Co-Educator", print the course and educator/co-educator on the console from the Session Detail table.&lt;/p&gt;

&lt;p&gt;For the default course which is already selected, Click on Remove Last Course.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;test3() test method:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Click on Already a Member?&lt;/p&gt;

&lt;p&gt;Login using the below credentials.&lt;/p&gt;

&lt;p&gt;Username: ivs kevin&lt;/p&gt;

&lt;p&gt;Password: illumination&lt;/p&gt;

&lt;p&gt;If the total number of entries, including the header, in the Session Detail table is less than or equal to 6:&lt;/p&gt;

&lt;p&gt;Add the course "Agile Testing" and the role "Co-Educator" from the dropdown menu, then click Add Details in the Add Course section.&lt;/p&gt;

&lt;p&gt;else, print "Issue with webtable."&lt;/p&gt;

&lt;p&gt;Print the current url on console.&lt;/p&gt;

&lt;p&gt;Take the screenshot of current page as "Image.PNG" and save it at /home/pg_user/Desktop/Additional SuppliedFiles/Screenshots folder.&lt;/p&gt;

&lt;p&gt;Click on SignOut.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Use After Method annotated tearDown method named as afterMethod() to:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Quit the driver.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Card</title>
      <dc:creator>Big Show</dc:creator>
      <pubDate>Wed, 14 Oct 2026 08:48:09 +0000</pubDate>
      <link>https://dev.to/big_shiw_d828acaaa5932383/card-44ii</link>
      <guid>https://dev.to/big_shiw_d828acaaa5932383/card-44ii</guid>
      <description>&lt;p&gt;import java.io.File;&lt;br&gt;
import java.io.FileInputStream;&lt;br&gt;
import java.io.IOException;&lt;br&gt;
import java.util.Set;&lt;br&gt;
import java.util.List;&lt;/p&gt;

&lt;p&gt;import org.apache.poi.ss.usermodel.*;&lt;br&gt;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;&lt;/p&gt;

&lt;p&gt;import org.openqa.selenium.&lt;em&gt;;&lt;br&gt;
import org.openqa.selenium.firefox.FirefoxDriver;&lt;br&gt;
import org.openqa.selenium.support.ui.Select;&lt;br&gt;
import org.testng.Assert;&lt;br&gt;
import org.testng.annotations.&lt;/em&gt;;&lt;/p&gt;

&lt;p&gt;import org.apache.commons.io.FileUtils;&lt;/p&gt;

&lt;p&gt;public class ApplicationTest {&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;WebDriver driver;

@BeforeClass
public void beforeClass() {
    System.setProperty(
        "webdriver.gecko.driver",
        "/home/pg_user/Desktop/geckodriver"
    );

    driver = new FirefoxDriver();

    driver.get(
        "http://localhost:8080/application/index.html"
    );

    driver.manage().window().maximize();

    driver.manage().timeouts()
          .implicitlyWait(
              java.time.Duration.ofSeconds(12)
          );
}

@Test(priority = 1)
public void test10() {

    driver.findElement(
        By.linkText("Offers")
    ).click();

    WebElement dropdown = driver.findElement(
        By.id("category")
    );

    Select select = new Select(dropdown);

    // Print all dropdown options
    List&amp;lt;WebElement&amp;gt; options = select.getOptions();

    for (WebElement option : options) {
        System.out.println(option.getText());
    }

    // Select Credit Card Offers
    select.selectByVisibleText("Credit Card Offers");

    // Click ICICI View Offer button
    driver.findElement(
        By.xpath(
            "//tr[.//td[contains(normalize-space(), 'ICICI')]]" +
            "//button[contains(., 'View Offer')]"
        )
    ).click();

    // Verify alert message
    Alert alert = driver.switchTo().alert();

    String actualMessage = alert.getText();

    Assert.assertEquals(
        actualMessage,
        "Now get Rs 100 off on your ICICI Bank Credit Card"
    );

    alert.accept();
}

@Test(priority = 2)
public void test20() throws IOException {

    driver.findElement(
        By.linkText("Home")
    ).click();

    // Select Garuda Mall
    driver.findElement(
        By.xpath(
            "//input[@type='radio' and " +
            "following-sibling::text()[contains(.,'Garuda Mall')]]"
        )
    ).click();

    // Read Movies Now web table
    WebElement table = driver.findElement(
        By.xpath(
            "//table[.//th[contains(.,'Top Movies')]]"
        )
    );

    List&amp;lt;WebElement&amp;gt; rows = table.findElements(
        By.xpath(".//tr")
    );

    for (int i = 1; i &amp;lt; rows.size(); i++) {

        List&amp;lt;WebElement&amp;gt; cells = rows.get(i)
                                     .findElements(By.xpath("./th|./td"));

        if (cells.size() &amp;gt;= 2) {
            System.out.println(
                "Top Movie: " + cells.get(0).getText()
                + " | Rating: " + cells.get(1).getText()
            );
        }
    }

    // Select BM Habitat Mall
    driver.findElement(
        By.xpath(
            "//input[@type='radio' and " +
            "following-sibling::text()[contains(.,'BM Habitat Mall')]]"
        )
    ).click();

    // Take screenshot
    File source = ((TakesScreenshot) driver)
                  .getScreenshotAs(OutputType.FILE);

    File destination = new File(
        "/home/pg_user/Desktop/" +
        "AdditionalSuppliedfiles/Screenshots/Image.png"
    );

    FileUtils.copyFile(source, destination);
}

@Test(priority = 3)
public void test30() throws Exception {

    driver.findElement(
        By.linkText("Events")
    ).click();

    // Select Music checkbox
    driver.findElement(
        By.xpath(
            "//input[@type='checkbox' and " +
            "following-sibling::text()[contains(.,'Music')]]"
        )
    ).click();

    // Click radio button adjacent to Sunburn On Air
    driver.findElement(
        By.xpath(
            "//input[@type='radio' and " +
            "following-sibling::text()[contains(.,'Sunburn On Air')]]"
        )
    ).click();

    // Accept alert if present
    try {
        driver.switchTo().alert().accept();
    } catch (NoAlertPresentException e) {
        System.out.println("No alert displayed.");
    }

    // Identify newly opened booking window
    String mainWindow = driver.getWindowHandle();
    String bookingWindow = null;

    Set&amp;lt;String&amp;gt; windows = driver.getWindowHandles();

    for (String window : windows) {
        driver.switchTo().window(window);

        System.out.println(
            "Window URL: " + driver.getCurrentUrl()
        );

        if (driver.getTitle().equals(
                "Book ThyEvent: Booking")) {
            bookingWindow = window;
        }
    }

    if (bookingWindow != null) {
        System.out.println("Desired window found");
        driver.switchTo().window(bookingWindow);
    } else {
        System.out.println("Desired window not found");
        driver.switchTo().window(mainWindow);
        return;
    }

    // Read Excel worksheet: Details
    String excelPath =
        "/home/pg_user/Desktop/" +
        "Additional Supplied Files/Data.xls";

    try (FileInputStream fis =
             new FileInputStream(excelPath);
         Workbook workbook = WorkbookFactory.create(fis)) {

        Sheet sheet = workbook.getSheet("Details");

        DataFormatter formatter = new DataFormatter();

        for (int i = 1; i &amp;lt;= sheet.getLastRowNum(); i++) {

            Row row = sheet.getRow(i);

            if (row == null) {
                continue;
            }

            // Example: map Excel columns to page fields.
            // Replace these locators and column indexes
            // with the actual worksheet and form structure.

            String name = formatter.formatCellValue(
                row.getCell(0)
            );

            String email = formatter.formatCellValue(
                row.getCell(1)
            );

            String tickets = formatter.formatCellValue(
                row.getCell(2)
            );

            driver.findElement(By.id("name"))
                  .clear();
            driver.findElement(By.id("name"))
                  .sendKeys(name);

            driver.findElement(By.id("email"))
                  .clear();
            driver.findElement(By.id("email"))
                  .sendKeys(email);

            driver.findElement(By.id("tickets"))
                  .clear();
            driver.findElement(By.id("tickets"))
                  .sendKeys(tickets);

            driver.findElement(
                By.id("checkValidData")
            ).click();

            driver.findElement(
                By.id("calculateCost")
            ).click();

            try {
                driver.switchTo().alert().accept();
            } catch (NoAlertPresentException e) {
                System.out.println(
                    "No calculation alert displayed."
                );
            }
        }
    }
}

@AfterClass
public void afterClass() {

    if (driver != null) {
        try {
            driver.findElement(
                By.linkText("Home")
            ).click();
        } catch (Exception e) {
            System.out.println(
                "Could not navigate to Home."
            );
        } finally {
            driver.quit();
        }
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Home delivery</title>
      <dc:creator>Big Show</dc:creator>
      <pubDate>Wed, 14 Oct 2026 08:46:21 +0000</pubDate>
      <link>https://dev.to/big_shiw_d828acaaa5932383/home-delivery-48ml</link>
      <guid>https://dev.to/big_shiw_d828acaaa5932383/home-delivery-48ml</guid>
      <description>&lt;p&gt;Launch the application using the url: &lt;a href="http://localhost:8080/application/index.html" rel="noopener noreferrer"&gt;http://localhost:8080/application/index.html&lt;/a&gt; (If not loaded, refer the Table1: Common issues and their resolutions)&lt;/p&gt;

&lt;p&gt;Maximize the browser.&lt;/p&gt;

&lt;p&gt;Give an implicit wait of 6 seconds.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;test1 test method:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Click on "Offices".&lt;/p&gt;

&lt;p&gt;Print how many offices are present in the page in the console.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;test2 test method:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Click on "HomeDelivery".&lt;/p&gt;

&lt;p&gt;Verify if "BuildOrder" button and "Where" dropdown is disabled using TestNG Soft Assertions.&lt;/p&gt;

&lt;p&gt;Select the options from both the dropdowns using the data from Data.xls file. Check if "BuildOrder" button is enabled after selecting each option,&lt;/p&gt;

&lt;p&gt;if enabled, write "Button is enabled"&lt;/p&gt;

&lt;p&gt;else write "Button is disabled" in the "Button status" column. (Datads is present at /home/pg_user/Desktop/Additional Supplied Files)&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;test30 test method:&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Click on "PickUp".&lt;/p&gt;

&lt;p&gt;Select the "Bengaluru" City dropdown and "Koramangala" Where dropdan&lt;/p&gt;

&lt;p&gt;Give "9876543210" as contact number.&lt;/p&gt;

&lt;p&gt;Click on "Coffee" Radio button.&lt;/p&gt;

&lt;p&gt;Iterate through the web table in the application and check if the below names are present in the Name column:&lt;/p&gt;

&lt;p&gt;Name&lt;/p&gt;

&lt;p&gt;Black Coffee&lt;/p&gt;

&lt;p&gt;Cappuccino&lt;/p&gt;

&lt;p&gt;Espresso&lt;/p&gt;

&lt;p&gt;If yes print "Mentioned coffee is in stock" in the console.&lt;/p&gt;

&lt;p&gt;Select cupSize as "Small" for Black Coffee using id locator.&lt;/p&gt;

&lt;p&gt;Fill Quantity Required as "10" using xpath locator.&lt;/p&gt;

&lt;p&gt;Click on Add to Cart&lt;/p&gt;

&lt;p&gt;Click on "No" in Have a promo code? and click on Place Order.&lt;/p&gt;

&lt;p&gt;Take a screenshot and save it as "Image.PNG" and save it at /home/pg,user/Desktop/AdditionalSuppliedFiles/Screenshots folder.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Use After Method annotated tearDown method named as afterMethod) to&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Quit the driver&lt;/p&gt;

</description>
      <category>automation</category>
      <category>java</category>
      <category>programming</category>
      <category>testing</category>
    </item>
    <item>
      <title>Music2</title>
      <dc:creator>Big Show</dc:creator>
      <pubDate>Tue, 13 Oct 2026 12:41:34 +0000</pubDate>
      <link>https://dev.to/big_shiw_d828acaaa5932383/music2-b88</link>
      <guid>https://dev.to/big_shiw_d828acaaa5932383/music2-b88</guid>
      <description>&lt;p&gt;public class Submit {&lt;br&gt;
WebDriver driver=null;&lt;br&gt;
@Before&lt;br&gt;
public void setup() {&lt;br&gt;
System.setProperty("webdriver.gecko.driver", "/home/user/Desktop/geckodriver");&lt;br&gt;
driver new FirefoxDriver();&lt;br&gt;
driver.get("&lt;a href="http://localhost:8080/application/*" rel="noopener noreferrer"&gt;http://localhost:8080/application/*&lt;/a&gt;); driver.manage().window().maximize();&lt;br&gt;
driver.manage().timeouts().implicitlywait(12, TimeUnit.SECONDS);&lt;/p&gt;

&lt;p&gt;&lt;a class="mentioned-user" href="https://dev.to/test"&gt;@test&lt;/a&gt;&lt;br&gt;
public void test() throws IOException {&lt;br&gt;
driver.findElement(By.id("bmhm")).click();&lt;br&gt;
TakesScreenshot src (TakesScreenshot) driver: File srcfile src.getScreenshotAs (OutputType.FILE);&lt;br&gt;
FileUtils.copyFile(srcfile, new File(/home/user/Desktop/user_repo/To_Participant/&lt;br&gt;
driver.findElement(By.id("offersLink")).click();&lt;br&gt;
Select dropdown = new Select(driver.findElement(By.id("offersDropdown"}});&lt;br&gt;
List WebElement&amp;gt; op= dropdown.getOptions();&lt;br&gt;
int size op.size();&lt;br&gt;
for(int i=0; i
System.out.println(options); String options op.get(i).getText();&lt;br&gt;
System.out.pritnln(options)&lt;br&gt;
}&lt;br&gt;
driver.findElement(By.id("eventsLink")).click();&lt;br&gt;
driver.findElement(By.id("ent")).click();&lt;br&gt;
WebElement tableDetails = driver.findElement(By.id("eventsTable']); List
for (WebElement r:rows) ( List WebElement&amp;gt; columns= driver.findElements By.tagName("td")); &lt;/p&gt;

&lt;p&gt;System.out.println("Number of cloumns:columns.size());&lt;br&gt;
}&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;driver.findElement(By.id("book2")).click();&lt;br&gt;
String msg driver.switchTo().alert().getText();&lt;br&gt;
Thread, sleep(1000);&lt;br&gt;
System.out.println(msg);&lt;br&gt;
driver.switchTo().alert().accept();&lt;br&gt;
Set handle driver.getwindowHandles();&lt;br&gt;
for (String s:handle) {&lt;br&gt;
driver.switchTo().window(s);&lt;br&gt;
String url= driver.getCurrentUrl(); System.out.println(driver.getCurrenturl());&lt;br&gt;
}&lt;br&gt;
String title driver.getTitle();&lt;br&gt;
System.out.println("pageTitle:+title);&lt;br&gt;
String path=/home/user/Desktop/user_repo/To_Participant/Additional Supplieds/Book;&lt;br&gt;
FileInputStream fis= new FileInputStream(path);&lt;/p&gt;

&lt;p&gt;XSSFWorkbook wb new XSSFWorkbook(); XSSFSheet stwb.getSheet("Sheet1");&lt;/p&gt;

&lt;p&gt;int ir st.getLastRowNum()-st.getFirstRowNum() for(int i=1; i&amp;lt;lr; i++) { Thread.sleep(1000);&lt;/p&gt;

&lt;p&gt;String contact st.getRow(i).getCell(0).getStringCellvalue(); driver.findElement(By.id("phone")).sendKeys(contact); Thread.sleep(1000);&lt;/p&gt;

&lt;p&gt;String email st.getRow(1).getCell(1).getStringCellValue(); driver.findElement(By.id("email")).sendKeys(email); Thread.sleep(1000);&lt;/p&gt;

&lt;p&gt;String ticket st.getRow(i).getCell(2).getStringellvalue(); driver.findElement(By.id("ticket")).sendKeys (ticket); Thread.sleep(1000);&lt;/p&gt;

&lt;p&gt;driver.findElement(By.id("checkValid")).click(); driver.findElement(By.id("calculateFare")).click();&lt;br&gt;
String msgl driver.switchTo().alert().getText();&lt;/p&gt;

&lt;p&gt;Thread.sleep(1000); System.out.println(msgl);&lt;/p&gt;

&lt;p&gt;driver.switchTo().alert().accept();&lt;/p&gt;

&lt;p&gt;&lt;a class="mentioned-user" href="https://dev.to/after"&gt;@after&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;public void tearDown() {&lt;/p&gt;

&lt;p&gt;driver.close();&lt;br&gt;
}&lt;br&gt;
}&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Music</title>
      <dc:creator>Big Show</dc:creator>
      <pubDate>Tue, 13 Oct 2026 09:08:53 +0000</pubDate>
      <link>https://dev.to/big_shiw_d828acaaa5932383/music-24no</link>
      <guid>https://dev.to/big_shiw_d828acaaa5932383/music-24no</guid>
      <description>&lt;p&gt;MUSIC&lt;/p&gt;

&lt;p&gt;import org.openqa.selenium.Alert;&lt;br&gt;
import org.openqa.selenium.By;&lt;br&gt;
import org.openqa.selenium.WebDriver;&lt;br&gt;
import org.openqa.selenium.WebElement;&lt;br&gt;
import org.openqa.selenium.firefox.FirefoxDriver;&lt;br&gt;
import org.openqa.selenium.support.ui.Select;&lt;br&gt;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;&lt;br&gt;
import org.apache.poi.ss.usermodel.DataFormatter;&lt;br&gt;
import org.apache.poi.ss.usermodel.Row;&lt;br&gt;
import org.apache.poi.ss.usermodel.Sheet;&lt;br&gt;
import org.apache.poi.ss.usermodel.Workbook;&lt;/p&gt;

&lt;p&gt;import org.testng.Assert; // Using TestNG's Assert&lt;br&gt;
import org.testng.annotations.AfterTest;&lt;br&gt;
import org.testng.annotations.BeforeTest;&lt;br&gt;
import org.testng.annotations.Test;&lt;/p&gt;

&lt;p&gt;import java.io.FileInputStream;&lt;br&gt;
import java.io.IOException;&lt;br&gt;
import java.time.Duration;&lt;br&gt;
import java.util.HashMap;&lt;br&gt;
import java.util.List;&lt;br&gt;
import java.util.Map;&lt;br&gt;
import java.util.Set;&lt;/p&gt;

&lt;p&gt;public class AutomationScenarioTest {&lt;/p&gt;

&lt;p&gt;private WebDriver driver;&lt;br&gt;
  private String originalWindowHandle;&lt;/p&gt;

&lt;p&gt;/**&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Helper method to read data from the .xls file&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Assumes data is in the first sheet, on the second row (index 1)&lt;br&gt;
*/&lt;br&gt;
private static Map readExcelData(String filePath) throws IOException {&lt;br&gt;
Map data = new HashMap&amp;lt;&amp;gt;();&lt;br&gt;
FileInputStream fis = new FileInputStream(filePath);&lt;/p&gt;

&lt;p&gt;// Use HSSFWorkbook for .xls files&lt;br&gt;
Workbook workbook = new HSSFWorkbook(fis);&lt;br&gt;
Sheet sheet = workbook.getSheetAt(0); // Assuming first sheet&lt;/p&gt;

&lt;p&gt;// DataFormatter handles different cell types&lt;br&gt;
DataFormatter formatter = new DataFormatter();&lt;/p&gt;

&lt;p&gt;// Assuming headers are in Row 0 and data is in Row 1&lt;br&gt;
Row dataRow = sheet.getRow(1);&lt;/p&gt;

&lt;p&gt;// Assuming Column 0 = Contact, Column 1 = Email, Column 2 = Tickets&lt;br&gt;
String contact = formatter.formatCellValue(dataRow.getCell(0));&lt;br&gt;
String email = formatter.formatCellValue(dataRow.getCell(1));&lt;br&gt;
String tickets = formatter.formatCellValue(dataRow.getCell(2));&lt;/p&gt;

&lt;p&gt;data.put("contact", contact);&lt;br&gt;
data.put("email", email);&lt;br&gt;
data.put("tickets", tickets);&lt;/p&gt;

&lt;p&gt;workbook.close();&lt;br&gt;
fis.close();&lt;/p&gt;

&lt;p&gt;return data;&lt;br&gt;
}&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;@BeforeTest&lt;br&gt;
  public void setup() {&lt;br&gt;
    // --- Step 1: Use appropriate Setup method to: ---&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// Set the driver property
System.setProperty("webdriver.gecko.driver", "/home/user/Desktop/geckodriver");

// Initialize Firefox driver
driver = new FirefoxDriver();

// Set an implicit wait of 12 seconds
driver.manage().timeouts().implicitlyWait(Duration.ofSeconds(12));

// Open the application using url
driver.get("http://localhost:8080/application/");

// Maximize the browser
driver.manage().window().maximize();

// Store the original window handle for later use
originalWindowHandle = driver.getWindowHandle();
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;&lt;a class="mentioned-user" href="https://dev.to/test"&gt;@test&lt;/a&gt;&lt;br&gt;
  public void executeAutomationScenario() throws Exception {&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// --- Step 2: Click on Events link. ---
// *ASSUMED LOCATOR*
driver.findElement(By.linkText("Events")).click();

// --- Step 3: Select Music check box. ---
// *ASSUMED LOCATOR*
WebElement musicCheckbox = driver.findElement(By.id("musicCheckbox")); // e.g., //input[@value='Music']
musicCheckbox.click();

// --- Step 4: Using webtable iteration... print all the contents of Events Table ---
System.out.println("\n--- Events Table Contents ---");
// *ASSUMED LOCATOR*
WebElement eventsTable = driver.findElement(By.id("eventsTable")); // e.g., //table[@name='events']

// Print Headers (th)
List&amp;lt;WebElement&amp;gt; headers = eventsTable.findElements(By.tagName("th"));
for (WebElement header : headers) {
  System.out.print(header.getText() + "\t\t");
}
System.out.println("\n---------------------------------");

// Print Rows (tr)
List&amp;lt;WebElement&amp;gt; rows = eventsTable.findElements(By.tagName("tr"));
for (WebElement row : rows) {
  List&amp;lt;WebElement&amp;gt; cells = row.findElements(By.tagName("td"));
  for (WebElement cell : cells) {
    System.out.print(cell.getText() + "\t\t");
  }
  if (!cells.isEmpty()) {
    System.out.println();
  }
}
System.out.println("--- End of Table ---");

// --- Step 5: Deselect the Music check box. ---
musicCheckbox.click();

// --- Step 6: Select the Adventure checkbox and select radio button against to Skydiving Celebration. ---
// *ASSUMED LOCATOR*
driver.findElement(By.id("adventureCheckbox")).click(); // e.g., //input[@value='Adventure']

// *ASSUMED LOCATOR (XPath)*
WebElement skydivingRadio = driver.findElement(By.xpath("//tr[contains(., 'Skydiving Celebration')]//input[@type='radio']"));
skydivingRadio.click();

// --- Step 7: Accept the alert box. ---
System.out.println("Accepting alert from step 6...");
Alert alert1 = driver.switchTo().alert();
alert1.accept();

// --- Step 8: ...print the URLs of each window and switch to the new tab... ---
Thread.sleep(2000); // Wait for new window

Set&amp;lt;String&amp;gt; allWindowHandles = driver.getWindowHandles();
String newWindowHandle = null;

System.out.println("Printing all window URLs:");
for (String handle : allWindowHandles) {
  driver.switchTo().window(handle);
  System.out.println("Window URL: " + driver.getCurrentUrl());
  if (!handle.equals(originalWindowHandle)) {
    newWindowHandle = handle; // Found the new window
  }
}

// Switch to the new window to work on it
Assert.assertNotNull(newWindowHandle, "New window was not found!");
driver.switchTo().window(newWindowHandle);
System.out.println("Switched to new window.");

// --- Step 9: Fetch the title of the newly opened window... ---
String newTitle = driver.getTitle();
System.out.println("New window title is: " + newTitle);
if (newTitle.equals("BookThyEvent: Booking")) {
  System.out.println("Desired window found");
} else {
  System.out.println("Desired window not found");
}
// TestNG assertion
Assert.assertEquals(newTitle, "BookThyEvent: Booking", "Window title mismatch!");


// --- Step 10: Parameterize the fields... ---
String excelFilePath = "/home/user/Desktop/user_repo/To_Participant/AdditionalSuppliedFiles/Data.xls";
Map&amp;lt;String, String&amp;gt; testData = readExcelData(excelFilePath);

// Fill the form
// *ASSUMED LOCATORS*
driver.findElement(By.id("contactNumber")).sendKeys(testData.get("contact"));
driver.findElement(By.id("emailId")).sendKeys(testData.get("email"));
driver.findElement(By.id("numTickets")).sendKeys(testData.get("tickets"));

// Click on "Check Valid data" and "Calculate cost" buttons
// *ASSUMED LOCATORS*
driver.findElement(By.id("checkValidDataButton")).click();
driver.findElement(By.id("calculateCostButton")).click();

// Accept the alert
System.out.println("Accepting alert from step 10...");
Alert alert2 = driver.switchTo().alert();
alert2.accept();

// --- Step 11: Switch back to the default window... ---
driver.close(); // Close the current (new) window
driver.switchTo().window(originalWindowHandle); // Switch back to the original
System.out.println("Switched back to original window.");

// --- Step 12: Click on Offers link. ---
// *ASSUMED LOCATOR*
driver.findElement(By.linkText("Offers")).click();

// --- Step 13: Select Debit Card offers option from 'Select Category' drop down. ---
// *ASSUMED LOCATOR*
WebElement categoryDropdown = driver.findElement(By.id("selectCategory"));
Select select = new Select(categoryDropdown);
select.selectByVisibleText("Debit Card offers");

// --- Step 14: Click on View Offer button corresponding to "AXIS" Bank. ---
// *ASSUMED LOCATOR (XPath)*
WebElement viewOfferButton = driver.findElement(By.xpath("//td[text()='AXIS Bank']/following-sibling::td/button[text()='View Offer']"));
viewOfferButton.click();

// --- Step 15: Print the alert message in the console and accept the alert. ---
System.out.println("Handling final alert...");
Alert alert3 = driver.switchTo().alert();
String alertMsg = alert3.getText();
System.out.println("Final Alert Message: " + alertMsg);
alert3.accept();

System.out.println("\n--- Scenario Completed Successfully ---");
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;@AfterTest&lt;br&gt;
  public void tearDown() {&lt;br&gt;
    // Ensure the browser is closed even if the script fails&lt;br&gt;
    if (driver != null) {&lt;br&gt;
      driver.quit();&lt;br&gt;
    }&lt;br&gt;
  }&lt;br&gt;
}&lt;/p&gt;

</description>
      <category>automation</category>
      <category>java</category>
      <category>programming</category>
      <category>testing</category>
    </item>
    <item>
      <title>Potato,tomato,onion</title>
      <dc:creator>Big Show</dc:creator>
      <pubDate>Tue, 13 Oct 2026 09:07:08 +0000</pubDate>
      <link>https://dev.to/big_shiw_d828acaaa5932383/potatotomatoonion-3o4i</link>
      <guid>https://dev.to/big_shiw_d828acaaa5932383/potatotomatoonion-3o4i</guid>
      <description>&lt;p&gt;6- IVS SELENIUM ADVANCED&lt;/p&gt;

&lt;p&gt;Potato, Tomato, Onion&lt;/p&gt;

&lt;p&gt;package day1;&lt;br&gt;
import java.io.FileInputStream;&lt;br&gt;
import java.io.FileOutputStream;&lt;br&gt;
import java.io.IOException;&lt;br&gt;
import java.util.List;&lt;br&gt;
import java.util.concurrent.TimeUnit;&lt;br&gt;
import org.apache.poi.hssf.usermodel.HSSFCell;&lt;br&gt;
import org.apache.poi.hssf.usermodel.HSSFRow;&lt;br&gt;
import org.apache.poi.hssf.usermodel.HSSFSheet;&lt;br&gt;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;&lt;br&gt;
import org.openqa.selenium.By;&lt;br&gt;
import org.openqa.selenium.WebDriver;&lt;br&gt;
import org.openqa.selenium.WebElement;&lt;br&gt;
import org.openqa.selenium.firefox.FirefoxDriver;&lt;br&gt;
import org.openqa.selenium.support.ui.Select;&lt;br&gt;
import org.testng.annotations.AfterClass;&lt;br&gt;
import org.testng.annotations.BeforeClass;&lt;br&gt;
import org.testng.annotations.DataProvider;&lt;br&gt;
import org.testng.annotations.Test;&lt;/p&gt;

&lt;p&gt;public class mock {&lt;/p&gt;

&lt;p&gt;WebDriver driver;&lt;br&gt;
 @BeforeClass&lt;br&gt;
 public void setup() {&lt;/p&gt;

&lt;p&gt;System.setProperty("webdriver.gecko.driver","/home/user/Desktop/geckodriver");&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    driver=new FirefoxDriver(); 
    driver.get(http://localhost:8080/application/);
    driver.manage().window().maximize();
    driver.manage().timeouts().implicitlyWait(5, TimeUnit.SECONDS);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;br&gt;
@DataProvider(name="data")&lt;br&gt;
public Object[][] getData()&lt;br&gt;
{&lt;br&gt;
Object[][] a=new Object[3][2];&lt;br&gt;
a[0][0] =&lt;a href="mailto:abc@gmail.com"&gt;abc@gmail.com&lt;/a&gt;;&lt;br&gt;
a[0][1]="password1";&lt;br&gt;
a[1][0]=&lt;a href="mailto:xyz@ymail.com"&gt;xyz@ymail.com&lt;/a&gt;;&lt;br&gt;
a[1][1]="password2";&lt;br&gt;
a[2][0]=&lt;a href="mailto:sap@rediff.com"&gt;sap@rediff.com&lt;/a&gt;;&lt;br&gt;
a[2][1]="password3";&lt;br&gt;
return a;&lt;br&gt;
}&lt;br&gt;
&lt;a class="mentioned-user" href="https://dev.to/test"&gt;@test&lt;/a&gt;(dataProvider="data",dependsOnMethods= {"setup"})&lt;br&gt;
public void Test0l (String email, String password) {&lt;br&gt;
driver.findElement(By.id("emailLogin")).sendKeys(email);&lt;br&gt;
        driver.findElement(By.id("passwordLogin")).sendKeys (password);&lt;br&gt;
        driver.findElement(By.id("login")).click();&lt;br&gt;
}&lt;br&gt;
 &lt;a class="mentioned-user" href="https://dev.to/test"&gt;@test&lt;/a&gt; (dependsOnMethods= {"Test01"})&lt;br&gt;
public void Test02() throws IOException {&lt;br&gt;
int num=driver.getWindowHandles().size();&lt;br&gt;
System.out.println("the number of windows:"+num);&lt;br&gt;
String title = driver.getTitle();&lt;br&gt;
        System.out.println(title);&lt;br&gt;
WebElement table=driver.findElement(By.xpath("/html/body/div[1]/div[1]/table"));&lt;br&gt;
List rows=table.findElements(By.tagName("tr"));&lt;br&gt;
for(int i=0;i&amp;lt;=1;i++) {&lt;br&gt;
List  cols=rows.get(i).findElements(By.tagName("td"));&lt;br&gt;
for(int j=0;j&amp;lt;3;j++) {&lt;br&gt;
String value=cols.get(j).getText();&lt;br&gt;
System.out.print(value+"");&lt;br&gt;
}&lt;br&gt;
System.out.println();&lt;br&gt;
}&lt;br&gt;
WebElement c=driver.findElement(By.id("contentDD"));&lt;br&gt;
Select e=new Select(c);&lt;br&gt;
List list=e.getOptions();&lt;br&gt;
int size=list.size();&lt;br&gt;
for(int i=0;i
String option =list.get(i).getText();&lt;br&gt;
         System.out.println(option);&lt;br&gt;
}&lt;br&gt;
        WebElement d=driver.findElement(By.id("quantityDD"));&lt;br&gt;
Select f=new Select(d);&lt;br&gt;
e.selectByVisibleText("Potato");&lt;br&gt;
f.selectByVisibleText("2" );&lt;br&gt;
driver.findElement(By.id("addItem")).click();&lt;br&gt;
 e.selectByVisibleText("Tomato");&lt;br&gt;
f.selectByVisibleText("2");&lt;br&gt;
 driver.findElement(By.id("addItem")).click();&lt;br&gt;
e.selectByVisibleText("Onion");&lt;br&gt;
f.selectByVisibleText("2");&lt;br&gt;
driver.findElement(By.id("addItem")).click();&lt;br&gt;
e.selectByVisibleText("Beans");&lt;br&gt;
f.selectByVisibleText("2");&lt;br&gt;
driver.findElement(By.id("addItem")).click();&lt;br&gt;
FileInputStream file=new FileInputStream("/home/user/Desktop/user_repo/To_Participant/Additional Supplied File ");&lt;br&gt;
XSSFWorkbook book = new HSSFWorkbook (file);&lt;br&gt;
XSSFSheet sheet=book.getSheet("Sheet1");&lt;br&gt;
WebElement table1=driver.findElement(By.id("myCart"));&lt;br&gt;
List  row=table1.findElements (By.tagName ("tr"));&lt;br&gt;
for(int g=1;g&amp;lt;=4;g++) {&lt;br&gt;
XSSFRow e_row=sheet.getRow(g);&lt;br&gt;
List t_cols=row.get(g).findElements(By.tagName("td"));&lt;br&gt;
for(int l=0;l&amp;lt;=2;l++) {&lt;br&gt;
XSSFCell cells=e_row.createCell(l);&lt;br&gt;
String cart=t_cols.get(1).getText();&lt;br&gt;
cells.setCellValue(cart);&lt;br&gt;
}&lt;br&gt;
}&lt;br&gt;
FileOutputStream fos=new FileOutputStream("/home/user/Desktop/user_repo/To Participant/Additional suppliedFil.FILE");&lt;br&gt;
 book.write(fos);&lt;br&gt;
book.close();&lt;br&gt;
driver.findElement(By.id("calculateTotal")).click();&lt;br&gt;
String msg=driver.switchTo().alert().getText();&lt;br&gt;
System.out.println(msg);&lt;br&gt;
driver.switchTo().alert().accept();&lt;br&gt;
}&lt;br&gt;
&lt;a class="mentioned-user" href="https://dev.to/test"&gt;@test&lt;/a&gt;(dependsOnMethods= {"Test02"})&lt;br&gt;
public void Test03() {&lt;br&gt;
driver.findElement(By.linkText("Logout")).click();&lt;br&gt;
}&lt;br&gt;
@AfterClass (dependsOnMethods={"Test03"})&lt;br&gt;
public void teardown() {&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    driver.close();

    driver.quit();

    }

    }
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

</description>
    </item>
    <item>
      <title>Chemical</title>
      <dc:creator>Big Show</dc:creator>
      <pubDate>Tue, 13 Oct 2026 09:06:18 +0000</pubDate>
      <link>https://dev.to/big_shiw_d828acaaa5932383/chemical-4jmf</link>
      <guid>https://dev.to/big_shiw_d828acaaa5932383/chemical-4jmf</guid>
      <description>&lt;p&gt;driver. findElement (By. id ("cname")) • sendkeys (Name); &lt;br&gt;
driver. findElement (By. id ("cno")) . sendkeys (ServiceNo); &lt;br&gt;
driver. findElement (By. id ("caun")) . sendkeys (Quantity);&lt;br&gt;
driver. finde lement (By. id ("addc")). click(); &lt;br&gt;
driver. findElement (By. id ("addmore")) . click();&lt;br&gt;
driver. findElement (By. id("back2")) . click(); &lt;br&gt;
driver. findElement (By. id ("view")). click();&lt;br&gt;
driver. findElement (By. xpath("/html/body")). click();&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;@Afterclass&lt;br&gt;
public void teardown () {&lt;br&gt;
driver. close(); &lt;br&gt;
driver-quit () ;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Co edu</title>
      <dc:creator>Big Show</dc:creator>
      <pubDate>Tue, 13 Oct 2026 09:02:49 +0000</pubDate>
      <link>https://dev.to/big_shiw_d828acaaa5932383/co-edu-iii</link>
      <guid>https://dev.to/big_shiw_d828acaaa5932383/co-edu-iii</guid>
      <description>&lt;p&gt;{&lt;br&gt;
val=msg;&lt;br&gt;
Assert.assertEquals(val, "SignOut");&lt;/p&gt;

&lt;p&gt;break;&lt;/p&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;&lt;a class="mentioned-user" href="https://dev.to/test"&gt;@test&lt;/a&gt;(dataProvider="data")&lt;br&gt;
public void add_course(String co, String rol) {&lt;br&gt;
WebElement course=driver.findElement(By.xpath("//&lt;em&gt;[&lt;a class="mentioned-user" href="https://dev.to/id"&gt;@id&lt;/a&gt;=\"course\"]"));&lt;br&gt;
Select sel=new Select(course);&lt;br&gt;
sel.selectByVisibleText(co);&lt;br&gt;
WebElement role=driver.findElement(By.xpath("//&lt;/em&gt;[&lt;a class="mentioned-user" href="https://dev.to/id"&gt;@id&lt;/a&gt;=\"role\"]"));&lt;br&gt;
Select sel1=new Select(role);&lt;br&gt;
sel1.selectByVisibleText(rol);&lt;br&gt;
driver.findElement(By.xpath("/html/body/div[3]/form/button[1]")).click();&lt;/p&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;@DataProvider&lt;br&gt;
public Object[][] data()&lt;br&gt;
{&lt;br&gt;
Object[][] a=new Object[2][2];&lt;/p&gt;

&lt;p&gt;a[0][0]="Selenium Using Python";&lt;br&gt;
a[0][1]="Educator";&lt;/p&gt;

&lt;p&gt;a[1][0]="Agile Testing";&lt;br&gt;
a[1][1]="Co-Educator";&lt;/p&gt;

&lt;p&gt;return a;&lt;/p&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;@AfterClass&lt;br&gt;
public void teardown()&lt;br&gt;
{&lt;br&gt;
driver.findElement(By.xpath("/html/body/nav/div/div[2]/ul/li/a")).click();&lt;br&gt;
driver.close();&lt;br&gt;
driver.quit();&lt;/p&gt;

&lt;p&gt;}&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;**** For this code we have to convert to testng or write the following code in testng.xml if it is already present in the files ****&lt;/p&gt;

&lt;p&gt;&amp;lt;?xml version="1.0" encoding="UTF-8"?&amp;gt;&lt;br&gt;
&amp;lt;!DOCTYPE suite SYSTEM "&lt;a href="http://testng.org/testng-1.0.dtd%22%3E" rel="noopener noreferrer"&gt;http://testng.org/testng-1.0.dtd"&amp;gt;&lt;/a&gt;&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;/p&gt;



</description>
    </item>
    <item>
      <title>Order veg</title>
      <dc:creator>Big Show</dc:creator>
      <pubDate>Tue, 13 Oct 2026 09:02:00 +0000</pubDate>
      <link>https://dev.to/big_shiw_d828acaaa5932383/order-veg-220b</link>
      <guid>https://dev.to/big_shiw_d828acaaa5932383/order-veg-220b</guid>
      <description>&lt;p&gt;}&lt;br&gt;
Thread.sleep(1000);&lt;/p&gt;

&lt;p&gt;driver.findElement(By.xpath("XpathExpression"));&lt;br&gt;
  Thread.sleep(1000);&lt;br&gt;
  TakesScreenshot src=(TakesScreenshot) driver;&lt;br&gt;
  File img = src.getScreenshotAs(OutputType.FILE);&lt;br&gt;
  File dest = new File("/home/user/desktop/user_repo.PNG");&lt;br&gt;
  FileUtils.copyFile(img, dest);&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;@BeforeClass&lt;br&gt;
  public void beforeClass() throws InterruptedException {&lt;br&gt;
  System.setProperty("webdriver.gecko.driver", "/home/user/Desktop/geckodriver");&lt;br&gt;
  driver = new FirefoxDriver();&lt;br&gt;
  driver.get(url);&lt;br&gt;
  driver.manage().timeouts().implicitlyWait(12, TimeUnit.SECONDS);&lt;br&gt;
  driver.manage().window().maximize();&lt;br&gt;
  Thread.sleep(5000);&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;@AfterClass&lt;br&gt;
 public void afterClass() {&lt;br&gt;
 driver.close();&lt;br&gt;
}&lt;br&gt;
}&lt;/p&gt;

</description>
    </item>
    <item>
      <title>System using pyr</title>
      <dc:creator>Big Show</dc:creator>
      <pubDate>Tue, 13 Oct 2026 09:01:17 +0000</pubDate>
      <link>https://dev.to/big_shiw_d828acaaa5932383/system-using-pyr-57i3</link>
      <guid>https://dev.to/big_shiw_d828acaaa5932383/system-using-pyr-57i3</guid>
      <description>&lt;p&gt;3-system engineer intro to python&lt;/p&gt;

&lt;p&gt;package day1;&lt;br&gt;
import java.ie.File;&lt;br&gt;
import java.io.FileInputstream;&lt;br&gt;
import java.ie. IOException;&lt;br&gt;
import java.util.List;&lt;br&gt;
import java.util.concurrent.TimeUnit;&lt;br&gt;
import org.apache.commons.ie.Fileutils;&lt;br&gt;
import org.apache.poi.xssf.usermodel.XSSFSheet;&lt;br&gt;
import org.apache.poi. xssf. usermodel.XSSFWorkbook;&lt;br&gt;
import org.openga.selenium.By;&lt;br&gt;
import org.openga.selenium.OutputType;&lt;br&gt;
import org openga selenium. TakesScreenshot;&lt;br&gt;
import org.openga.selenium.WebDriver;&lt;br&gt;
import org.openga.selenium.WebElement;&lt;br&gt;
import org.openga.selenium.support.ui.Select;&lt;br&gt;
import org.testng.annotations.Test;&lt;br&gt;
import org.testng. annotations. AfterCLass; &lt;br&gt;
import org.testng. annotations. Beforelest; &lt;br&gt;
import org.testng.annotations.AfterTest;&lt;br&gt;
import org. testng. annotations. BeforeClass; &lt;br&gt;
import org testng.annotations.Betoresuite:&lt;br&gt;
import org.testng.annotations AfterSuite;&lt;/p&gt;

&lt;p&gt;public class mocksubmit {&lt;br&gt;
WebDriver driver=null;&lt;br&gt;
@BeforeClass&lt;br&gt;
public void setup() {&lt;br&gt;
System setProperty "webdriver. chrome driver", "C"); &lt;br&gt;
driver manage). timeouts).implicitlyWait(10, TimeUnit.SECONDS);&lt;br&gt;
driver .get ("");&lt;br&gt;
driver.manage ().window().maximize();&lt;/p&gt;

&lt;p&gt;&lt;a class="mentioned-user" href="https://dev.to/test"&gt;@test&lt;/a&gt;&lt;br&gt;
public void test() throws IOException{&lt;br&gt;
driver. findElement (By.xpath("//*[&lt;a class="mentioned-user" href="https://dev.to/id"&gt;@id&lt;/a&gt;=\'viewFcourse\']")). click();&lt;br&gt;
System.out.println("Intro to Programming in python"); &lt;br&gt;
driver.switchTo(). alert);&lt;/p&gt;

&lt;p&gt;driver. findElement (By.xpath("//&lt;em&gt;[&lt;a class="mentioned-user" href="https://dev.to/id"&gt;@id&lt;/a&gt;=cIpp\']")) . click();&lt;br&gt;
driver.findElement (By.xpath("//&lt;/em&gt;[id=|&lt;em&gt;indexE\ ]")). click();&lt;br&gt;
List link = driver.findElements (By.tagName('")) ;&lt;br&gt;
System.out.println("The number of Hyperliks are : "+link.size()); &lt;br&gt;
driver. findElement (By.xpath("/html/body/div[2]/div/div[1]/div[2]/label")).click();&lt;br&gt;
driver. findElement (By.xpath("//&lt;/em&gt;[&lt;a class="mentioned-user" href="https://dev.to/id"&gt;@id&lt;/a&gt;=|| btn2\ ]")) . click();&lt;br&gt;
driver.findElement(By. xpath//&lt;em&gt;[&lt;a class="mentioned-user" href="https://dev.to/id"&gt;@id&lt;/a&gt;=\'name\' ]")) . sendkeys ("Jack");&lt;br&gt;
driver. findElement (By. xpath("//&lt;/em&gt;[&lt;a class="mentioned-user" href="https://dev.to/id"&gt;@id&lt;/a&gt;=\ email\ 1")) . sendkeys("&lt;a href="mailto:jack@ivs.com"&gt;jack@ivs.com&lt;/a&gt;");&lt;br&gt;
driver. findElement(By.xpath("//*[&lt;a class="mentioned-user" href="https://dev.to/id"&gt;@id&lt;/a&gt;=|'empRadio|\']")). click();&lt;br&gt;
//&lt;/p&gt;

&lt;p&gt;WebELement company=driver-findElement (By.xpath("//*[&lt;a class="mentioned-user" href="https://dev.to/id"&gt;@id&lt;/a&gt;=cIpp\']"));&lt;br&gt;
Select company1=new Select (company);&lt;br&gt;
company1. selectByVisibleText("Infosys");&lt;/p&gt;

&lt;p&gt;WebElement role=driver.findElement (By.xpath("//")) ;&lt;br&gt;
Select rolel=new Select (role);&lt;br&gt;
rolel. selectByValue("System Engineer"); &lt;br&gt;
driver. findElement (By.xpath("")) . click();&lt;br&gt;
driver. findElement (By.xpath("")) . click();&lt;/p&gt;

&lt;p&gt;FileInputStream fis=new FileInputStream(''");&lt;br&gt;
XSSFWorkbook wb=new XSSFWorkbook (fis);&lt;br&gt;
XSSFSheet sheet =wb.getSheetAt (0) ;&lt;br&gt;
WebElement crdno-driver.findElement (By.xpath("'"));&lt;/p&gt;

&lt;p&gt;crdno.sendkeys (sheet getRow(0) getCell(0). getStringCellValue());&lt;br&gt;
WebElement cvv=driver.findElement(By.xpath(''') (By.xpath'");&lt;br&gt;
cvv.sendkeys (sheet.getRow(0) getCell(1) getStringCellValue())&lt;/p&gt;

&lt;p&gt;WebElement month=driver.findElement (By.xpath(null));&lt;br&gt;
Select mon=new Select (month); &lt;br&gt;
mon.selectByVisibleTextsheet.getRow(0). getCell (2). getStringCellValue());&lt;br&gt;
WebElement year=driver. findElement (By.Xpath(null));&lt;br&gt;
Select yr=new Select (year);&lt;/p&gt;

&lt;p&gt;yr.selectByVisibleText(sheet.getRow(0). getCell(3). getStringCellValue());&lt;br&gt;
wb.close();&lt;/p&gt;

&lt;p&gt;driver findElement (By .xpath("")) . click();&lt;br&gt;
System.out.printin("payment done congratulation jack for getting enrolled in this course. further");&lt;br&gt;
WebElement home-driver.findElement (By.xpath(null));&lt;br&gt;
if (home. isDisplayed()) {&lt;br&gt;
System.out.println("Link for homepage is displayed");&lt;br&gt;
}&lt;br&gt;
else&lt;br&gt;
System.out.println("Link for homepage is not available");&lt;/p&gt;

&lt;p&gt;driver. findElement (By.Xpath("")) . click();&lt;br&gt;
WebElement table= driver.findElement (By.xpath("")) ;&lt;br&gt;
List rows =driver.findElements (By. tagName("tr")) ;&lt;br&gt;
for (WebElement r: rows)&lt;/p&gt;

&lt;p&gt;{&lt;/p&gt;

&lt;p&gt;String row=r.getText();&lt;/p&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;FiteInputStream fisi-new FileInputStream("'');&lt;br&gt;
XSSFWorkbook wb1=new XSSFWorkbook (fisi);&lt;br&gt;
XSSFSheet sheet1 =wb1. getSheetAt (0) ;&lt;/p&gt;

&lt;p&gt;for (int i-0; i&amp;lt;=sheet.getLastRowNum(); i++)&lt;br&gt;
{&lt;/p&gt;

&lt;p&gt;for (int j=1;j&amp;lt;=3;j++)&lt;br&gt;
{&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;driver. findElement (By.xpath("'")). click();&lt;br&gt;
TakesScreenshot ss = (TakesScreenshot) driver;&lt;br&gt;
File srcFile =ss. getScreenshotAs(OutputType.FILE);&lt;/p&gt;

&lt;p&gt;@AfterClass&lt;br&gt;
public void tearDown()&lt;br&gt;
{&lt;br&gt;
driver. close ); &lt;br&gt;
driver.quit();&lt;br&gt;
}&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Mall of mys</title>
      <dc:creator>Big Show</dc:creator>
      <pubDate>Tue, 13 Oct 2026 08:55:05 +0000</pubDate>
      <link>https://dev.to/big_shiw_d828acaaa5932383/mom-30op</link>
      <guid>https://dev.to/big_shiw_d828acaaa5932383/mom-30op</guid>
      <description>&lt;p&gt;1- icici Mall of Mysore&lt;/p&gt;

&lt;p&gt;public class NewTest {&lt;br&gt;
    WebDriver driver;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;@BeforeClass

 public void setup() {

 System.setProperty("webdriver.gecko.driver","/home/user/Desktop/geckodriver");

        driver=new FirefoxDriver(); 
        driver.get("http://localhost:8080/application/");
        driver.manage().window().maximize();
        driver.manage().timeouts().implicitlyWait(12, TimeUnit.SECONDS);

}


@Test
public void test() throws Exception {
  driver.findElement(By.xpath("//*[ @id='mom']")).click();
  WebElement table = driver.findElement(By.xpath("//*[ @id='upComingMovies']"));
  List&amp;lt;WebElement&amp;gt; data = table.findElements(By.tagName("td"));
  System.out.println(data.size());
  for(WebElement d : data) {
    System.out.println(d.getText());
  }

  driver.findElement(By.xpath("//*[ @id='offersDropdown']")).click();

  Select drop1 = new Select(driver.findElement(By.id("offersDropdown")));
  drop1.selectByIndex(1);
  driver.findElement(By.xpath("offersDropdown")).click();

  Alert alert = driver.switchTo().alert();
  System.out.println(alert.getText());
  alert.accept();


  driver.findElement(By.id("eventsLink")).click();
  driver.findElement(By.xpath("//*[ @id='ad']")).click();
  driver.findElement(By.xpath("//*[ @id='book5']")).click();

  driver.switchTo().alert().accept();
  Thread.sleep(2000);

Set&amp;lt;String&amp;gt; tabs = driver.getWindowHandles();
for (String tab : tabs) {
  driver.switchTo().window(tab);
  String url = driver.getCurrentUrl();
  System.out.println(url);
  if (url.endsWith("booking.html")) {
    break;
  }
}

Thread.sleep(2000);
String msg = driver.findElement(By.xpath("/html/body/div/section[1]/table/tbody/tr[5]/"))
          .getText();
System.out.println(msg);

Thread.sleep(3000);

File file = new File("home/user/Desktop/user_repo/To_participant/AdditionalSuppliedFiles/");
FileInputStream fis = new FileInputStream(file);
XSSFWorkbook wb = new XSSFWorkbook(fis);
XSSFSheet st = wb.getSheet("Sheet1");

XSSFWorkbook wb = new XSSFWorkbook(file);
XSSFSheet sheet = wb.getSheet("Sheet1");

XSSFRow row = sheet.getRow(1);
XSSFCell cell = row.getCell(1);
String stringCellValue = cell.getStringCellValue();
System.out.println(stringCellValue);

int lastrownum = st.getLastRowNum();
for (int i = 1; i &amp;lt;= lastrownum; i++) {
  driver.findElement(By.xpath("//*[@id='checkvalidT']")).sendKeys(st.getRow(i).getCell(0).getStringCellValue());
  driver.findElement(By.xpath("//*[@id='checkvalidT']")).sendKeys(st.getRow(i).getCell(1).getStringCellValue());
  driver.findElement(By.id("tickno")).sendKeys(st.getRow(i).getCell(2).getStringCellValue());

  FileOutputStream fos = new FileOutputStream(file);
  driver.findElement(By.xpath("//*[@id='checkvalidT']")).click();
  driver.switchTo().alert().accept();
  driver.switchTo().alert().accept();
}
wb.close();

driver.findElement(By.xpath("//*[@id='checkvalid1']")).sendKeys(getStringCellValue(row).getCell);
driver.findElement(By.id("email")).sendKeys(getStringCellValue(row).getCell);
driver.findElement(By.xpath("//*[@id='note']")).sendKeys(getStringCellValue(row).getCellValue);

FileOutputStream fos = new FileOutputStream(file);
driver.findElement(By.xpath("//*[@id='calculateFare']")).click();
driver.switchTo().alert().accept();

driver.switchTo().alert().accept();
wb.close();
fos.close();
fis.close();

Thread.sleep(2000);

TakeScreenshot ts = (TakeScreenshot)driver;
File file = ts.getScreenshotAs(OutputType.FILE);
FileUtils.copyFile(file, new File("/home/user/Desktop/user_repo/To_participant/AdditionalSuppliedFiles"));


@AfterClass 
public void teardown() {

        //driver.close();

        driver.quit();
}            
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;/p&gt;

</description>
    </item>
    <item>
      <title>MCQ SEL basic</title>
      <dc:creator>Big Show</dc:creator>
      <pubDate>Fri, 09 Oct 2026 05:53:29 +0000</pubDate>
      <link>https://dev.to/big_shiw_d828acaaa5932383/bi-29em</link>
      <guid>https://dev.to/big_shiw_d828acaaa5932383/bi-29em</guid>
      <description>&lt;p&gt;Mcq&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
