diff --git a/playwright/features/headerLinks.feature b/playwright/features/headerLinks.feature index ae53277b..e4e2b7fd 100644 --- a/playwright/features/headerLinks.feature +++ b/playwright/features/headerLinks.feature @@ -18,14 +18,20 @@ Feature: Header Links And the "get help header link" should be displayed And the "search header link" should be displayed - Scenario: As a user I navigate to the Digital Research Books home page and verify the account and search header sub-links are displayed + Scenario: As a user I navigate to the Digital Research Books home page and verify the account and search header sub-links and elements are displayed Given I go to the "home" page When I click the Then the should be displayed Examples: - | first header link | second header link | - | "my account header link" | "catalog header link" | - | "my account header link" | "research catalog header link" | - | "my account header link" | "close my account header link" | - | "search header link" | "close search header link" | + | first header link | second header link | + | "my account header link" | "catalog header link" | + | "my account header link" | "research catalog header link" | + | "my account header link" | "close my account header link" | + | "search header link" | "search header label" | + | "search header link" | "search header text field" | + | "search header link" | "search books music movies radio button" | + | "search header link" | "search research catalog radio button" | + | "search header link" | "search library website radio button" | + | "search header link" | "search header button" | + | "search header link" | "close search header link" | diff --git a/playwright/support/mappings.ts b/playwright/support/mappings.ts index 869ddfb8..da87be86 100644 --- a/playwright/support/mappings.ts +++ b/playwright/support/mappings.ts @@ -177,43 +177,32 @@ export const elements = { "back to search results button": "a:text('Back to search results')", /** header locators */ "header logo": "a[aria-label='The New York Public Library']", - "spotlight heading": "a:text('Spotlight')", "my account header link": "[aria-label='My Account']", "catalog header link": "span:text('Go To The Catalog')", "research catalog header link": "span:text('Go To The Research Catalog')", "close my account header link": "[aria-label='Close']", - "my account login form": "#login", "locations header link": "[href='https://www.nypl.org/locations']", - "find your library page heading": "#location-finder__title", "library card header link": "[href='https://www.nypl.org/library-card/new']", - "library card page heading": "h1:text('Apply for a Library Card Online')", "email updates header link": "[href='https://pub.email.nypl.org/subscriptioncenter']", - "email updates page heading": "h1:text('Get the Best of NYPL in Your Inbox')", - "donate header link": - "[href='https://secure.nypl.org/site/Donation2?7825.donation=form1&df_id=7825&mfc_pref=T&s_src=FRQ18ZZ_TNN']", - "donate page heading": - "h1:text('Make Your Tax-Deductible Gift Today') >> nth=0", + "donate header link": "[href='https://www.nypl.org/donate-button']", "shop header link": "[href='https://shop.nypl.org/?utm_campaign=NYPLHeaderButton&utm_source=nypl.org&utm_medium=referral']", - "shop page heading": "[title='The New York Public Library Shop'] >> nth=0", "books music movies header link": "[href='https://www.nypl.org/books-music-movies']", - "books music movies page heading": "h1:text('Books/Music/Movies')", "research header link": "[href='https://www.nypl.org/research'] >> nth=0", - "research page heading": "h1:text('Research')", "education header link": "[href='https://www.nypl.org/education']", - "education page heading": "h1:text('Education')", "events header link": "[href='https://www.nypl.org/events']", - "events page heading": "h1:text('Events')", "connect header link": "[href='https://www.nypl.org/connect']", - "connect page heading": "h1:text('Connect')", "give header link": "[href='https://www.nypl.org/give']", - "give page heading": "h1:text('Give')", "get help header link": "[href='https://www.nypl.org/get-help']", - "get help page heading": "h1:text('Get Help')", "search header link": "#searchButton", "search header label": "#searchInput-label", + "search header text field": "#searchInput", + "search books music movies radio button": "span:text('Search books, music, and movies')", + "search research catalog radio button": "span:text('Search the Research Catalog')", + "search library website radio button": "span:text('Search the library website')", + "search header button": "#search-btn", "close search header link": "[aria-label='Close Search']", /** end header locators */ };