0% found this document useful (0 votes)
19 views2 pages

Playwright Locators

The document outlines a home assignment focused on using Playwright for web element interaction through various locator strategies. It includes detailed steps for creating and editing leads in a CRM application, as well as creating a new account in Salesforce. The expected outcome is to gain proficiency in selecting and validating web page elements using Playwright locators.

Uploaded by

ktselvan4029
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views2 pages

Playwright Locators

The document outlines a home assignment focused on using Playwright for web element interaction through various locator strategies. It includes detailed steps for creating and editing leads in a CRM application, as well as creating a new account in Salesforce. The expected outcome is to gain proficiency in selecting and validating web page elements using Playwright locators.

Uploaded by

ktselvan4029
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Home Assignment <1> Locators

Learning Objective:
Understand how to efficiently select and interact with elements on a web page using different
locator strategies (Playwright getBys, CSS, XPath)

Assignment Details:
Create a test script that navigates to a CRM application, logs in, finds a specific lead by name or
ID, edits details of the lead (such as name, email, or status), and verifies that the changes have
been successfully saved.

Precondition:
- Use a fixture to setup and teardown

Test Steps:

Assignment: 1 Create a Lead


1. Navigate to the url http://leaftaps.com/opentaps/control/main
2. Enter the username as ‘Demosalesmanager’
3. Enter the password as ‘crmsfa’
4. Click the Login button
5. Click CRM/SFA
6. Click Leads
7. Click Create Lead
8. Fill the Company Name
9. Fill the First Name
10. Fill the Last Name
11. Fill the Salutation
12. Fill the Title
13. Fill the Annual Revenue
14. Fill the Department
15. Fill the Phone number
16. Click Create Lead button
17. Verify the company name, first name, last name and the status
18. Get the page title
Assignment: 2 Edit a Lead
1. Navigate to the url http://leaftaps.com/opentaps/control/main
2. Enter the username as ‘Demosalesmanager’
3. Enter the password as ‘crmsfa’
4. Click the Login button
5. Click CRM/SFA
6. Click Leads
7. Click Find Leads
8. Enter the first name
9. Click Find Leads button
10. Click the first resulting Lead ID
11. Click Edit
12. Edit Company name
13. Edit Annual Revenue
14. Edit Department
15. Enter Description
16. Click Update
17. Verify the edited fields and print the title of the page

Assignment: 3 Create a new Account


1. Navigate to the url https://login.salesforce.com/
2. Enter username using getByLabel
3. Enter password using getByLabel
4. Click Login
5. Verify the title and url of the page using appropriate assertions
6. Click App Launcher using the class locator
7. Click View All using getByText
8. Enter ‘Service’ in the App Launcher Search box using getByPlaceHolder
9. Click Service using index based XPath
10. Click Accounts using attribute based CSS selector
11. Click New using getByRole
12. Enter Account name using attribute based CSS selector
13. Click Save button using XPath
14. Verify the toast message displayed

Expected Outcome:
Understand the use of Playwright locators to find web elements to validate web page content.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy