Category: Java

Assert Checkboxes, usage of “blur” and “clear” methods in Playwright Java

In this blog we will be utilizing Playwright Java to assert checkboxes and we will also see the usage of blur() and clear() methods. Topics that we will cover: Assert checkboxes (using assertThat() method) Assert if checkbox is visible Usage of blur() method Usage of clear() method Source code (assert checkboxes) Source code (blur, clear) […]

Verify “Tool Tip”, Set focus to element using Playwright Java

In this blog we will be utilizing Playwright Java to verify title of “tool tip” and we will see how to set focus to a particular element. Topics that we will cover: Assert tool tip Set focus to an element Source code (tool tip) Source code (focus an element) Assert tool tip When a user […]

Verify “Page Title”, “Text Not Present” using Playwright Java

In this blog we will be utilizing Playwright Java to assert “page title” and “text not present on the webpage”. Topics that we will cover: Assert page title (assertTrue method) Assert page title (assertEquals method) Assert page title (If-else loop) Validate that the text is not present on the page Source code (page title) Source […]

Soft Assertion using Playwright Java

In this blog we will be utilizing Playwright Java to implement soft assertion. Topics that we will cover: Soft assertion Source code (soft assertion) Soft assertion A “Soft Assert” is an Assertion type that allows the test case to continue executing even if an assertion fails.  Thus, in the event of a soft assert failure, […]

Verify “Current versus Expected Url”, Verify “Placeholder Text” using Playwright Java

In this blog we will be utilizing Playwright Java to verify “current versus expected url” and verify “placeholder text”. Topics that we will cover: Verify “current versus expected url” Verify “placeholder text“ Source code (current versus expected url) Source code (placeholder text) Verify “current versus expected url” In a test case, we might need to […]

Usage of stream(), has-text() and mouse right click methods using Playwright Java

In this blog we will be utilizing Playwright Java to handle mouse right click and will see the usage of steam() and has-text() methods. Topics that we will cover: Mouse ‘Right click’ operation Usage of stream() and has-text() methods Source code (mouse right click) Source code (stream() , has-text()) Mouse ‘Right click’ operation Go to […]

Handle Calendars and Date picks using Playwright Java

In this blog we will be utilizing Playwright Java to handle calendars and date picks. Topics that we will cover: Select date/month/year on a given website Source code Select date/month/year on a given website Go to https://rahulshettyacademy.com/seleniumPractise/#/offers  Our goal is to automate the selection of ‘Delivery Date’ calendar that is shown above. We will first […]

Handle Checkboxes using Playwright Java

In this blog we will be utilizing Playwright Java to handle checkboxes. Topics that we will cover: “check()” method to select a checkbox “locator() method clubbed with check()” method to select a checkbox Use the “click()” function to pick a checkbox “uncheck()” method to uncheck a checkbox “locator() method clubbed with click()” method to select […]

Handle Radio buttons using Playwright Java

In this blog we will be utilizing Playwright Java to handle radio buttons. Topics that we will cover: “check()” method to select a radio button “locator() method clubbed with check()” method to select a radio button Use the “click()” function to pick a radio button “locator() method clubbed with click()” method to select a radio […]

Allure Report generation using Playwright Java

In this blog we will be utilizing Playwright Java to generate allure reports. Topics that we will cover: Add aspectj version in the properties section of pom.xml Add 3 properties in the properties section of pom.xml Add maven allure testng dependency Add ‘aspectjweaver’ setting in pom.xml Maven install Run any sample testng test Manually install […]