Selenium Tips & Tricks

https://practicetestautomation.com/practice-test-login/ Comparison Differnt Versions of Selenium 1 2 3 4 5 6 7 8 9 10 11 12 // Selenium 2, 3 (Manual driver setup) System.setProperty("webdriver.chrome.driver", "C:\\drivers\\chromedriver.exe"); WebDriver driver = new ChromeDriver(); // Selenium 4.0 – 4.5 (Using external WebDriverManager) import io.github.bonigarcia.wdm.WebDriverManager; WebDriverManager.chromedriver().setup(); WebDriver driver = new ChromeDriver(); // Selenium 4.6+ to 4.38 (Built-in Selenium Manager — current) WebDriver driver = new ChromeDriver(); // No setup needed Best Practices 1 2 3 4 5 6 7 8 9 10 11 12 13 14 // Window management driver.manage().window().maximize(); // Cookies driver.get("https://www.google.com"); driver.manage().addCookie(new Cookie("TestCookie", "12345")); // Timeouts — Best Practice driver.manage().timeouts().implicitlyWait(Duration.ofSeconds(10)); // for element search driver.manage().timeouts().pageLoadTimeout(Duration.ofSeconds(20)); // for full page load driver.manage().timeouts().scriptTimeout(Duration.ofSeconds(10)); // for JS scripts // Example: delete old cookies at start driver.manage().deleteAllCookies(); driver.manage() – Overview Category Common Methods Purpose Window maximize(), minimize(), fullscreen(), setSize(), setPosition() Control browser window Cookies getCookies(), addCookie(), deleteAllCookies() Manage session cookies Timeouts implicitlyWait(), pageLoadTimeout(), scriptTimeout() Control how Selenium waits for operations Timeouts — driver.manage().timeouts() Method Description implicitlyWait(Duration time) Wait for elements to appear pageLoadTimeout(Duration time) Max time to wait for page to load scriptTimeout(Duration time) Max time for asynchronous scripts (JS) Sample Test Case You are a Selenium Java expert. I need to automate a simple task: ...

November 6, 2025 ·  (Updated: February 19, 2026) · 2 min · 217 words · FewSteps
Read More

Create the Login page for hugo website testing

You want a fake login page inside your Hugo site (Papermod theme) so that you can teach QA automation with Java + Selenium using selectors like ID, name, CSS, XPath, etc. The login page should work like this: Page name: test.md Contains a form: username, password, Login button Valid credentials: username: fewsteps password: password If correct → redirect to login-success page If wrong → show an error message on the same page ...

January 29, 2026 ·  (Updated: February 16, 2026) · 4 min · 758 words · FewSteps
Read More

AI Tools & Automation Commands

Current Prompotion: https://www.udemy.com/course/macos-26-tahoe/?couponCode=ED0A273A8F8764C522C5 geneate like 5-10 charaere eaik which will be engilhs name and the domain is @mess-mails.fr.nf. toall 5 email Here are 5 email suggestions with 5–10 character English-style names: LiamFox@mess-mails.fr.nf ok EmmaRay@mess-mails.fr.nf ok NoahLee@mess-mails.fr.nf ok AvaCole@mess-mails.fr.nf ok EliStone@mess-mails.fr.nf ok Full Name Email Address Oliver Harper oliver.harper@binich.com ok Charlotte Bennett charlotte.bennett.mail@binich.com ok William-James Thompson william-james.thompson@binich.com Elizabeth Robinson elizabeth.robinson.workspace@binich.com Nathaniel Anderson nathaniel.anderson.personal.inbox@binich.com Sophia Mitchell sophia.mitchell.contact@binich.com Henry Clark henry.clark.office.mail@binich.com Amelia Harrison amelia.harrison.notes@binich.com George Matthews george.matthews.daily.inbox@binich.com Victoria Evans victoria.evans.communications@binich.com Here is the improved and complete version with your new requirement added: ...

January 29, 2026 ·  (Updated: February 16, 2026) · 1 min · 207 words · FewSteps
Read More