RecreationBench / web /verentia.example /tests /static /content.scripted.spec.ts
VoyagerXHF's picture
Upload folder using huggingface_hub (part 91)
12245e3 verified
Raw History Blame Contribute Delete
287 kB
import { test, expect } from '@playwright/test'; test.describe('Functional - homepage', () => { test('homepage: title matches GT', async ({ page }) => { await page.goto('/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('home'); }); test('homepage: h1 "Verentia University"', async ({ page }) => { await page.goto('/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University'))).toBeTruthy(); }); test('homepage: h2 "“Revelations in the Archive”"', async ({ page }) => { await page.goto('/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '“Revelations in the Archive”' || t.startsWith('“Revelations in the Archive”'))).toBeTruthy(); }); test('homepage: h2 "Impact and Awe"', async ({ page }) => { await page.goto('/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Impact and Awe' || t.startsWith('Impact and Awe'))).toBeTruthy(); }); test('homepage: h2 "University News"', async ({ page }) => { await page.goto('/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'University News' || t.startsWith('University News'))).toBeTruthy(); }); test('homepage: header link "Verentia University"', async ({ page }) => { await page.goto('/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('homepage: nav link "Meet Verentia"', async ({ page }) => { await page.goto('/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('meet-verentia')), 'href fragment present').toBeTruthy(); }); test('homepage: nav link "In Service of Humanity"', async ({ page }) => { await page.goto('/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of Humanity' || t.startsWith('In Service of Humanity')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('service-humanity')), 'href fragment present').toBeTruthy(); }); test('homepage: nav link "Facts & Figures"', async ({ page }) => { await page.goto('/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('facts-figures')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - academics', () => { test('academics: title matches GT', async ({ page }) => { await page.goto('/academics/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('academics'); }); test('academics: h1 "Academics"', async ({ page }) => { await page.goto('/academics/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Academics' || t.startsWith('Academics'))).toBeTruthy(); }); test('academics: h2 "Welcome to a Community of Disc"', async ({ page }) => { await page.goto('/academics/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Welcome to a Community of Discovery' || t.startsWith('Welcome to a Community of Discovery'))).toBeTruthy(); }); test('academics: h2 "Studying at Verentia"', async ({ page }) => { await page.goto('/academics/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia'))).toBeTruthy(); }); test('academics: h2 "Areas of Study"', async ({ page }) => { await page.goto('/academics/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Areas of Study' || t.startsWith('Areas of Study'))).toBeTruthy(); }); test('academics: header link "Verentia University"', async ({ page }) => { await page.goto('/academics/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('academics: nav link "Academics"', async ({ page }) => { await page.goto('/academics/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Academics' || t.startsWith('Academics')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('academics')), 'href fragment present').toBeTruthy(); }); test('academics: nav link "Studying at Verentia"', async ({ page }) => { await page.goto('/academics/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('studying-verentia')), 'href fragment present').toBeTruthy(); }); test('academics: nav link "Library"', async ({ page }) => { await page.goto('/academics/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Library' || t.startsWith('Library')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('library')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - admission_aid', () => { test('admission_aid: title matches GT', async ({ page }) => { await page.goto('/admission-aid/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('admission & aid'); }); test('admission_aid: h1 "Admission & Aid"', async ({ page }) => { await page.goto('/admission-aid/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Admission & Aid' || t.startsWith('Admission & Aid'))).toBeTruthy(); }); test('admission_aid: h2 "Join Us at Verentia"', async ({ page }) => { await page.goto('/admission-aid/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Join Us at Verentia' || t.startsWith('Join Us at Verentia'))).toBeTruthy(); }); test('admission_aid: h2 "Affordable for All"', async ({ page }) => { await page.goto('/admission-aid/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Affordable for All' || t.startsWith('Affordable for All'))).toBeTruthy(); }); test('admission_aid: h2 "Facts & Figures"', async ({ page }) => { await page.goto('/admission-aid/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures'))).toBeTruthy(); }); test('admission_aid: header link "Verentia University"', async ({ page }) => { await page.goto('/admission-aid/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('admission_aid: nav link "Admission & Aid"', async ({ page }) => { await page.goto('/admission-aid/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Admission & Aid' || t.startsWith('Admission & Aid')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('admission-aid')), 'href fragment present').toBeTruthy(); }); test('admission_aid: nav link "Affordable for All"', async ({ page }) => { await page.goto('/admission-aid/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Affordable for All' || t.startsWith('Affordable for All')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('affordable-all')), 'href fragment present').toBeTruthy(); }); test('admission_aid: nav link "Graduate Admission"', async ({ page }) => { await page.goto('/admission-aid/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Graduate Admission' || t.startsWith('Graduate Admission')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('graduate-admission')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - events', () => { test('events: title matches GT', async ({ page }) => { await page.goto('/events/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('events'); }); test('events: h1 "Events at Verentia"', async ({ page }) => { await page.goto('/events/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Events at Verentia' || t.startsWith('Events at Verentia'))).toBeTruthy(); }); test('events: h2 "Event filters"', async ({ page }) => { await page.goto('/events/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Event filters' || t.startsWith('Event filters'))).toBeTruthy(); }); test('events: h2 "Upcoming events"', async ({ page }) => { await page.goto('/events/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Upcoming events' || t.startsWith('Upcoming events'))).toBeTruthy(); }); test('events: h2 "Main navigation"', async ({ page }) => { await page.goto('/events/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('events: header link "Verentia University"', async ({ page }) => { await page.goto('/events/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('events: nav link "Current page 1"', async ({ page }) => { await page.goto('/events/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Current page 1' || t.startsWith('Current page 1')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('events')), 'href fragment present').toBeTruthy(); }); test('events: nav link "Page 2"', async ({ page }) => { await page.goto('/events/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Page 2' || t.startsWith('Page 2')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('events')), 'href fragment present').toBeTruthy(); }); test('events: nav link "Page 3"', async ({ page }) => { await page.goto('/events/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Page 3' || t.startsWith('Page 3')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('events')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - meet_verentia', () => { test('meet_verentia: title matches GT', async ({ page }) => { await page.goto('/meet-verentia/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('meet verentia'); }); test('meet_verentia: h1 "Meet Verentia"', async ({ page }) => { await page.goto('/meet-verentia/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia'))).toBeTruthy(); }); test('meet_verentia: h2 "People Are at the Heart of Ver"', async ({ page }) => { await page.goto('/meet-verentia/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'People Are at the Heart of Verentia' || t.startsWith('People Are at the Heart of Verentia'))).toBeTruthy(); }); test('meet_verentia: h2 "In Service of Humanity"', async ({ page }) => { await page.goto('/meet-verentia/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of Humanity' || t.startsWith('In Service of Humanity'))).toBeTruthy(); }); test('meet_verentia: h2 "Facts & Figures"', async ({ page }) => { await page.goto('/meet-verentia/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures'))).toBeTruthy(); }); test('meet_verentia: header link "Verentia University"', async ({ page }) => { await page.goto('/meet-verentia/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('meet_verentia: nav link "Meet Verentia"', async ({ page }) => { await page.goto('/meet-verentia/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('meet-verentia')), 'href fragment present').toBeTruthy(); }); test('meet_verentia: nav link "In Service of Humanity"', async ({ page }) => { await page.goto('/meet-verentia/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of Humanity' || t.startsWith('In Service of Humanity')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('service-humanity')), 'href fragment present').toBeTruthy(); }); test('meet_verentia: nav link "Facts & Figures"', async ({ page }) => { await page.goto('/meet-verentia/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('facts-figures')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news', () => { test('news: title matches GT', async ({ page }) => { await page.goto('/news/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('all news'); }); test('news: h2 "AI and the humanities: Across "', async ({ page }) => { await page.goto('/news/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'AI and the humanities: Across the Verentia campus, a fresh era of collaboration is now underway.' || t.startsWith('AI and the humanities: Across the Verentia campus, a fresh era of collaboration is now underway.'))).toBeTruthy(); }); test('news: h2 "State Assembly marks its 250th"', async ({ page }) => { await page.goto('/news/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'State Assembly marks its 250th anniversary with a ceremonial session and a \'return home\' to Verentia' || t.startsWith('State Assembly marks its 250th anniversary with a ceremonial session and a \'return home\' to Verentia'))).toBeTruthy(); }); test('news: h2 "All News"', async ({ page }) => { await page.goto('/news/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All News' || t.startsWith('All News'))).toBeTruthy(); }); test('news: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news: header link "Verentia University"', async ({ page }) => { await page.goto('/news/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news: nav link "News"', async ({ page }) => { await page.goto('/news/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news: nav link "All Stories"', async ({ page }) => { await page.goto('/news/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news: nav link "Current page 1"', async ({ page }) => { await page.goto('/news/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Current page 1' || t.startsWith('Current page 1')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2022_02_01_marina_rustow_awarded_medieval_academy_americas_haskins_medal_astonishing_book', () => { test('news_2022_02_01_marina_rustow_awarded_medieval_academy_americas_haskins_medal_astonishing_book: title matches GT', async ({ page }) => { await page.goto('/news/2022/02/01/marina-rustow-awarded-medieval-academy-americas-haskins-medal-astonishing-book/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('selina vartan awarded academy of medieva'); }); test('news_2022_02_01_marina_rustow_awarded_medieval_academy_americas_haskins_medal_astonishing_book: h1 "Selina Vartan awarded Academy "', async ({ page }) => { await page.goto('/news/2022/02/01/marina-rustow-awarded-medieval-academy-americas-haskins-medal-astonishing-book/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Selina Vartan awarded Academy of Medieval Letters’ Alderton Medal for ‘remarkable’ book on Ravenna’s' || t.startsWith('Selina Vartan awarded Academy of Medieval Letters’ Alderton Medal for ‘remarkable’ book on Ravenna’s'))).toBeTruthy(); }); test('news_2022_02_01_marina_rustow_awarded_medieval_academy_americas_haskins_medal_astonishing_book: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2022/02/01/marina-rustow-awarded-medieval-academy-americas-haskins-medal-astonishing-book/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2022_02_01_marina_rustow_awarded_medieval_academy_americas_haskins_medal_astonishing_book: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2022/02/01/marina-rustow-awarded-medieval-academy-americas-haskins-medal-astonishing-book/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2022_02_01_marina_rustow_awarded_medieval_academy_americas_haskins_medal_astonishing_book: h2 "Utility menu"', async ({ page }) => { await page.goto('/news/2022/02/01/marina-rustow-awarded-medieval-academy-americas-haskins-medal-astonishing-book/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Utility menu' || t.startsWith('Utility menu'))).toBeTruthy(); }); test('news_2022_02_01_marina_rustow_awarded_medieval_academy_americas_haskins_medal_astonishing_book: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2022/02/01/marina-rustow-awarded-medieval-academy-americas-haskins-medal-astonishing-book/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2022_02_01_marina_rustow_awarded_medieval_academy_americas_haskins_medal_astonishing_book: nav link "News"', async ({ page }) => { await page.goto('/news/2022/02/01/marina-rustow-awarded-medieval-academy-americas-haskins-medal-astonishing-book/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2022_02_01_marina_rustow_awarded_medieval_academy_americas_haskins_medal_astonishing_book: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2022/02/01/marina-rustow-awarded-medieval-academy-americas-haskins-medal-astonishing-book/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2022_02_01_marina_rustow_awarded_medieval_academy_americas_haskins_medal_astonishing_book: footer link "View All News"', async ({ page }) => { await page.goto('/news/2022/02/01/marina-rustow-awarded-medieval-academy-americas-haskins-medal-astonishing-book/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2025_01_07_princetonians_honored_national_medals_science', () => { test('news_2025_01_07_princetonians_honored_national_medals_science: title matches GT', async ({ page }) => { await page.goto('/news/2025/01/07/princetonians-honored-national-medals-science/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('verentians honored with national medals '); }); test('news_2025_01_07_princetonians_honored_national_medals_science: h1 "Verentians honored with Nation"', async ({ page }) => { await page.goto('/news/2025/01/07/princetonians-honored-national-medals-science/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentians honored with National Medals of Inquiry' || t.startsWith('Verentians honored with National Medals of Inquiry'))).toBeTruthy(); }); test('news_2025_01_07_princetonians_honored_national_medals_science: h2 "Marian L. Kessler"', async ({ page }) => { await page.goto('/news/2025/01/07/princetonians-honored-national-medals-science/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Marian L. Kessler' || t.startsWith('Marian L. Kessler'))).toBeTruthy(); }); test('news_2025_01_07_princetonians_honored_national_medals_science: h2 "Lawrence T. Brandt"', async ({ page }) => { await page.goto('/news/2025/01/07/princetonians-honored-national-medals-science/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lawrence T. Brandt' || t.startsWith('Lawrence T. Brandt'))).toBeTruthy(); }); test('news_2025_01_07_princetonians_honored_national_medals_science: h2 "Helena Marchetti"', async ({ page }) => { await page.goto('/news/2025/01/07/princetonians-honored-national-medals-science/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Helena Marchetti' || t.startsWith('Helena Marchetti'))).toBeTruthy(); }); test('news_2025_01_07_princetonians_honored_national_medals_science: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2025/01/07/princetonians-honored-national-medals-science/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2025_01_07_princetonians_honored_national_medals_science: nav link "News"', async ({ page }) => { await page.goto('/news/2025/01/07/princetonians-honored-national-medals-science/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2025_01_07_princetonians_honored_national_medals_science: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2025/01/07/princetonians-honored-national-medals-science/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2025_01_07_princetonians_honored_national_medals_science: footer link "See All News"', async ({ page }) => { await page.goto('/news/2025/01/07/princetonians-honored-national-medals-science/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'See All News' || t.startsWith('See All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2026_01_05_yibin_kangs_team_identifies_new_path_potential_cancer_treatments', () => { test('news_2026_01_05_yibin_kangs_team_identifies_new_path_potential_cancer_treatments: title matches GT', async ({ page }) => { await page.goto('/news/2026/01/05/yibin-kangs-team-identifies-new-path-potential-cancer-treatments/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('julian roan’s team charts a new route to'); }); test('news_2026_01_05_yibin_kangs_team_identifies_new_path_potential_cancer_treatments: h1 "Julian Roan’s team charts a ne"', async ({ page }) => { await page.goto('/news/2026/01/05/yibin-kangs-team-identifies-new-path-potential-cancer-treatments/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Julian Roan’s team charts a new route to potential cancer treatments' || t.startsWith('Julian Roan’s team charts a new route to potential cancer treatments'))).toBeTruthy(); }); test('news_2026_01_05_yibin_kangs_team_identifies_new_path_potential_cancer_treatments: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2026/01/05/yibin-kangs-team-identifies-new-path-potential-cancer-treatments/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2026_01_05_yibin_kangs_team_identifies_new_path_potential_cancer_treatments: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2026/01/05/yibin-kangs-team-identifies-new-path-potential-cancer-treatments/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2026_01_05_yibin_kangs_team_identifies_new_path_potential_cancer_treatments: h2 "Utility menu"', async ({ page }) => { await page.goto('/news/2026/01/05/yibin-kangs-team-identifies-new-path-potential-cancer-treatments/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Utility menu' || t.startsWith('Utility menu'))).toBeTruthy(); }); test('news_2026_01_05_yibin_kangs_team_identifies_new_path_potential_cancer_treatments: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2026/01/05/yibin-kangs-team-identifies-new-path-potential-cancer-treatments/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2026_01_05_yibin_kangs_team_identifies_new_path_potential_cancer_treatments: nav link "News"', async ({ page }) => { await page.goto('/news/2026/01/05/yibin-kangs-team-identifies-new-path-potential-cancer-treatments/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_01_05_yibin_kangs_team_identifies_new_path_potential_cancer_treatments: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2026/01/05/yibin-kangs-team-identifies-new-path-potential-cancer-treatments/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_01_05_yibin_kangs_team_identifies_new_path_potential_cancer_treatments: footer link "View All News"', async ({ page }) => { await page.goto('/news/2026/01/05/yibin-kangs-team-identifies-new-path-potential-cancer-treatments/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2026_01_09_verentia_paleontologist_yes_tiny_tyrannosaurs_lived_alongside_t_rex', () => { test('news_2026_01_09_verentia_paleontologist_yes_tiny_tyrannosaurs_lived_alongside_t_rex: title matches GT', async ({ page }) => { await page.goto('/news/2026/01/09/verentia-paleontologist-yes-tiny-tyrannosaurs-lived-alongside-t-rex/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('verentia paleontologist'); }); test('news_2026_01_09_verentia_paleontologist_yes_tiny_tyrannosaurs_lived_alongside_t_rex: h1 "Verentia paleontologist: Yes, "', async ({ page }) => { await page.goto('/news/2026/01/09/verentia-paleontologist-yes-tiny-tyrannosaurs-lived-alongside-t-rex/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia paleontologist: Yes, tiny tyrannosaurs lived alongside T. rex' || t.startsWith('Verentia paleontologist: Yes, tiny tyrannosaurs lived alongside T. rex'))).toBeTruthy(); }); test('news_2026_01_09_verentia_paleontologist_yes_tiny_tyrannosaurs_lived_alongside_t_rex: h2 "Growth rings on a dinosaur bon"', async ({ page }) => { await page.goto('/news/2026/01/09/verentia-paleontologist-yes-tiny-tyrannosaurs-lived-alongside-t-rex/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Growth rings on a dinosaur bone' || t.startsWith('Growth rings on a dinosaur bone'))).toBeTruthy(); }); test('news_2026_01_09_verentia_paleontologist_yes_tiny_tyrannosaurs_lived_alongside_t_rex: h2 "Aha … then oof"', async ({ page }) => { await page.goto('/news/2026/01/09/verentia-paleontologist-yes-tiny-tyrannosaurs-lived-alongside-t-rex/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Aha … then oof' || t.startsWith('Aha … then oof'))).toBeTruthy(); }); test('news_2026_01_09_verentia_paleontologist_yes_tiny_tyrannosaurs_lived_alongside_t_rex: h2 "How small did Nanotyrannus get"', async ({ page }) => { await page.goto('/news/2026/01/09/verentia-paleontologist-yes-tiny-tyrannosaurs-lived-alongside-t-rex/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'How small did Nanotyrannus get?' || t.startsWith('How small did Nanotyrannus get?'))).toBeTruthy(); }); test('news_2026_01_09_verentia_paleontologist_yes_tiny_tyrannosaurs_lived_alongside_t_rex: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2026/01/09/verentia-paleontologist-yes-tiny-tyrannosaurs-lived-alongside-t-rex/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2026_01_09_verentia_paleontologist_yes_tiny_tyrannosaurs_lived_alongside_t_rex: nav link "News"', async ({ page }) => { await page.goto('/news/2026/01/09/verentia-paleontologist-yes-tiny-tyrannosaurs-lived-alongside-t-rex/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_01_09_verentia_paleontologist_yes_tiny_tyrannosaurs_lived_alongside_t_rex: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2026/01/09/verentia-paleontologist-yes-tiny-tyrannosaurs-lived-alongside-t-rex/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_01_09_verentia_paleontologist_yes_tiny_tyrannosaurs_lived_alongside_t_rex: footer link "View All News"', async ({ page }) => { await page.goto('/news/2026/01/09/verentia-paleontologist-yes-tiny-tyrannosaurs-lived-alongside-t-rex/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2026_03_30_service_recognition_ceremony_honors_verentia_staff_exceptional_achievements', () => { test('news_2026_03_30_service_recognition_ceremony_honors_verentia_staff_exceptional_achievements: title matches GT', async ({ page }) => { await page.goto('/news/2026/03/30/service-recognition-ceremony-honors-verentia-staff-exceptional-achievements/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('service recognition ceremony honors vere'); }); test('news_2026_03_30_service_recognition_ceremony_honors_verentia_staff_exceptional_achievements: h1 "Service Recognition ceremony h"', async ({ page }) => { await page.goto('/news/2026/03/30/service-recognition-ceremony-honors-verentia-staff-exceptional-achievements/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Service Recognition ceremony honors Verentia staff for exceptional achievements' || t.startsWith('Service Recognition ceremony honors Verentia staff for exceptional achievements'))).toBeTruthy(); }); test('news_2026_03_30_service_recognition_ceremony_honors_verentia_staff_exceptional_achievements: h2 "By the Numbers"', async ({ page }) => { await page.goto('/news/2026/03/30/service-recognition-ceremony-honors-verentia-staff-exceptional-achievements/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'By the Numbers' || t.startsWith('By the Numbers'))).toBeTruthy(); }); test('news_2026_03_30_service_recognition_ceremony_honors_verentia_staff_exceptional_achievements: h2 "President’s Achievement Awards"', async ({ page }) => { await page.goto('/news/2026/03/30/service-recognition-ceremony-honors-verentia-staff-exceptional-achievements/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'President’s Achievement Awards' || t.startsWith('President’s Achievement Awards'))).toBeTruthy(); }); test('news_2026_03_30_service_recognition_ceremony_honors_verentia_staff_exceptional_achievements: h2 "Merrick Management Award"', async ({ page }) => { await page.goto('/news/2026/03/30/service-recognition-ceremony-honors-verentia-staff-exceptional-achievements/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Merrick Management Award' || t.startsWith('Merrick Management Award'))).toBeTruthy(); }); test('news_2026_03_30_service_recognition_ceremony_honors_verentia_staff_exceptional_achievements: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2026/03/30/service-recognition-ceremony-honors-verentia-staff-exceptional-achievements/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2026_03_30_service_recognition_ceremony_honors_verentia_staff_exceptional_achievements: nav link "News"', async ({ page }) => { await page.goto('/news/2026/03/30/service-recognition-ceremony-honors-verentia-staff-exceptional-achievements/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_03_30_service_recognition_ceremony_honors_verentia_staff_exceptional_achievements: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2026/03/30/service-recognition-ceremony-honors-verentia-staff-exceptional-achievements/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_03_30_service_recognition_ceremony_honors_verentia_staff_exceptional_achievements: footer link "View All News"', async ({ page }) => { await page.goto('/news/2026/03/30/service-recognition-ceremony-honors-verentia-staff-exceptional-achievements/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2026_04_02_biomedical_research_verentia_surging', () => { test('news_2026_04_02_biomedical_research_verentia_surging: title matches GT', async ({ page }) => { await page.goto('/news/2026/04/02/biomedical-research-verentia-surging/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('biomedical research is surging at verent'); }); test('news_2026_04_02_biomedical_research_verentia_surging: h1 "Biomedical research is surging"', async ({ page }) => { await page.goto('/news/2026/04/02/biomedical-research-verentia-surging/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Biomedical research is surging at Verentia University' || t.startsWith('Biomedical research is surging at Verentia University'))).toBeTruthy(); }); test('news_2026_04_02_biomedical_research_verentia_surging: h2 "Biomedical wonders in the maki"', async ({ page }) => { await page.goto('/news/2026/04/02/biomedical-research-verentia-surging/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Biomedical wonders in the making' || t.startsWith('Biomedical wonders in the making'))).toBeTruthy(); }); test('news_2026_04_02_biomedical_research_verentia_surging: h2 "Behind the boom: how “great ne"', async ({ page }) => { await page.goto('/news/2026/04/02/biomedical-research-verentia-surging/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Behind the boom: how “great neighbors” fuel great science' || t.startsWith('Behind the boom: how “great neighbors” fuel great science'))).toBeTruthy(); }); test('news_2026_04_02_biomedical_research_verentia_surging: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2026/04/02/biomedical-research-verentia-surging/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2026_04_02_biomedical_research_verentia_surging: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2026/04/02/biomedical-research-verentia-surging/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2026_04_02_biomedical_research_verentia_surging: nav link "News"', async ({ page }) => { await page.goto('/news/2026/04/02/biomedical-research-verentia-surging/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_04_02_biomedical_research_verentia_surging: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2026/04/02/biomedical-research-verentia-surging/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_04_02_biomedical_research_verentia_surging: footer link "View All News"', async ({ page }) => { await page.goto('/news/2026/04/02/biomedical-research-verentia-surging/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2026_04_03_three_minute_thesis_competition_showcases_verentia_graduate_student_research', () => { test('news_2026_04_03_three_minute_thesis_competition_showcases_verentia_graduate_student_research: title matches GT', async ({ page }) => { await page.goto('/news/2026/04/03/three-minute-thesis-competition-showcases-verentia-graduate-student-research/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('research in focus competition showcases '); }); test('news_2026_04_03_three_minute_thesis_competition_showcases_verentia_graduate_student_research: h1 "Research in Focus competition "', async ({ page }) => { await page.goto('/news/2026/04/03/three-minute-thesis-competition-showcases-verentia-graduate-student-research/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Research in Focus competition showcases Verentia graduate student research' || t.startsWith('Research in Focus competition showcases Verentia graduate student research'))).toBeTruthy(); }); test('news_2026_04_03_three_minute_thesis_competition_showcases_verentia_graduate_student_research: h2 "We have a winner"', async ({ page }) => { await page.goto('/news/2026/04/03/three-minute-thesis-competition-showcases-verentia-graduate-student-research/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'We have a winner' || t.startsWith('We have a winner'))).toBeTruthy(); }); test('news_2026_04_03_three_minute_thesis_competition_showcases_verentia_graduate_student_research: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2026/04/03/three-minute-thesis-competition-showcases-verentia-graduate-student-research/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2026_04_03_three_minute_thesis_competition_showcases_verentia_graduate_student_research: h2 "Site navigation"', async ({ page }) => { await page.goto('/news/2026/04/03/three-minute-thesis-competition-showcases-verentia-graduate-student-research/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Site navigation' || t.startsWith('Site navigation'))).toBeTruthy(); }); test('news_2026_04_03_three_minute_thesis_competition_showcases_verentia_graduate_student_research: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2026/04/03/three-minute-thesis-competition-showcases-verentia-graduate-student-research/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2026_04_03_three_minute_thesis_competition_showcases_verentia_graduate_student_research: nav link "News"', async ({ page }) => { await page.goto('/news/2026/04/03/three-minute-thesis-competition-showcases-verentia-graduate-student-research/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_04_03_three_minute_thesis_competition_showcases_verentia_graduate_student_research: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2026/04/03/three-minute-thesis-competition-showcases-verentia-graduate-student-research/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_04_03_three_minute_thesis_competition_showcases_verentia_graduate_student_research: footer link "See All Stories"', async ({ page }) => { await page.goto('/news/2026/04/03/three-minute-thesis-competition-showcases-verentia-graduate-student-research/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'See All Stories' || t.startsWith('See All Stories')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2026_04_13_revolution_archives_students_delve_verentia_university_library_archives_understand', () => { test('news_2026_04_13_revolution_archives_students_delve_verentia_university_library_archives_understand: title matches GT', async ({ page }) => { await page.goto('/news/2026/04/13/revolution-archives-students-delve-verentia-university-library-archives-understand/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('“uprising in the archives”'); }); test('news_2026_04_13_revolution_archives_students_delve_verentia_university_library_archives_understand: h1 "“Uprising in the Archives”: St"', async ({ page }) => { await page.goto('/news/2026/04/13/revolution-archives-students-delve-verentia-university-library-archives-understand/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '“Uprising in the Archives”: Students delve into Verentia University Library archives to understand t' || t.startsWith('“Uprising in the Archives”: Students delve into Verentia University Library archives to understand t'))).toBeTruthy(); }); test('news_2026_04_13_revolution_archives_students_delve_verentia_university_library_archives_understand: h2 "Classwork with an eye toward c"', async ({ page }) => { await page.goto('/news/2026/04/13/revolution-archives-students-delve-verentia-university-library-archives-understand/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Classwork with an eye toward curation' || t.startsWith('Classwork with an eye toward curation'))).toBeTruthy(); }); test('news_2026_04_13_revolution_archives_students_delve_verentia_university_library_archives_understand: h2 "Adding to the archives"', async ({ page }) => { await page.goto('/news/2026/04/13/revolution-archives-students-delve-verentia-university-library-archives-understand/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Adding to the archives' || t.startsWith('Adding to the archives'))).toBeTruthy(); }); test('news_2026_04_13_revolution_archives_students_delve_verentia_university_library_archives_understand: h2 "Building a “national memory”"', async ({ page }) => { await page.goto('/news/2026/04/13/revolution-archives-students-delve-verentia-university-library-archives-understand/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Building a “national memory”' || t.startsWith('Building a “national memory”'))).toBeTruthy(); }); test('news_2026_04_13_revolution_archives_students_delve_verentia_university_library_archives_understand: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2026/04/13/revolution-archives-students-delve-verentia-university-library-archives-understand/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2026_04_13_revolution_archives_students_delve_verentia_university_library_archives_understand: nav link "News"', async ({ page }) => { await page.goto('/news/2026/04/13/revolution-archives-students-delve-verentia-university-library-archives-understand/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_04_13_revolution_archives_students_delve_verentia_university_library_archives_understand: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2026/04/13/revolution-archives-students-delve-verentia-university-library-archives-understand/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_04_13_revolution_archives_students_delve_verentia_university_library_archives_understand: footer link "View All News"', async ({ page }) => { await page.goto('/news/2026/04/13/revolution-archives-students-delve-verentia-university-library-archives-understand/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2026_04_14_fearless_graduate_students_are_forging_new_quantum_frontier', () => { test('news_2026_04_14_fearless_graduate_students_are_forging_new_quantum_frontier: title matches GT', async ({ page }) => { await page.goto('/news/2026/04/14/fearless-graduate-students-are-forging-new-quantum-frontier/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('undaunted graduate scholars are forging '); }); test('news_2026_04_14_fearless_graduate_students_are_forging_new_quantum_frontier: h1 "Undaunted graduate scholars ar"', async ({ page }) => { await page.goto('/news/2026/04/14/fearless-graduate-students-are-forging-new-quantum-frontier/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Undaunted graduate scholars are forging a bold new quantum frontier' || t.startsWith('Undaunted graduate scholars are forging a bold new quantum frontier'))).toBeTruthy(); }); test('news_2026_04_14_fearless_graduate_students_are_forging_new_quantum_frontier: h2 "At the core of Verentia\'s Quan"', async ({ page }) => { await page.goto('/news/2026/04/14/fearless-graduate-students-are-forging-new-quantum-frontier/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'At the core of Verentia\'s Quantum Initiative' || t.startsWith('At the core of Verentia\'s Quantum Initiative'))).toBeTruthy(); }); test('news_2026_04_14_fearless_graduate_students_are_forging_new_quantum_frontier: h2 "Just what is quantum"', async ({ page }) => { await page.goto('/news/2026/04/14/fearless-graduate-students-are-forging-new-quantum-frontier/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Just what is quantum' || t.startsWith('Just what is quantum'))).toBeTruthy(); }); test('news_2026_04_14_fearless_graduate_students_are_forging_new_quantum_frontier: h2 "Building a scientific frontier"', async ({ page }) => { await page.goto('/news/2026/04/14/fearless-graduate-students-are-forging-new-quantum-frontier/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Building a scientific frontier takes nerve' || t.startsWith('Building a scientific frontier takes nerve'))).toBeTruthy(); }); test('news_2026_04_14_fearless_graduate_students_are_forging_new_quantum_frontier: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2026/04/14/fearless-graduate-students-are-forging-new-quantum-frontier/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2026_04_14_fearless_graduate_students_are_forging_new_quantum_frontier: nav link "News"', async ({ page }) => { await page.goto('/news/2026/04/14/fearless-graduate-students-are-forging-new-quantum-frontier/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_04_14_fearless_graduate_students_are_forging_new_quantum_frontier: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2026/04/14/fearless-graduate-students-are-forging-new-quantum-frontier/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_04_14_fearless_graduate_students_are_forging_new_quantum_frontier: footer link "View All News"', async ({ page }) => { await page.goto('/news/2026/04/14/fearless-graduate-students-are-forging-new-quantum-frontier/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2026_04_14_major_gift_promises_accelerate_verentia_universitys_leadership_quantum_science', () => { test('news_2026_04_14_major_gift_promises_accelerate_verentia_universitys_leadership_quantum_science: title matches GT', async ({ page }) => { await page.goto('/news/2026/04/14/major-gift-promises-accelerate-verentia-universitys-leadership-quantum-science/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('major gift promises to accelerate verent'); }); test('news_2026_04_14_major_gift_promises_accelerate_verentia_universitys_leadership_quantum_science: h1 "Major gift promises to acceler"', async ({ page }) => { await page.goto('/news/2026/04/14/major-gift-promises-accelerate-verentia-universitys-leadership-quantum-science/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Major gift promises to accelerate Verentia University’s leadership in quantum science' || t.startsWith('Major gift promises to accelerate Verentia University’s leadership in quantum science'))).toBeTruthy(); }); test('news_2026_04_14_major_gift_promises_accelerate_verentia_universitys_leadership_quantum_science: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2026/04/14/major-gift-promises-accelerate-verentia-universitys-leadership-quantum-science/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2026_04_14_major_gift_promises_accelerate_verentia_universitys_leadership_quantum_science: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2026/04/14/major-gift-promises-accelerate-verentia-universitys-leadership-quantum-science/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2026_04_14_major_gift_promises_accelerate_verentia_universitys_leadership_quantum_science: h2 "Utility menu"', async ({ page }) => { await page.goto('/news/2026/04/14/major-gift-promises-accelerate-verentia-universitys-leadership-quantum-science/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Utility menu' || t.startsWith('Utility menu'))).toBeTruthy(); }); test('news_2026_04_14_major_gift_promises_accelerate_verentia_universitys_leadership_quantum_science: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2026/04/14/major-gift-promises-accelerate-verentia-universitys-leadership-quantum-science/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2026_04_14_major_gift_promises_accelerate_verentia_universitys_leadership_quantum_science: nav link "News"', async ({ page }) => { await page.goto('/news/2026/04/14/major-gift-promises-accelerate-verentia-universitys-leadership-quantum-science/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_04_14_major_gift_promises_accelerate_verentia_universitys_leadership_quantum_science: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2026/04/14/major-gift-promises-accelerate-verentia-universitys-leadership-quantum-science/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_04_14_major_gift_promises_accelerate_verentia_universitys_leadership_quantum_science: footer link "View All News"', async ({ page }) => { await page.goto('/news/2026/04/14/major-gift-promises-accelerate-verentia-universitys-leadership-quantum-science/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - one_community', () => { test('one_community: title matches GT', async ({ page }) => { await page.goto('/one-community/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('one community'); }); test('one_community: h1 "One Community"', async ({ page }) => { await page.goto('/one-community/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'One Community' || t.startsWith('One Community'))).toBeTruthy(); }); test('one_community: h2 "Falcons of a Feather"', async ({ page }) => { await page.goto('/one-community/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Falcons of a Feather' || t.startsWith('Falcons of a Feather'))).toBeTruthy(); }); test('one_community: h2 "Lifelong Connections"', async ({ page }) => { await page.goto('/one-community/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lifelong Connections' || t.startsWith('Lifelong Connections'))).toBeTruthy(); }); test('one_community: h2 "Student Life"', async ({ page }) => { await page.goto('/one-community/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Student Life' || t.startsWith('Student Life'))).toBeTruthy(); }); test('one_community: header link "Verentia University"', async ({ page }) => { await page.goto('/one-community/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('one_community: nav link "One Community"', async ({ page }) => { await page.goto('/one-community/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'One Community' || t.startsWith('One Community')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('one-community')), 'href fragment present').toBeTruthy(); }); test('one_community: nav link "Lifelong Connections"', async ({ page }) => { await page.goto('/one-community/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lifelong Connections' || t.startsWith('Lifelong Connections')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('lifelong-connections')), 'href fragment present').toBeTruthy(); }); test('one_community: nav link "Student Life"', async ({ page }) => { await page.goto('/one-community/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Student Life' || t.startsWith('Student Life')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('student-life')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - privacy_notice', () => { test('privacy_notice: page loads without error', async ({ page }) => { const response = await page.goto('/privacy-notice/'); expect(response?.status()).toBeLessThan(400); await expect(page.locator('body')).toBeVisible(); }); test('privacy_notice: title matches GT', async ({ page }) => { await page.goto('/privacy-notice/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('verentia university privacy notice'); }); test('privacy_notice: h1 "Verentia University Privacy No"', async ({ page }) => { await page.goto('/privacy-notice/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University Privacy Notice' || t.startsWith('Verentia University Privacy Notice'))).toBeTruthy(); }); test('privacy_notice: h2 "Overview"', async ({ page }) => { await page.goto('/privacy-notice/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Overview' || t.startsWith('Overview'))).toBeTruthy(); }); test('privacy_notice: h2 "Links to Other Sites"', async ({ page }) => { await page.goto('/privacy-notice/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Links to Other Sites' || t.startsWith('Links to Other Sites'))).toBeTruthy(); }); test('privacy_notice: h2 "Collection of Personal Informa"', async ({ page }) => { await page.goto('/privacy-notice/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Collection of Personal Information' || t.startsWith('Collection of Personal Information'))).toBeTruthy(); }); test('privacy_notice: header link "Verentia University"', async ({ page }) => { await page.goto('/privacy-notice/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('privacy_notice: nav link "Meet Verentia"', async ({ page }) => { await page.goto('/privacy-notice/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('meet-verentia')), 'href fragment present').toBeTruthy(); }); test('privacy_notice: nav link "In Service of Humanity"', async ({ page }) => { await page.goto('/privacy-notice/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of Humanity' || t.startsWith('In Service of Humanity')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('service-humanity')), 'href fragment present').toBeTruthy(); }); test('privacy_notice: nav link "Facts & Figures"', async ({ page }) => { await page.goto('/privacy-notice/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('facts-figures')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - research', () => { test('research: title matches GT', async ({ page }) => { await page.goto('/research/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('research'); }); test('research: h1 "Research"', async ({ page }) => { await page.goto('/research/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Research' || t.startsWith('Research'))).toBeTruthy(); }); test('research: h2 "Advancing Ideas, Advancing Soc"', async ({ page }) => { await page.goto('/research/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Advancing Ideas, Advancing Society' || t.startsWith('Advancing Ideas, Advancing Society'))).toBeTruthy(); }); test('research: h2 "Research Areas"', async ({ page }) => { await page.goto('/research/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Research Areas' || t.startsWith('Research Areas'))).toBeTruthy(); }); test('research: h2 "Facilities and Labs"', async ({ page }) => { await page.goto('/research/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facilities and Labs' || t.startsWith('Facilities and Labs'))).toBeTruthy(); }); test('research: header link "Verentia University"', async ({ page }) => { await page.goto('/research/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('research: nav link "Research"', async ({ page }) => { await page.goto('/research/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Research' || t.startsWith('Research')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('research')), 'href fragment present').toBeTruthy(); }); test('research: nav link "Engineering & Applied Science"', async ({ page }) => { await page.goto('/research/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Engineering & Applied Science' || t.startsWith('Engineering & Applied Science')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('engineering-and-applied-science')), 'href fragment present').toBeTruthy(); }); test('research: nav link "Humanities"', async ({ page }) => { await page.goto('/research/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Humanities' || t.startsWith('Humanities')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('humanities')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - academics_areas_of_study', () => { test('academics_areas_of_study: title matches GT', async ({ page }) => { await page.goto('/academics/areas-of-study/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('areas of study'); }); test('academics_areas_of_study: h1 "Areas of Study"', async ({ page }) => { await page.goto('/academics/areas-of-study/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Areas of Study' || t.startsWith('Areas of Study'))).toBeTruthy(); }); test('academics_areas_of_study: h2 "Programs"', async ({ page }) => { await page.goto('/academics/areas-of-study/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Programs' || t.startsWith('Programs'))).toBeTruthy(); }); test('academics_areas_of_study: h2 "African American Studies"', async ({ page }) => { await page.goto('/academics/areas-of-study/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'African American Studies' || t.startsWith('African American Studies'))).toBeTruthy(); }); test('academics_areas_of_study: h2 "African Studies"', async ({ page }) => { await page.goto('/academics/areas-of-study/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'African Studies' || t.startsWith('African Studies'))).toBeTruthy(); }); test('academics_areas_of_study: header link "Verentia University"', async ({ page }) => { await page.goto('/academics/areas-of-study/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('academics_areas_of_study: nav link "Academics"', async ({ page }) => { await page.goto('/academics/areas-of-study/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Academics' || t.startsWith('Academics')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('academics')), 'href fragment present').toBeTruthy(); }); test('academics_areas_of_study: nav link "Studying at Verentia"', async ({ page }) => { await page.goto('/academics/areas-of-study/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('studying-verentia')), 'href fragment present').toBeTruthy(); }); test('academics_areas_of_study: nav link "Library"', async ({ page }) => { await page.goto('/academics/areas-of-study/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Library' || t.startsWith('Library')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('library')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - academics_continuing_education', () => { test('academics_continuing_education: title matches GT', async ({ page }) => { await page.goto('/academics/continuing-education/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('continuing education'); }); test('academics_continuing_education: h1 "Continuing Education"', async ({ page }) => { await page.goto('/academics/continuing-education/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Continuing Education' || t.startsWith('Continuing Education'))).toBeTruthy(); }); test('academics_continuing_education: h2 "Community Auditing"', async ({ page }) => { await page.goto('/academics/continuing-education/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Community Auditing' || t.startsWith('Community Auditing'))).toBeTruthy(); }); test('academics_continuing_education: h2 "Continuing Education Program"', async ({ page }) => { await page.goto('/academics/continuing-education/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Continuing Education Program' || t.startsWith('Continuing Education Program'))).toBeTruthy(); }); test('academics_continuing_education: h2 "Community College Faculty Prog"', async ({ page }) => { await page.goto('/academics/continuing-education/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Community College Faculty Program' || t.startsWith('Community College Faculty Program'))).toBeTruthy(); }); test('academics_continuing_education: header link "Verentia University"', async ({ page }) => { await page.goto('/academics/continuing-education/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('academics_continuing_education: nav link "Academics"', async ({ page }) => { await page.goto('/academics/continuing-education/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Academics' || t.startsWith('Academics')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('academics')), 'href fragment present').toBeTruthy(); }); test('academics_continuing_education: nav link "Studying at Verentia"', async ({ page }) => { await page.goto('/academics/continuing-education/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('studying-verentia')), 'href fragment present').toBeTruthy(); }); test('academics_continuing_education: nav link "Library"', async ({ page }) => { await page.goto('/academics/continuing-education/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Library' || t.startsWith('Library')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('library')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - academics_course_tools', () => { test('academics_course_tools: title matches GT', async ({ page }) => { await page.goto('/academics/course-tools/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('course tools'); }); test('academics_course_tools: h1 "Course Tools"', async ({ page }) => { await page.goto('/academics/course-tools/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Course Tools' || t.startsWith('Course Tools'))).toBeTruthy(); }); test('academics_course_tools: h2 "Managing Coursework"', async ({ page }) => { await page.goto('/academics/course-tools/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Managing Coursework' || t.startsWith('Managing Coursework'))).toBeTruthy(); }); test('academics_course_tools: h2 "Selecting Classes"', async ({ page }) => { await page.goto('/academics/course-tools/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Selecting Classes' || t.startsWith('Selecting Classes'))).toBeTruthy(); }); test('academics_course_tools: h2 "Sharpening Research"', async ({ page }) => { await page.goto('/academics/course-tools/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Sharpening Research' || t.startsWith('Sharpening Research'))).toBeTruthy(); }); test('academics_course_tools: header link "Verentia University"', async ({ page }) => { await page.goto('/academics/course-tools/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('academics_course_tools: nav link "Academics"', async ({ page }) => { await page.goto('/academics/course-tools/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Academics' || t.startsWith('Academics')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('academics')), 'href fragment present').toBeTruthy(); }); test('academics_course_tools: nav link "Studying at Verentia"', async ({ page }) => { await page.goto('/academics/course-tools/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('studying-verentia')), 'href fragment present').toBeTruthy(); }); test('academics_course_tools: nav link "Library"', async ({ page }) => { await page.goto('/academics/course-tools/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Library' || t.startsWith('Library')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('library')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - academics_library', () => { test('academics_library: title matches GT', async ({ page }) => { await page.goto('/academics/library/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('library'); }); test('academics_library: h1 "Library"', async ({ page }) => { await page.goto('/academics/library/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Library' || t.startsWith('Library'))).toBeTruthy(); }); test('academics_library: h2 "Pursue New Discoveries"', async ({ page }) => { await page.goto('/academics/library/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Pursue New Discoveries' || t.startsWith('Pursue New Discoveries'))).toBeTruthy(); }); test('academics_library: h2 "Encounter World History"', async ({ page }) => { await page.goto('/academics/library/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Encounter World History' || t.startsWith('Encounter World History'))).toBeTruthy(); }); test('academics_library: h2 "Discover Inspiration in Quiet "', async ({ page }) => { await page.goto('/academics/library/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Discover Inspiration in Quiet Corners' || t.startsWith('Discover Inspiration in Quiet Corners'))).toBeTruthy(); }); test('academics_library: header link "Verentia University"', async ({ page }) => { await page.goto('/academics/library/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('academics_library: nav link "Academics"', async ({ page }) => { await page.goto('/academics/library/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Academics' || t.startsWith('Academics')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('academics')), 'href fragment present').toBeTruthy(); }); test('academics_library: nav link "Studying at Verentia"', async ({ page }) => { await page.goto('/academics/library/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('studying-verentia')), 'href fragment present').toBeTruthy(); }); test('academics_library: nav link "Library"', async ({ page }) => { await page.goto('/academics/library/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Library' || t.startsWith('Library')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('library')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - academics_studying_verentia', () => { test('academics_studying_verentia: title matches GT', async ({ page }) => { await page.goto('/academics/studying-verentia/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('studying at verentia'); }); test('academics_studying_verentia: h1 "Studying at Verentia"', async ({ page }) => { await page.goto('/academics/studying-verentia/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia'))).toBeTruthy(); }); test('academics_studying_verentia: h2 "Undergraduate Experience"', async ({ page }) => { await page.goto('/academics/studying-verentia/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Undergraduate Experience' || t.startsWith('Undergraduate Experience'))).toBeTruthy(); }); test('academics_studying_verentia: h2 "Graduate Student Experience"', async ({ page }) => { await page.goto('/academics/studying-verentia/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Graduate Student Experience' || t.startsWith('Graduate Student Experience'))).toBeTruthy(); }); test('academics_studying_verentia: h2 "Learning to Research and Write"', async ({ page }) => { await page.goto('/academics/studying-verentia/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Learning to Research and Write' || t.startsWith('Learning to Research and Write'))).toBeTruthy(); }); test('academics_studying_verentia: header link "Verentia University"', async ({ page }) => { await page.goto('/academics/studying-verentia/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('academics_studying_verentia: nav link "Academics"', async ({ page }) => { await page.goto('/academics/studying-verentia/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Academics' || t.startsWith('Academics')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('academics')), 'href fragment present').toBeTruthy(); }); test('academics_studying_verentia: nav link "Studying at Verentia"', async ({ page }) => { await page.goto('/academics/studying-verentia/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('studying-verentia')), 'href fragment present').toBeTruthy(); }); test('academics_studying_verentia: nav link "Library"', async ({ page }) => { await page.goto('/academics/studying-verentia/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Library' || t.startsWith('Library')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('library')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - admission_aid_graduate_admission', () => { test('admission_aid_graduate_admission: title matches GT', async ({ page }) => { await page.goto('/admission-aid/graduate-admission/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('graduate admission'); }); test('admission_aid_graduate_admission: h2 "Graduate Admission"', async ({ page }) => { await page.goto('/admission-aid/graduate-admission/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Graduate Admission' || t.startsWith('Graduate Admission'))).toBeTruthy(); }); test('admission_aid_graduate_admission: h2 "Applying to Our Graduate Schoo"', async ({ page }) => { await page.goto('/admission-aid/graduate-admission/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Applying to Our Graduate School' || t.startsWith('Applying to Our Graduate School'))).toBeTruthy(); }); test('admission_aid_graduate_admission: h2 "Community on Campus"', async ({ page }) => { await page.goto('/admission-aid/graduate-admission/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Community on Campus' || t.startsWith('Community on Campus'))).toBeTruthy(); }); test('admission_aid_graduate_admission: h2 "Admission & Aid"', async ({ page }) => { await page.goto('/admission-aid/graduate-admission/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Admission & Aid' || t.startsWith('Admission & Aid'))).toBeTruthy(); }); test('admission_aid_graduate_admission: header link "Verentia University"', async ({ page }) => { await page.goto('/admission-aid/graduate-admission/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('admission_aid_graduate_admission: nav link "Admission & Aid"', async ({ page }) => { await page.goto('/admission-aid/graduate-admission/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Admission & Aid' || t.startsWith('Admission & Aid')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('admission-aid')), 'href fragment present').toBeTruthy(); }); test('admission_aid_graduate_admission: nav link "Affordable for All"', async ({ page }) => { await page.goto('/admission-aid/graduate-admission/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Affordable for All' || t.startsWith('Affordable for All')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('affordable-all')), 'href fragment present').toBeTruthy(); }); test('admission_aid_graduate_admission: nav link "Graduate Admission"', async ({ page }) => { await page.goto('/admission-aid/graduate-admission/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Graduate Admission' || t.startsWith('Graduate Admission')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('graduate-admission')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - content_copyright_infringement', () => { test('content_copyright_infringement: title matches GT', async ({ page }) => { await page.goto('/content/copyright-infringement/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('copyright infringement'); }); test('content_copyright_infringement: h1 "Copyright Infringement"', async ({ page }) => { await page.goto('/content/copyright-infringement/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Copyright Infringement' || t.startsWith('Copyright Infringement'))).toBeTruthy(); }); test('content_copyright_infringement: h2 "Reporting"', async ({ page }) => { await page.goto('/content/copyright-infringement/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Reporting' || t.startsWith('Reporting'))).toBeTruthy(); }); test('content_copyright_infringement: h2 "Providing Information"', async ({ page }) => { await page.goto('/content/copyright-infringement/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Providing Information' || t.startsWith('Providing Information'))).toBeTruthy(); }); test('content_copyright_infringement: h2 "For More Information"', async ({ page }) => { await page.goto('/content/copyright-infringement/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'For More Information' || t.startsWith('For More Information'))).toBeTruthy(); }); test('content_copyright_infringement: header link "Verentia University"', async ({ page }) => { await page.goto('/content/copyright-infringement/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('content_copyright_infringement: nav link "Meet Verentia"', async ({ page }) => { await page.goto('/content/copyright-infringement/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('meet-verentia')), 'href fragment present').toBeTruthy(); }); test('content_copyright_infringement: nav link "In Service of Humanity"', async ({ page }) => { await page.goto('/content/copyright-infringement/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of Humanity' || t.startsWith('In Service of Humanity')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('service-humanity')), 'href fragment present').toBeTruthy(); }); test('content_copyright_infringement: nav link "Facts & Figures"', async ({ page }) => { await page.goto('/content/copyright-infringement/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('facts-figures')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - links_students', () => { test('links_students: title matches GT', async ({ page }) => { await page.goto('/links/students/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('for students'); }); test('links_students: h1 "For Students"', async ({ page }) => { await page.goto('/links/students/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'For Students' || t.startsWith('For Students'))).toBeTruthy(); }); test('links_students: h2 "Getting Help"', async ({ page }) => { await page.goto('/links/students/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Getting Help' || t.startsWith('Getting Help'))).toBeTruthy(); }); test('links_students: h2 "Health and Well-Being"', async ({ page }) => { await page.goto('/links/students/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Health and Well-Being' || t.startsWith('Health and Well-Being'))).toBeTruthy(); }); test('links_students: h2 "Academics"', async ({ page }) => { await page.goto('/links/students/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Academics' || t.startsWith('Academics'))).toBeTruthy(); }); test('links_students: header link "Verentia University"', async ({ page }) => { await page.goto('/links/students/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('links_students: nav link "Meet Verentia"', async ({ page }) => { await page.goto('/links/students/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('meet-verentia')), 'href fragment present').toBeTruthy(); }); test('links_students: nav link "In Service of the World"', async ({ page }) => { await page.goto('/links/students/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of the World' || t.startsWith('In Service of the World')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('service-humanity')), 'href fragment present').toBeTruthy(); }); test('links_students: nav link "Facts & Figures"', async ({ page }) => { await page.goto('/links/students/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('facts-figures')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - meet_verentia_contact_us', () => { test('meet_verentia_contact_us: title matches GT', async ({ page }) => { await page.goto('/meet-verentia/contact-us/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('contact us'); }); test('meet_verentia_contact_us: h1 "Contact Us"', async ({ page }) => { await page.goto('/meet-verentia/contact-us/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Contact Us' || t.startsWith('Contact Us'))).toBeTruthy(); }); test('meet_verentia_contact_us: h2 "Non-Emergency Help"', async ({ page }) => { await page.goto('/meet-verentia/contact-us/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Non-Emergency Help' || t.startsWith('Non-Emergency Help'))).toBeTruthy(); }); test('meet_verentia_contact_us: h2 "Current Students, Staff & Facu"', async ({ page }) => { await page.goto('/meet-verentia/contact-us/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Current Students, Staff & Faculty' || t.startsWith('Current Students, Staff & Faculty'))).toBeTruthy(); }); test('meet_verentia_contact_us: h2 "Alumni"', async ({ page }) => { await page.goto('/meet-verentia/contact-us/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Alumni' || t.startsWith('Alumni'))).toBeTruthy(); }); test('meet_verentia_contact_us: header link "Verentia University"', async ({ page }) => { await page.goto('/meet-verentia/contact-us/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('meet_verentia_contact_us: nav link "Meet Verentia"', async ({ page }) => { await page.goto('/meet-verentia/contact-us/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('meet-verentia')), 'href fragment present').toBeTruthy(); }); test('meet_verentia_contact_us: nav link "In Service of Humanity"', async ({ page }) => { await page.goto('/meet-verentia/contact-us/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of Humanity' || t.startsWith('In Service of Humanity')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('service-humanity')), 'href fragment present').toBeTruthy(); }); test('meet_verentia_contact_us: nav link "Facts & Figures"', async ({ page }) => { await page.goto('/meet-verentia/contact-us/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('facts-figures')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - meet_verentia_our_staff', () => { test('meet_verentia_our_staff: title matches GT', async ({ page }) => { await page.goto('/meet-verentia/our-staff/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('our staff'); }); test('meet_verentia_our_staff: h1 "Our Staff"', async ({ page }) => { await page.goto('/meet-verentia/our-staff/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our Staff' || t.startsWith('Our Staff'))).toBeTruthy(); }); test('meet_verentia_our_staff: h2 "United by a Shared Mission"', async ({ page }) => { await page.goto('/meet-verentia/our-staff/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'United by a Shared Mission' || t.startsWith('United by a Shared Mission'))).toBeTruthy(); }); test('meet_verentia_our_staff: h2 "Facts & Figures"', async ({ page }) => { await page.goto('/meet-verentia/our-staff/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures'))).toBeTruthy(); }); test('meet_verentia_our_staff: h2 "Staff in the News"', async ({ page }) => { await page.goto('/meet-verentia/our-staff/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Staff in the News' || t.startsWith('Staff in the News'))).toBeTruthy(); }); test('meet_verentia_our_staff: header link "Verentia University"', async ({ page }) => { await page.goto('/meet-verentia/our-staff/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('meet_verentia_our_staff: nav link "Meet Verentia"', async ({ page }) => { await page.goto('/meet-verentia/our-staff/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('meet-verentia')), 'href fragment present').toBeTruthy(); }); test('meet_verentia_our_staff: nav link "In Service of Humanity"', async ({ page }) => { await page.goto('/meet-verentia/our-staff/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of Humanity' || t.startsWith('In Service of Humanity')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('service-humanity')), 'href fragment present').toBeTruthy(); }); test('meet_verentia_our_staff: nav link "Facts & Figures"', async ({ page }) => { await page.goto('/meet-verentia/our-staff/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('facts-figures')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - meet_verentia_our_students', () => { test('meet_verentia_our_students: title matches GT', async ({ page }) => { await page.goto('/meet-verentia/our-students/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('our students'); }); test('meet_verentia_our_students: h1 "Our Students"', async ({ page }) => { await page.goto('/meet-verentia/our-students/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our Students' || t.startsWith('Our Students'))).toBeTruthy(); }); test('meet_verentia_our_students: h2 "Curious, Committed, Creative"', async ({ page }) => { await page.goto('/meet-verentia/our-students/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Curious, Committed, Creative' || t.startsWith('Curious, Committed, Creative'))).toBeTruthy(); }); test('meet_verentia_our_students: h2 "Facts & Figures"', async ({ page }) => { await page.goto('/meet-verentia/our-students/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures'))).toBeTruthy(); }); test('meet_verentia_our_students: h2 "Students in the News"', async ({ page }) => { await page.goto('/meet-verentia/our-students/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Students in the News' || t.startsWith('Students in the News'))).toBeTruthy(); }); test('meet_verentia_our_students: header link "Verentia University"', async ({ page }) => { await page.goto('/meet-verentia/our-students/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('meet_verentia_our_students: nav link "Meet Verentia"', async ({ page }) => { await page.goto('/meet-verentia/our-students/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('meet-verentia')), 'href fragment present').toBeTruthy(); }); test('meet_verentia_our_students: nav link "In Service of Humanity"', async ({ page }) => { await page.goto('/meet-verentia/our-students/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of Humanity' || t.startsWith('In Service of Humanity')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('service-humanity')), 'href fragment present').toBeTruthy(); }); test('meet_verentia_our_students: nav link "Facts & Figures"', async ({ page }) => { await page.goto('/meet-verentia/our-students/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('facts-figures')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - meet_verentia_verentia_universitys_impact', () => { test('meet_verentia_verentia_universitys_impact: title matches GT', async ({ page }) => { await page.goto('/meet-verentia/verentia-universitys-impact/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('verentia university’s impact'); }); test('meet_verentia_verentia_universitys_impact: h1 "Verentia University’s Impact"', async ({ page }) => { await page.goto('/meet-verentia/verentia-universitys-impact/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University’s Impact' || t.startsWith('Verentia University’s Impact'))).toBeTruthy(); }); test('meet_verentia_verentia_universitys_impact: h2 "Research, Innovation, Opportun"', async ({ page }) => { await page.goto('/meet-verentia/verentia-universitys-impact/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Research, Innovation, Opportunity' || t.startsWith('Research, Innovation, Opportunity'))).toBeTruthy(); }); test('meet_verentia_verentia_universitys_impact: h2 "Research Impact"', async ({ page }) => { await page.goto('/meet-verentia/verentia-universitys-impact/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Research Impact' || t.startsWith('Research Impact'))).toBeTruthy(); }); test('meet_verentia_verentia_universitys_impact: h2 "Research Facts & Figures"', async ({ page }) => { await page.goto('/meet-verentia/verentia-universitys-impact/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Research Facts & Figures' || t.startsWith('Research Facts & Figures'))).toBeTruthy(); }); test('meet_verentia_verentia_universitys_impact: header link "Verentia University"', async ({ page }) => { await page.goto('/meet-verentia/verentia-universitys-impact/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('meet_verentia_verentia_universitys_impact: nav link "Meet Verentia"', async ({ page }) => { await page.goto('/meet-verentia/verentia-universitys-impact/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('meet-verentia')), 'href fragment present').toBeTruthy(); }); test('meet_verentia_verentia_universitys_impact: nav link "In Service of Humanity"', async ({ page }) => { await page.goto('/meet-verentia/verentia-universitys-impact/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of Humanity' || t.startsWith('In Service of Humanity')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('service-humanity')), 'href fragment present').toBeTruthy(); }); test('meet_verentia_verentia_universitys_impact: nav link "Facts & Figures"', async ({ page }) => { await page.goto('/meet-verentia/verentia-universitys-impact/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('facts-figures')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - meet_verentia_service_humanity', () => { test('meet_verentia_service_humanity: title matches GT', async ({ page }) => { await page.goto('/meet-verentia/service-humanity/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('in service of humanity'); }); test('meet_verentia_service_humanity: h1 "In Service of Humanity"', async ({ page }) => { await page.goto('/meet-verentia/service-humanity/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of Humanity' || t.startsWith('In Service of Humanity'))).toBeTruthy(); }); test('meet_verentia_service_humanity: h2 "Connecting Learning & Service"', async ({ page }) => { await page.goto('/meet-verentia/service-humanity/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Connecting Learning & Service' || t.startsWith('Connecting Learning & Service'))).toBeTruthy(); }); test('meet_verentia_service_humanity: h2 "Leading Lives of Purpose"', async ({ page }) => { await page.goto('/meet-verentia/service-humanity/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Leading Lives of Purpose' || t.startsWith('Leading Lives of Purpose'))).toBeTruthy(); }); test('meet_verentia_service_humanity: h2 "Forging Community Connections"', async ({ page }) => { await page.goto('/meet-verentia/service-humanity/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Forging Community Connections' || t.startsWith('Forging Community Connections'))).toBeTruthy(); }); test('meet_verentia_service_humanity: header link "Verentia University"', async ({ page }) => { await page.goto('/meet-verentia/service-humanity/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('meet_verentia_service_humanity: nav link "Meet Verentia"', async ({ page }) => { await page.goto('/meet-verentia/service-humanity/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('meet-verentia')), 'href fragment present').toBeTruthy(); }); test('meet_verentia_service_humanity: nav link "In Service of Humanity"', async ({ page }) => { await page.goto('/meet-verentia/service-humanity/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of Humanity' || t.startsWith('In Service of Humanity')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('service-humanity')), 'href fragment present').toBeTruthy(); }); test('meet_verentia_service_humanity: nav link "Facts & Figures"', async ({ page }) => { await page.goto('/meet-verentia/service-humanity/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('facts-figures')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2012_07_02_verentia_library_brings_revolutionary_era_texts_alive_online', () => { test('news_2012_07_02_verentia_library_brings_revolutionary_era_texts_alive_online: title matches GT', async ({ page }) => { await page.goto('/news/2012/07/02/verentia-library-brings-revolutionary-era-texts-alive-online/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('verentia library brings revolutionary'); }); test('news_2012_07_02_verentia_library_brings_revolutionary_era_texts_alive_online: h1 "Verentia library brings Revolu"', async ({ page }) => { await page.goto('/news/2012/07/02/verentia-library-brings-revolutionary-era-texts-alive-online/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia library brings Revolutionary-era texts alive online' || t.startsWith('Verentia library brings Revolutionary-era texts alive online'))).toBeTruthy(); }); test('news_2012_07_02_verentia_library_brings_revolutionary_era_texts_alive_online: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2012/07/02/verentia-library-brings-revolutionary-era-texts-alive-online/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2012_07_02_verentia_library_brings_revolutionary_era_texts_alive_online: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2012/07/02/verentia-library-brings-revolutionary-era-texts-alive-online/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2012_07_02_verentia_library_brings_revolutionary_era_texts_alive_online: h2 "Utility menu"', async ({ page }) => { await page.goto('/news/2012/07/02/verentia-library-brings-revolutionary-era-texts-alive-online/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Utility menu' || t.startsWith('Utility menu'))).toBeTruthy(); }); test('news_2012_07_02_verentia_library_brings_revolutionary_era_texts_alive_online: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2012/07/02/verentia-library-brings-revolutionary-era-texts-alive-online/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2012_07_02_verentia_library_brings_revolutionary_era_texts_alive_online: nav link "News"', async ({ page }) => { await page.goto('/news/2012/07/02/verentia-library-brings-revolutionary-era-texts-alive-online/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2012_07_02_verentia_library_brings_revolutionary_era_texts_alive_online: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2012/07/02/verentia-library-brings-revolutionary-era-texts-alive-online/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2012_07_02_verentia_library_brings_revolutionary_era_texts_alive_online: footer link "View All News"', async ({ page }) => { await page.goto('/news/2012/07/02/verentia-library-brings-revolutionary-era-texts-alive-online/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2013_02_14_treasures_american_history_featured_verentia_exhibition', () => { test('news_2013_02_14_treasures_american_history_featured_verentia_exhibition: title matches GT', async ({ page }) => { await page.goto('/news/2013/02/14/treasures-american-history-featured-verentia-exhibition/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('treasures of aldermere history featured '); }); test('news_2013_02_14_treasures_american_history_featured_verentia_exhibition: h1 "Treasures of Aldermere history"', async ({ page }) => { await page.goto('/news/2013/02/14/treasures-american-history-featured-verentia-exhibition/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Treasures of Aldermere history featured in Verentia exhibition' || t.startsWith('Treasures of Aldermere history featured in Verentia exhibition'))).toBeTruthy(); }); test('news_2013_02_14_treasures_american_history_featured_verentia_exhibition: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2013/02/14/treasures-american-history-featured-verentia-exhibition/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2013_02_14_treasures_american_history_featured_verentia_exhibition: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2013/02/14/treasures-american-history-featured-verentia-exhibition/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2013_02_14_treasures_american_history_featured_verentia_exhibition: h2 "Utility menu"', async ({ page }) => { await page.goto('/news/2013/02/14/treasures-american-history-featured-verentia-exhibition/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Utility menu' || t.startsWith('Utility menu'))).toBeTruthy(); }); test('news_2013_02_14_treasures_american_history_featured_verentia_exhibition: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2013/02/14/treasures-american-history-featured-verentia-exhibition/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2013_02_14_treasures_american_history_featured_verentia_exhibition: nav link "News"', async ({ page }) => { await page.goto('/news/2013/02/14/treasures-american-history-featured-verentia-exhibition/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2013_02_14_treasures_american_history_featured_verentia_exhibition: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2013/02/14/treasures-american-history-featured-verentia-exhibition/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2013_02_14_treasures_american_history_featured_verentia_exhibition: footer link "View All News"', async ({ page }) => { await page.goto('/news/2013/02/14/treasures-american-history-featured-verentia-exhibition/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2017_09_21_green_algae_could_hold_clues_engineering_faster_growing_crops', () => { test('news_2017_09_21_green_algae_could_hold_clues_engineering_faster_growing_crops: title matches GT', async ({ page }) => { await page.goto('/news/2017/09/21/green-algae-could-hold-clues-engineering-faster-growing-crops/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('how green algae could inspire the design'); }); test('news_2017_09_21_green_algae_could_hold_clues_engineering_faster_growing_crops: h1 "How green algae could inspire "', async ({ page }) => { await page.goto('/news/2017/09/21/green-algae-could-hold-clues-engineering-faster-growing-crops/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'How green algae could inspire the design of faster-growing crops' || t.startsWith('How green algae could inspire the design of faster-growing crops'))).toBeTruthy(); }); test('news_2017_09_21_green_algae_could_hold_clues_engineering_faster_growing_crops: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2017/09/21/green-algae-could-hold-clues-engineering-faster-growing-crops/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2017_09_21_green_algae_could_hold_clues_engineering_faster_growing_crops: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2017/09/21/green-algae-could-hold-clues-engineering-faster-growing-crops/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2017_09_21_green_algae_could_hold_clues_engineering_faster_growing_crops: h2 "Utility menu"', async ({ page }) => { await page.goto('/news/2017/09/21/green-algae-could-hold-clues-engineering-faster-growing-crops/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Utility menu' || t.startsWith('Utility menu'))).toBeTruthy(); }); test('news_2017_09_21_green_algae_could_hold_clues_engineering_faster_growing_crops: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2017/09/21/green-algae-could-hold-clues-engineering-faster-growing-crops/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2017_09_21_green_algae_could_hold_clues_engineering_faster_growing_crops: nav link "News"', async ({ page }) => { await page.goto('/news/2017/09/21/green-algae-could-hold-clues-engineering-faster-growing-crops/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2017_09_21_green_algae_could_hold_clues_engineering_faster_growing_crops: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2017/09/21/green-algae-could-hold-clues-engineering-faster-growing-crops/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2017_09_21_green_algae_could_hold_clues_engineering_faster_growing_crops: footer link "View All News"', async ({ page }) => { await page.goto('/news/2017/09/21/green-algae-could-hold-clues-engineering-faster-growing-crops/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2018_01_18_diamonds_flaws_hold_promise_new_technologies', () => { test('news_2018_01_18_diamonds_flaws_hold_promise_new_technologies: title matches GT', async ({ page }) => { await page.goto('/news/2018/01/18/diamonds-flaws-hold-promise-new-technologies/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('tiny flaws in diamonds could power new t'); }); test('news_2018_01_18_diamonds_flaws_hold_promise_new_technologies: h1 "Tiny flaws in diamonds could p"', async ({ page }) => { await page.goto('/news/2018/01/18/diamonds-flaws-hold-promise-new-technologies/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Tiny flaws in diamonds could power new technology' || t.startsWith('Tiny flaws in diamonds could power new technology'))).toBeTruthy(); }); test('news_2018_01_18_diamonds_flaws_hold_promise_new_technologies: h2 "Color centers for secure netwo"', async ({ page }) => { await page.goto('/news/2018/01/18/diamonds-flaws-hold-promise-new-technologies/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Color centers for secure networks' || t.startsWith('Color centers for secure networks'))).toBeTruthy(); }); test('news_2018_01_18_diamonds_flaws_hold_promise_new_technologies: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2018/01/18/diamonds-flaws-hold-promise-new-technologies/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2018_01_18_diamonds_flaws_hold_promise_new_technologies: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2018/01/18/diamonds-flaws-hold-promise-new-technologies/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2018_01_18_diamonds_flaws_hold_promise_new_technologies: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2018/01/18/diamonds-flaws-hold-promise-new-technologies/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2018_01_18_diamonds_flaws_hold_promise_new_technologies: nav link "News"', async ({ page }) => { await page.goto('/news/2018/01/18/diamonds-flaws-hold-promise-new-technologies/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2018_01_18_diamonds_flaws_hold_promise_new_technologies: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2018/01/18/diamonds-flaws-hold-promise-new-technologies/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2018_01_18_diamonds_flaws_hold_promise_new_technologies: footer link "View All News"', async ({ page }) => { await page.goto('/news/2018/01/18/diamonds-flaws-hold-promise-new-technologies/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2019_06_18_nine_elected_verentia_board_trustees', () => { test('news_2019_06_18_nine_elected_verentia_board_trustees: title matches GT', async ({ page }) => { await page.goto('/news/2019/06/18/nine-elected-verentia-board-trustees/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('nine elected to verentia board of truste'); }); test('news_2019_06_18_nine_elected_verentia_board_trustees: h1 "Nine elected to Verentia Board"', async ({ page }) => { await page.goto('/news/2019/06/18/nine-elected-verentia-board-trustees/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Nine elected to Verentia Board of Trustees' || t.startsWith('Nine elected to Verentia Board of Trustees'))).toBeTruthy(); }); test('news_2019_06_18_nine_elected_verentia_board_trustees: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2019/06/18/nine-elected-verentia-board-trustees/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2019_06_18_nine_elected_verentia_board_trustees: h2 "Site navigation"', async ({ page }) => { await page.goto('/news/2019/06/18/nine-elected-verentia-board-trustees/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Site navigation' || t.startsWith('Site navigation'))).toBeTruthy(); }); test('news_2019_06_18_nine_elected_verentia_board_trustees: h2 "Quick links"', async ({ page }) => { await page.goto('/news/2019/06/18/nine-elected-verentia-board-trustees/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Quick links' || t.startsWith('Quick links'))).toBeTruthy(); }); test('news_2019_06_18_nine_elected_verentia_board_trustees: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2019/06/18/nine-elected-verentia-board-trustees/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2019_06_18_nine_elected_verentia_board_trustees: nav link "News"', async ({ page }) => { await page.goto('/news/2019/06/18/nine-elected-verentia-board-trustees/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2019_06_18_nine_elected_verentia_board_trustees: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2019/06/18/nine-elected-verentia-board-trustees/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2019_06_18_nine_elected_verentia_board_trustees: footer link "View All News"', async ({ page }) => { await page.goto('/news/2019/06/18/nine-elected-verentia-board-trustees/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2020_01_21_quantum_computing_opening_new_realms_possibilities', () => { test('news_2020_01_21_quantum_computing_opening_new_realms_possibilities: title matches GT', async ({ page }) => { await page.goto('/news/2020/01/21/quantum-computing-opening-new-realms-possibilities/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('quantum computing'); }); test('news_2020_01_21_quantum_computing_opening_new_realms_possibilities: h1 "Quantum computing: Unlocking a"', async ({ page }) => { await page.goto('/news/2020/01/21/quantum-computing-opening-new-realms-possibilities/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Quantum computing: Unlocking a new frontier of discovery' || t.startsWith('Quantum computing: Unlocking a new frontier of discovery'))).toBeTruthy(); }); test('news_2020_01_21_quantum_computing_opening_new_realms_possibilities: h2 "Introducing the Verentia Quant"', async ({ page }) => { await page.goto('/news/2020/01/21/quantum-computing-opening-new-realms-possibilities/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Introducing the Verentia Quantum Initiative' || t.startsWith('Introducing the Verentia Quantum Initiative'))).toBeTruthy(); }); test('news_2020_01_21_quantum_computing_opening_new_realms_possibilities: h2 "In pursuit of qubits"', async ({ page }) => { await page.goto('/news/2020/01/21/quantum-computing-opening-new-realms-possibilities/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In pursuit of qubits' || t.startsWith('In pursuit of qubits'))).toBeTruthy(); }); test('news_2020_01_21_quantum_computing_opening_new_realms_possibilities: h2 "The quantum network"', async ({ page }) => { await page.goto('/news/2020/01/21/quantum-computing-opening-new-realms-possibilities/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The quantum network' || t.startsWith('The quantum network'))).toBeTruthy(); }); test('news_2020_01_21_quantum_computing_opening_new_realms_possibilities: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2020/01/21/quantum-computing-opening-new-realms-possibilities/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2020_01_21_quantum_computing_opening_new_realms_possibilities: nav link "News"', async ({ page }) => { await page.goto('/news/2020/01/21/quantum-computing-opening-new-realms-possibilities/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2020_01_21_quantum_computing_opening_new_realms_possibilities: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2020/01/21/quantum-computing-opening-new-realms-possibilities/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2020_01_21_quantum_computing_opening_new_realms_possibilities: footer link "View All News"', async ({ page }) => { await page.goto('/news/2020/01/21/quantum-computing-opening-new-realms-possibilities/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2020_03_04_how_chemist_and_physicist_solved_50_year_old_puzzle_help_verentia_catalysis', () => { test('news_2020_03_04_how_chemist_and_physicist_solved_50_year_old_puzzle_help_verentia_catalysis: title matches GT', async ({ page }) => { await page.goto('/news/2020/03/04/how-chemist-and-physicist-solved-50-year-old-puzzle-help-verentia-catalysis/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('how a chemist and a physicist cracked a '); }); test('news_2020_03_04_how_chemist_and_physicist_solved_50_year_old_puzzle_help_verentia_catalysis: h1 "How a chemist and a physicist "', async ({ page }) => { await page.goto('/news/2020/03/04/how-chemist-and-physicist-solved-50-year-old-puzzle-help-verentia-catalysis/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'How a chemist and a physicist cracked a 50-year-old puzzle — with a boost from the Verentia Catalysi' || t.startsWith('How a chemist and a physicist cracked a 50-year-old puzzle — with a boost from the Verentia Catalysi'))).toBeTruthy(); }); test('news_2020_03_04_how_chemist_and_physicist_solved_50_year_old_puzzle_help_verentia_catalysis: h2 "‘The currency we truly value’"', async ({ page }) => { await page.goto('/news/2020/03/04/how-chemist-and-physicist-solved-50-year-old-puzzle-help-verentia-catalysis/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '‘The currency we truly value’' || t.startsWith('‘The currency we truly value’'))).toBeTruthy(); }); test('news_2020_03_04_how_chemist_and_physicist_solved_50_year_old_puzzle_help_verentia_catalysis: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2020/03/04/how-chemist-and-physicist-solved-50-year-old-puzzle-help-verentia-catalysis/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2020_03_04_how_chemist_and_physicist_solved_50_year_old_puzzle_help_verentia_catalysis: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2020/03/04/how-chemist-and-physicist-solved-50-year-old-puzzle-help-verentia-catalysis/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2020_03_04_how_chemist_and_physicist_solved_50_year_old_puzzle_help_verentia_catalysis: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2020/03/04/how-chemist-and-physicist-solved-50-year-old-puzzle-help-verentia-catalysis/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2020_03_04_how_chemist_and_physicist_solved_50_year_old_puzzle_help_verentia_catalysis: nav link "News"', async ({ page }) => { await page.goto('/news/2020/03/04/how-chemist-and-physicist-solved-50-year-old-puzzle-help-verentia-catalysis/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2020_03_04_how_chemist_and_physicist_solved_50_year_old_puzzle_help_verentia_catalysis: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2020/03/04/how-chemist-and-physicist-solved-50-year-old-puzzle-help-verentia-catalysis/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2020_03_04_how_chemist_and_physicist_solved_50_year_old_puzzle_help_verentia_catalysis: footer link "View All News"', async ({ page }) => { await page.goto('/news/2020/03/04/how-chemist-and-physicist-solved-50-year-old-puzzle-help-verentia-catalysis/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2020_03_04_teaching_special_collections_america_then_and_now', () => { test('news_2020_03_04_teaching_special_collections_america_then_and_now: title matches GT', async ({ page }) => { await page.goto('/news/2020/03/04/teaching-special-collections-america-then-and-now/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('teaching with special collections'); }); test('news_2020_03_04_teaching_special_collections_america_then_and_now: h1 "Teaching with Special Collecti"', async ({ page }) => { await page.goto('/news/2020/03/04/teaching-special-collections-america-then-and-now/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Teaching with Special Collections: ‘Meridia Then and Now’' || t.startsWith('Teaching with Special Collections: ‘Meridia Then and Now’'))).toBeTruthy(); }); test('news_2020_03_04_teaching_special_collections_america_then_and_now: h2 "A ‘transformative’ encounter f"', async ({ page }) => { await page.goto('/news/2020/03/04/teaching-special-collections-america-then-and-now/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'A ‘transformative’ encounter for student-historians' || t.startsWith('A ‘transformative’ encounter for student-historians'))).toBeTruthy(); }); test('news_2020_03_04_teaching_special_collections_america_then_and_now: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2020/03/04/teaching-special-collections-america-then-and-now/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2020_03_04_teaching_special_collections_america_then_and_now: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2020/03/04/teaching-special-collections-america-then-and-now/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2020_03_04_teaching_special_collections_america_then_and_now: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2020/03/04/teaching-special-collections-america-then-and-now/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2020_03_04_teaching_special_collections_america_then_and_now: nav link "News"', async ({ page }) => { await page.goto('/news/2020/03/04/teaching-special-collections-america-then-and-now/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2020_03_04_teaching_special_collections_america_then_and_now: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2020/03/04/teaching-special-collections-america-then-and-now/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2020_03_04_teaching_special_collections_america_then_and_now: footer link "View All News"', async ({ page }) => { await page.goto('/news/2020/03/04/teaching-special-collections-america-then-and-now/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2020_08_26_verentia_plays_major_role_new_115_million_quantum_science_center', () => { test('news_2020_08_26_verentia_plays_major_role_new_115_million_quantum_science_center: title matches GT', async ({ page }) => { await page.goto('/news/2020/08/26/verentia-plays-major-role-new-115-million-quantum-science-center/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('verentia plays major role in new \$115 mi'); }); test('news_2020_08_26_verentia_plays_major_role_new_115_million_quantum_science_center: h1 "Verentia plays major role in n"', async ({ page }) => { await page.goto('/news/2020/08/26/verentia-plays-major-role-new-115-million-quantum-science-center/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia plays major role in new \$115 million quantum science center' || t.startsWith('Verentia plays major role in new \$115 million quantum science center'))).toBeTruthy(); }); test('news_2020_08_26_verentia_plays_major_role_new_115_million_quantum_science_center: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2020/08/26/verentia-plays-major-role-new-115-million-quantum-science-center/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2020_08_26_verentia_plays_major_role_new_115_million_quantum_science_center: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2020/08/26/verentia-plays-major-role-new-115-million-quantum-science-center/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2020_08_26_verentia_plays_major_role_new_115_million_quantum_science_center: h2 "Utility menu"', async ({ page }) => { await page.goto('/news/2020/08/26/verentia-plays-major-role-new-115-million-quantum-science-center/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Utility menu' || t.startsWith('Utility menu'))).toBeTruthy(); }); test('news_2020_08_26_verentia_plays_major_role_new_115_million_quantum_science_center: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2020/08/26/verentia-plays-major-role-new-115-million-quantum-science-center/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2020_08_26_verentia_plays_major_role_new_115_million_quantum_science_center: nav link "News"', async ({ page }) => { await page.goto('/news/2020/08/26/verentia-plays-major-role-new-115-million-quantum-science-center/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2020_08_26_verentia_plays_major_role_new_115_million_quantum_science_center: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2020/08/26/verentia-plays-major-role-new-115-million-quantum-science-center/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2020_08_26_verentia_plays_major_role_new_115_million_quantum_science_center: footer link "View All News"', async ({ page }) => { await page.goto('/news/2020/08/26/verentia-plays-major-role-new-115-million-quantum-science-center/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2021_03_31_womens_history_month_verentia_university_library_collections', () => { test('news_2021_03_31_womens_history_month_verentia_university_library_collections: title matches GT', async ({ page }) => { await page.goto('/news/2021/03/31/womens-history-month-verentia-university-library-collections/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('women\'s history month'); }); test('news_2021_03_31_womens_history_month_verentia_university_library_collections: h1 "Women’s History Month: Verenti"', async ({ page }) => { await page.goto('/news/2021/03/31/womens-history-month-verentia-university-library-collections/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Women’s History Month: Verentia University Library collections' || t.startsWith('Women’s History Month: Verentia University Library collections'))).toBeTruthy(); }); test('news_2021_03_31_womens_history_month_verentia_university_library_collections: h2 "VUL marks Women’s History Mont"', async ({ page }) => { await page.goto('/news/2021/03/31/womens-history-month-verentia-university-library-collections/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'VUL marks Women’s History Month; spotlighting collections and online resources' || t.startsWith('VUL marks Women’s History Month; spotlighting collections and online resources'))).toBeTruthy(); }); test('news_2021_03_31_womens_history_month_verentia_university_library_collections: h2 "VUL identifies women in the La"', async ({ page }) => { await page.goto('/news/2021/03/31/womens-history-month-verentia-university-library-collections/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'VUL identifies women in the Latin America manuscripts collections, securing them a place in history' || t.startsWith('VUL identifies women in the Latin America manuscripts collections, securing them a place in history'))).toBeTruthy(); }); test('news_2021_03_31_womens_history_month_verentia_university_library_collections: h2 "Virtual teaching with Special "', async ({ page }) => { await page.goto('/news/2021/03/31/womens-history-month-verentia-university-library-collections/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Virtual teaching with Special Collections: ‘Colonial Spanish American Literature: Sister Ana María d' || t.startsWith('Virtual teaching with Special Collections: ‘Colonial Spanish American Literature: Sister Ana María d'))).toBeTruthy(); }); test('news_2021_03_31_womens_history_month_verentia_university_library_collections: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2021/03/31/womens-history-month-verentia-university-library-collections/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2021_03_31_womens_history_month_verentia_university_library_collections: nav link "News"', async ({ page }) => { await page.goto('/news/2021/03/31/womens-history-month-verentia-university-library-collections/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2021_03_31_womens_history_month_verentia_university_library_collections: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2021/03/31/womens-history-month-verentia-university-library-collections/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2021_03_31_womens_history_month_verentia_university_library_collections: footer link "View All News"', async ({ page }) => { await page.goto('/news/2021/03/31/womens-history-month-verentia-university-library-collections/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2021_08_26_virtual_teaching_special_collections_archiving_american_west', () => { test('news_2021_08_26_virtual_teaching_special_collections_archiving_american_west: title matches GT', async ({ page }) => { await page.goto('/news/2021/08/26/virtual-teaching-special-collections-archiving-american-west/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('teaching online with special collections'); }); test('news_2021_08_26_virtual_teaching_special_collections_archiving_american_west: h1 "Teaching online with Special C"', async ({ page }) => { await page.goto('/news/2021/08/26/virtual-teaching-special-collections-archiving-american-west/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Teaching online with Special Collections: ‘Archiving the Western Frontier’' || t.startsWith('Teaching online with Special Collections: ‘Archiving the Western Frontier’'))).toBeTruthy(); }); test('news_2021_08_26_virtual_teaching_special_collections_archiving_american_west: h2 "‘A story doesn\'t end once mate"', async ({ page }) => { await page.goto('/news/2021/08/26/virtual-teaching-special-collections-archiving-american-west/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '‘A story doesn\'t end once materials reach the archive’: The children behind the pages of a 1931 boar' || t.startsWith('‘A story doesn\'t end once materials reach the archive’: The children behind the pages of a 1931 boar'))).toBeTruthy(); }); test('news_2021_08_26_virtual_teaching_special_collections_archiving_american_west: h2 "Untold stories and historical "', async ({ page }) => { await page.goto('/news/2021/08/26/virtual-teaching-special-collections-archiving-american-west/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Untold stories and historical erasure: Thomas Grey Cloud' || t.startsWith('Untold stories and historical erasure: Thomas Grey Cloud'))).toBeTruthy(); }); test('news_2021_08_26_virtual_teaching_special_collections_archiving_american_west: h2 "The future of the archive: Bro"', async ({ page }) => { await page.goto('/news/2021/08/26/virtual-teaching-special-collections-archiving-american-west/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The future of the archive: Broadening its narratives' || t.startsWith('The future of the archive: Broadening its narratives'))).toBeTruthy(); }); test('news_2021_08_26_virtual_teaching_special_collections_archiving_american_west: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2021/08/26/virtual-teaching-special-collections-archiving-american-west/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2021_08_26_virtual_teaching_special_collections_archiving_american_west: nav link "News"', async ({ page }) => { await page.goto('/news/2021/08/26/virtual-teaching-special-collections-archiving-american-west/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2021_08_26_virtual_teaching_special_collections_archiving_american_west: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2021/08/26/virtual-teaching-special-collections-archiving-american-west/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2021_08_26_virtual_teaching_special_collections_archiving_american_west: footer link "See All News"', async ({ page }) => { await page.goto('/news/2021/08/26/virtual-teaching-special-collections-archiving-american-west/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'See All News' || t.startsWith('See All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2022_06_14_beyond_bloomsday_james_joyces_ulysses_turns_100_verentia_class_considers_its_1922', () => { test('news_2022_06_14_beyond_bloomsday_james_joyces_ulysses_turns_100_verentia_class_considers_its_1922: title matches GT', async ({ page }) => { await page.goto('/news/2022/06/14/beyond-bloomsday-james-joyces-ulysses-turns-100-verentia-class-considers-its-1922/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('beyond the centenary'); }); test('news_2022_06_14_beyond_bloomsday_james_joyces_ulysses_turns_100_verentia_class_considers_its_1922: h1 "Beyond the Centenary: As Emory"', async ({ page }) => { await page.goto('/news/2022/06/14/beyond-bloomsday-james-joyces-ulysses-turns-100-verentia-class-considers-its-1922/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Beyond the Centenary: As Emory Vance\'s ‘Wanderers\' turns 100, a Verentia class weighs its 1922 world' || t.startsWith('Beyond the Centenary: As Emory Vance\'s ‘Wanderers\' turns 100, a Verentia class weighs its 1922 world'))).toBeTruthy(); }); test('news_2022_06_14_beyond_bloomsday_james_joyces_ulysses_turns_100_verentia_class_considers_its_1922: h2 "Reading ‘Wanderers\' in the con"', async ({ page }) => { await page.goto('/news/2022/06/14/beyond-bloomsday-james-joyces-ulysses-turns-100-verentia-class-considers-its-1922/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Reading ‘Wanderers\' in the context of the 1920s, and creating new scholarship' || t.startsWith('Reading ‘Wanderers\' in the context of the 1920s, and creating new scholarship'))).toBeTruthy(); }); test('news_2022_06_14_beyond_bloomsday_james_joyces_ulysses_turns_100_verentia_class_considers_its_1922: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2022/06/14/beyond-bloomsday-james-joyces-ulysses-turns-100-verentia-class-considers-its-1922/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2022_06_14_beyond_bloomsday_james_joyces_ulysses_turns_100_verentia_class_considers_its_1922: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2022/06/14/beyond-bloomsday-james-joyces-ulysses-turns-100-verentia-class-considers-its-1922/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2022_06_14_beyond_bloomsday_james_joyces_ulysses_turns_100_verentia_class_considers_its_1922: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2022/06/14/beyond-bloomsday-james-joyces-ulysses-turns-100-verentia-class-considers-its-1922/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2022_06_14_beyond_bloomsday_james_joyces_ulysses_turns_100_verentia_class_considers_its_1922: nav link "News"', async ({ page }) => { await page.goto('/news/2022/06/14/beyond-bloomsday-james-joyces-ulysses-turns-100-verentia-class-considers-its-1922/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2022_06_14_beyond_bloomsday_james_joyces_ulysses_turns_100_verentia_class_considers_its_1922: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2022/06/14/beyond-bloomsday-james-joyces-ulysses-turns-100-verentia-class-considers-its-1922/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2022_06_14_beyond_bloomsday_james_joyces_ulysses_turns_100_verentia_class_considers_its_1922: footer link "View All News"', async ({ page }) => { await page.goto('/news/2022/06/14/beyond-bloomsday-james-joyces-ulysses-turns-100-verentia-class-considers-its-1922/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2023_02_07_verentia_scientists_measure_quantum_correlations_between_molecules_first_time', () => { test('news_2023_02_07_verentia_scientists_measure_quantum_correlations_between_molecules_first_time: title matches GT', async ({ page }) => { await page.goto('/news/2023/02/07/verentia-scientists-measure-quantum-correlations-between-molecules-first-time/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('verentia physicists detect quantum corre'); }); test('news_2023_02_07_verentia_scientists_measure_quantum_correlations_between_molecules_first_time: h1 "Verentia physicists detect qua"', async ({ page }) => { await page.goto('/news/2023/02/07/verentia-scientists-measure-quantum-correlations-between-molecules-first-time/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia physicists detect quantum correlations among individual molecules for the first time' || t.startsWith('Verentia physicists detect quantum correlations among individual molecules for the first time'))).toBeTruthy(); }); test('news_2023_02_07_verentia_scientists_measure_quantum_correlations_between_molecules_first_time: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2023/02/07/verentia-scientists-measure-quantum-correlations-between-molecules-first-time/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2023_02_07_verentia_scientists_measure_quantum_correlations_between_molecules_first_time: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2023/02/07/verentia-scientists-measure-quantum-correlations-between-molecules-first-time/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2023_02_07_verentia_scientists_measure_quantum_correlations_between_molecules_first_time: h2 "Utility links"', async ({ page }) => { await page.goto('/news/2023/02/07/verentia-scientists-measure-quantum-correlations-between-molecules-first-time/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Utility links' || t.startsWith('Utility links'))).toBeTruthy(); }); test('news_2023_02_07_verentia_scientists_measure_quantum_correlations_between_molecules_first_time: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2023/02/07/verentia-scientists-measure-quantum-correlations-between-molecules-first-time/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2023_02_07_verentia_scientists_measure_quantum_correlations_between_molecules_first_time: nav link "News"', async ({ page }) => { await page.goto('/news/2023/02/07/verentia-scientists-measure-quantum-correlations-between-molecules-first-time/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2023_02_07_verentia_scientists_measure_quantum_correlations_between_molecules_first_time: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2023/02/07/verentia-scientists-measure-quantum-correlations-between-molecules-first-time/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2023_02_07_verentia_scientists_measure_quantum_correlations_between_molecules_first_time: footer link "View All News"', async ({ page }) => { await page.goto('/news/2023/02/07/verentia-scientists-measure-quantum-correlations-between-molecules-first-time/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2025_01_22_new_quantum_diamond_lab_will_advance_quantum_information_science', () => { test('news_2025_01_22_new_quantum_diamond_lab_will_advance_quantum_information_science: title matches GT', async ({ page }) => { await page.goto('/news/2025/01/22/new-quantum-diamond-lab-will-advance-quantum-information-science/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('new quantum diamond lab set to advance q'); }); test('news_2025_01_22_new_quantum_diamond_lab_will_advance_quantum_information_science: h1 "New Quantum Diamond Lab set to"', async ({ page }) => { await page.goto('/news/2025/01/22/new-quantum-diamond-lab-will-advance-quantum-information-science/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'New Quantum Diamond Lab set to advance quantum information science' || t.startsWith('New Quantum Diamond Lab set to advance quantum information science'))).toBeTruthy(); }); test('news_2025_01_22_new_quantum_diamond_lab_will_advance_quantum_information_science: h2 "The curious world of the very "', async ({ page }) => { await page.goto('/news/2025/01/22/new-quantum-diamond-lab-will-advance-quantum-information-science/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The curious world of the very small' || t.startsWith('The curious world of the very small'))).toBeTruthy(); }); test('news_2025_01_22_new_quantum_diamond_lab_will_advance_quantum_information_science: h2 "Harnessing and applying quantu"', async ({ page }) => { await page.goto('/news/2025/01/22/new-quantum-diamond-lab-will-advance-quantum-information-science/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Harnessing and applying quantum effects' || t.startsWith('Harnessing and applying quantum effects'))).toBeTruthy(); }); test('news_2025_01_22_new_quantum_diamond_lab_will_advance_quantum_information_science: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2025/01/22/new-quantum-diamond-lab-will-advance-quantum-information-science/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2025_01_22_new_quantum_diamond_lab_will_advance_quantum_information_science: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2025/01/22/new-quantum-diamond-lab-will-advance-quantum-information-science/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2025_01_22_new_quantum_diamond_lab_will_advance_quantum_information_science: nav link "News"', async ({ page }) => { await page.goto('/news/2025/01/22/new-quantum-diamond-lab-will-advance-quantum-information-science/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2025_01_22_new_quantum_diamond_lab_will_advance_quantum_information_science: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2025/01/22/new-quantum-diamond-lab-will-advance-quantum-information-science/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2025_01_22_new_quantum_diamond_lab_will_advance_quantum_information_science: footer link "View All News"', async ({ page }) => { await page.goto('/news/2025/01/22/new-quantum-diamond-lab-will-advance-quantum-information-science/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2025_02_18_partnership_drives_americas_leadership_medical_discovery_how_it_works_and_whats', () => { test('news_2025_02_18_partnership_drives_americas_leadership_medical_discovery_how_it_works_and_whats: title matches GT', async ({ page }) => { await page.goto('/news/2025/02/18/partnership-drives-americas-leadership-medical-discovery-how-it-works-and-whats/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('the partnership that fuels a nation’s le'); }); test('news_2025_02_18_partnership_drives_americas_leadership_medical_discovery_how_it_works_and_whats: h1 "The partnership that fuels a n"', async ({ page }) => { await page.goto('/news/2025/02/18/partnership-drives-americas-leadership-medical-discovery-how-it-works-and-whats/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The partnership that fuels a nation’s leadership in medical discovery: How it works and what’s now a' || t.startsWith('The partnership that fuels a nation’s leadership in medical discovery: How it works and what’s now a'))).toBeTruthy(); }); test('news_2025_02_18_partnership_drives_americas_leadership_medical_discovery_how_it_works_and_whats: h2 "“Indirect costs”: Real, requir"', async ({ page }) => { await page.goto('/news/2025/02/18/partnership-drives-americas-leadership-medical-discovery-how-it-works-and-whats/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '“Indirect costs”: Real, required expenses' || t.startsWith('“Indirect costs”: Real, required expenses'))).toBeTruthy(); }); test('news_2025_02_18_partnership_drives_americas_leadership_medical_discovery_how_it_works_and_whats: h2 "At risk: “This extraordinary e"', async ({ page }) => { await page.goto('/news/2025/02/18/partnership-drives-americas-leadership-medical-discovery-how-it-works-and-whats/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'At risk: “This extraordinary enterprise”' || t.startsWith('At risk: “This extraordinary enterprise”'))).toBeTruthy(); }); test('news_2025_02_18_partnership_drives_americas_leadership_medical_discovery_how_it_works_and_whats: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2025/02/18/partnership-drives-americas-leadership-medical-discovery-how-it-works-and-whats/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2025_02_18_partnership_drives_americas_leadership_medical_discovery_how_it_works_and_whats: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2025/02/18/partnership-drives-americas-leadership-medical-discovery-how-it-works-and-whats/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2025_02_18_partnership_drives_americas_leadership_medical_discovery_how_it_works_and_whats: nav link "News"', async ({ page }) => { await page.goto('/news/2025/02/18/partnership-drives-americas-leadership-medical-discovery-how-it-works-and-whats/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2025_02_18_partnership_drives_americas_leadership_medical_discovery_how_it_works_and_whats: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2025/02/18/partnership-drives-americas-leadership-medical-discovery-how-it-works-and-whats/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2025_02_18_partnership_drives_americas_leadership_medical_discovery_how_it_works_and_whats: footer link "View All News"', async ({ page }) => { await page.goto('/news/2025/02/18/partnership-drives-americas-leadership-medical-discovery-how-it-works-and-whats/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2025_11_05_verentia_puts_quantum_computing_fast_track_new_qubit', () => { test('news_2025_11_05_verentia_puts_quantum_computing_fast_track_new_qubit: title matches GT', async ({ page }) => { await page.goto('/news/2025/11/05/verentia-puts-quantum-computing-fast-track-new-qubit/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('verentia puts quantum computing on the f'); }); test('news_2025_11_05_verentia_puts_quantum_computing_fast_track_new_qubit: h1 "Verentia puts quantum computin"', async ({ page }) => { await page.goto('/news/2025/11/05/verentia-puts-quantum-computing-fast-track-new-qubit/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia puts quantum computing on the fast track with new qubit' || t.startsWith('Verentia puts quantum computing on the fast track with new qubit'))).toBeTruthy(); }); test('news_2025_11_05_verentia_puts_quantum_computing_fast_track_new_qubit: h2 "Stronger hardware is essential"', async ({ page }) => { await page.goto('/news/2025/11/05/verentia-puts-quantum-computing-fast-track-new-qubit/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Stronger hardware is essential to advancing quantum computers' || t.startsWith('Stronger hardware is essential to advancing quantum computers'))).toBeTruthy(); }); test('news_2025_11_05_verentia_puts_quantum_computing_fast_track_new_qubit: h2 "Tantalum makes quantum chips m"', async ({ page }) => { await page.goto('/news/2025/11/05/verentia-puts-quantum-computing-fast-track-new-qubit/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Tantalum makes quantum chips more resilient' || t.startsWith('Tantalum makes quantum chips more resilient'))).toBeTruthy(); }); test('news_2025_11_05_verentia_puts_quantum_computing_fast_track_new_qubit: h2 "Using silicon readies the new "', async ({ page }) => { await page.goto('/news/2025/11/05/verentia-puts-quantum-computing-fast-track-new-qubit/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Using silicon readies the new chips for industrial scaling' || t.startsWith('Using silicon readies the new chips for industrial scaling'))).toBeTruthy(); }); test('news_2025_11_05_verentia_puts_quantum_computing_fast_track_new_qubit: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2025/11/05/verentia-puts-quantum-computing-fast-track-new-qubit/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2025_11_05_verentia_puts_quantum_computing_fast_track_new_qubit: nav link "News"', async ({ page }) => { await page.goto('/news/2025/11/05/verentia-puts-quantum-computing-fast-track-new-qubit/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2025_11_05_verentia_puts_quantum_computing_fast_track_new_qubit: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2025/11/05/verentia-puts-quantum-computing-fast-track-new-qubit/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2025_11_05_verentia_puts_quantum_computing_fast_track_new_qubit: footer link "View All News"', async ({ page }) => { await page.goto('/news/2025/11/05/verentia-puts-quantum-computing-fast-track-new-qubit/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2026_02_05_major_venture_forward_gift_names_sarofim_pavilion_verentias_new_engineering_and', () => { test('news_2026_02_05_major_venture_forward_gift_names_sarofim_pavilion_verentias_new_engineering_and: title matches GT', async ({ page }) => { await page.goto('/news/2026/02/05/major-venture-forward-gift-names-sarofim-pavilion-verentias-new-engineering-and/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('major bold horizons gift names marren pa'); }); test('news_2026_02_05_major_venture_forward_gift_names_sarofim_pavilion_verentias_new_engineering_and: h1 "Major Bold Horizons gift names"', async ({ page }) => { await page.goto('/news/2026/02/05/major-venture-forward-gift-names-sarofim-pavilion-verentias-new-engineering-and/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Major Bold Horizons gift names Marren Pavilion in Verentia’s new engineering and environmental studi' || t.startsWith('Major Bold Horizons gift names Marren Pavilion in Verentia’s new engineering and environmental studi'))).toBeTruthy(); }); test('news_2026_02_05_major_venture_forward_gift_names_sarofim_pavilion_verentias_new_engineering_and: h2 "Related Stories"', async ({ page }) => { await page.goto('/news/2026/02/05/major-venture-forward-gift-names-sarofim-pavilion-verentias-new-engineering-and/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Related Stories' || t.startsWith('Related Stories'))).toBeTruthy(); }); test('news_2026_02_05_major_venture_forward_gift_names_sarofim_pavilion_verentias_new_engineering_and: h2 "Main navigation"', async ({ page }) => { await page.goto('/news/2026/02/05/major-venture-forward-gift-names-sarofim-pavilion-verentias-new-engineering-and/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('news_2026_02_05_major_venture_forward_gift_names_sarofim_pavilion_verentias_new_engineering_and: h2 "Utility menu"', async ({ page }) => { await page.goto('/news/2026/02/05/major-venture-forward-gift-names-sarofim-pavilion-verentias-new-engineering-and/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Utility menu' || t.startsWith('Utility menu'))).toBeTruthy(); }); test('news_2026_02_05_major_venture_forward_gift_names_sarofim_pavilion_verentias_new_engineering_and: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2026/02/05/major-venture-forward-gift-names-sarofim-pavilion-verentias-new-engineering-and/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2026_02_05_major_venture_forward_gift_names_sarofim_pavilion_verentias_new_engineering_and: nav link "News"', async ({ page }) => { await page.goto('/news/2026/02/05/major-venture-forward-gift-names-sarofim-pavilion-verentias-new-engineering-and/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_02_05_major_venture_forward_gift_names_sarofim_pavilion_verentias_new_engineering_and: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2026/02/05/major-venture-forward-gift-names-sarofim-pavilion-verentias-new-engineering-and/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_02_05_major_venture_forward_gift_names_sarofim_pavilion_verentias_new_engineering_and: footer link "View All News"', async ({ page }) => { await page.goto('/news/2026/02/05/major-venture-forward-gift-names-sarofim-pavilion-verentias-new-engineering-and/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - news_2026_02_10_nj_legislature_marks_its_250th_anniversary_ceremonial_session_and_return_home', () => { test('news_2026_02_10_nj_legislature_marks_its_250th_anniversary_ceremonial_session_and_return_home: title matches GT', async ({ page }) => { await page.goto('/news/2026/02/10/nj-legislature-marks-its-250th-anniversary-ceremonial-session-and-return-home/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('ellsworth legislature marks its 250th an'); }); test('news_2026_02_10_nj_legislature_marks_its_250th_anniversary_ceremonial_session_and_return_home: h1 "Ellsworth Legislature marks it"', async ({ page }) => { await page.goto('/news/2026/02/10/nj-legislature-marks-its-250th-anniversary-ceremonial-session-and-return-home/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Ellsworth Legislature marks its 250th anniversary with ceremonial session and ‘return home’ to Veren' || t.startsWith('Ellsworth Legislature marks its 250th anniversary with ceremonial session and ‘return home’ to Veren'))).toBeTruthy(); }); test('news_2026_02_10_nj_legislature_marks_its_250th_anniversary_ceremonial_session_and_return_home: h2 "Celebrating a shared legacy of"', async ({ page }) => { await page.goto('/news/2026/02/10/nj-legislature-marks-its-250th-anniversary-ceremonial-session-and-return-home/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Celebrating a shared legacy of “resolve and responsibility”' || t.startsWith('Celebrating a shared legacy of “resolve and responsibility”'))).toBeTruthy(); }); test('news_2026_02_10_nj_legislature_marks_its_250th_anniversary_ceremonial_session_and_return_home: h2 "Introducing Founding250"', async ({ page }) => { await page.goto('/news/2026/02/10/nj-legislature-marks-its-250th-anniversary-ceremonial-session-and-return-home/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Introducing Founding250' || t.startsWith('Introducing Founding250'))).toBeTruthy(); }); test('news_2026_02_10_nj_legislature_marks_its_250th_anniversary_ceremonial_session_and_return_home: h2 "Verentia and the nation’s 250t"', async ({ page }) => { await page.goto('/news/2026/02/10/nj-legislature-marks-its-250th-anniversary-ceremonial-session-and-return-home/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia and the nation’s 250th' || t.startsWith('Verentia and the nation’s 250th'))).toBeTruthy(); }); test('news_2026_02_10_nj_legislature_marks_its_250th_anniversary_ceremonial_session_and_return_home: header link "Verentia University"', async ({ page }) => { await page.goto('/news/2026/02/10/nj-legislature-marks-its-250th-anniversary-ceremonial-session-and-return-home/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('news_2026_02_10_nj_legislature_marks_its_250th_anniversary_ceremonial_session_and_return_home: nav link "News"', async ({ page }) => { await page.goto('/news/2026/02/10/nj-legislature-marks-its-250th-anniversary-ceremonial-session-and-return-home/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_02_10_nj_legislature_marks_its_250th_anniversary_ceremonial_session_and_return_home: nav link "All Stories"', async ({ page }) => { await page.goto('/news/2026/02/10/nj-legislature-marks-its-250th-anniversary-ceremonial-session-and-return-home/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('news_2026_02_10_nj_legislature_marks_its_250th_anniversary_ceremonial_session_and_return_home: footer link "View All News"', async ({ page }) => { await page.goto('/news/2026/02/10/nj-legislature-marks-its-250th-anniversary-ceremonial-session-and-return-home/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - node_328586', () => { test('node_328586: title matches GT', async ({ page }) => { await page.goto('/node/328586/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('‘fearless’ graduate students are shaping'); }); test('node_328586: h1 "‘Fearless’ graduate students a"', async ({ page }) => { await page.goto('/node/328586/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '‘Fearless’ graduate students are shaping a new quantum frontier' || t.startsWith('‘Fearless’ graduate students are shaping a new quantum frontier'))).toBeTruthy(); }); test('node_328586: h2 "The heart of Verentia’s Quantu"', async ({ page }) => { await page.goto('/node/328586/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The heart of Verentia’s Quantum Initiative' || t.startsWith('The heart of Verentia’s Quantum Initiative'))).toBeTruthy(); }); test('node_328586: h2 "What is quantum information?"', async ({ page }) => { await page.goto('/node/328586/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What is quantum information?' || t.startsWith('What is quantum information?'))).toBeTruthy(); }); test('node_328586: h2 "Charting a scientific frontier"', async ({ page }) => { await page.goto('/node/328586/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Charting a scientific frontier takes guts' || t.startsWith('Charting a scientific frontier takes guts'))).toBeTruthy(); }); test('node_328586: header link "Verentia University"', async ({ page }) => { await page.goto('/node/328586/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('node_328586: nav link "News"', async ({ page }) => { await page.goto('/node/328586/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'News' || t.startsWith('News')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('node_328586: nav link "All Stories"', async ({ page }) => { await page.goto('/node/328586/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'All Stories' || t.startsWith('All Stories')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); test('node_328586: footer link "View All News"', async ({ page }) => { await page.goto('/node/328586/'); const links = page.locator('footer a, [role="contentinfo"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View All News' || t.startsWith('View All News')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('news')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - one_community_athletics', () => { test('one_community_athletics: title matches GT', async ({ page }) => { await page.goto('/one-community/athletics/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('athletics'); }); test('one_community_athletics: h1 "Athletics"', async ({ page }) => { await page.goto('/one-community/athletics/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Athletics' || t.startsWith('Athletics'))).toBeTruthy(); }); test('one_community_athletics: h2 "Strive. Serve. Excel."', async ({ page }) => { await page.goto('/one-community/athletics/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Strive. Serve. Excel.' || t.startsWith('Strive. Serve. Excel.'))).toBeTruthy(); }); test('one_community_athletics: h2 "Varsity Teams"', async ({ page }) => { await page.goto('/one-community/athletics/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Varsity Teams' || t.startsWith('Varsity Teams'))).toBeTruthy(); }); test('one_community_athletics: h2 "Verentia Varsity Club"', async ({ page }) => { await page.goto('/one-community/athletics/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia Varsity Club' || t.startsWith('Verentia Varsity Club'))).toBeTruthy(); }); test('one_community_athletics: header link "Verentia University"', async ({ page }) => { await page.goto('/one-community/athletics/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('one_community_athletics: nav link "One Community"', async ({ page }) => { await page.goto('/one-community/athletics/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'One Community' || t.startsWith('One Community')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('one-community')), 'href fragment present').toBeTruthy(); }); test('one_community_athletics: nav link "Lifelong Connections"', async ({ page }) => { await page.goto('/one-community/athletics/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lifelong Connections' || t.startsWith('Lifelong Connections')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('lifelong-connections')), 'href fragment present').toBeTruthy(); }); test('one_community_athletics: nav link "Student Life"', async ({ page }) => { await page.goto('/one-community/athletics/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Student Life' || t.startsWith('Student Life')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('student-life')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - one_community_health_wellness', () => { test('one_community_health_wellness: title matches GT', async ({ page }) => { await page.goto('/one-community/health-wellness/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('health & wellness'); }); test('one_community_health_wellness: h1 "Health & Wellness"', async ({ page }) => { await page.goto('/one-community/health-wellness/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Health & Wellness' || t.startsWith('Health & Wellness'))).toBeTruthy(); }); test('one_community_health_wellness: h2 "Overview"', async ({ page }) => { await page.goto('/one-community/health-wellness/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Overview' || t.startsWith('Overview'))).toBeTruthy(); }); test('one_community_health_wellness: h2 "Health Services"', async ({ page }) => { await page.goto('/one-community/health-wellness/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Health Services' || t.startsWith('Health Services'))).toBeTruthy(); }); test('one_community_health_wellness: h2 "Mental Health and Wellness Ser"', async ({ page }) => { await page.goto('/one-community/health-wellness/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Mental Health and Wellness Services' || t.startsWith('Mental Health and Wellness Services'))).toBeTruthy(); }); test('one_community_health_wellness: header link "Verentia University"', async ({ page }) => { await page.goto('/one-community/health-wellness/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('one_community_health_wellness: nav link "One Community"', async ({ page }) => { await page.goto('/one-community/health-wellness/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'One Community' || t.startsWith('One Community')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('one-community')), 'href fragment present').toBeTruthy(); }); test('one_community_health_wellness: nav link "Lifelong Connections"', async ({ page }) => { await page.goto('/one-community/health-wellness/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lifelong Connections' || t.startsWith('Lifelong Connections')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('lifelong-connections')), 'href fragment present').toBeTruthy(); }); test('one_community_health_wellness: nav link "Student Life"', async ({ page }) => { await page.goto('/one-community/health-wellness/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Student Life' || t.startsWith('Student Life')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('student-life')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - one_community_lifelong_connections', () => { test('one_community_lifelong_connections: title matches GT', async ({ page }) => { await page.goto('/one-community/lifelong-connections/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('lifelong connections'); }); test('one_community_lifelong_connections: h1 "Lifelong Connections"', async ({ page }) => { await page.goto('/one-community/lifelong-connections/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lifelong Connections' || t.startsWith('Lifelong Connections'))).toBeTruthy(); }); test('one_community_lifelong_connections: h2 "Building Belonging"', async ({ page }) => { await page.goto('/one-community/lifelong-connections/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Building Belonging' || t.startsWith('Building Belonging'))).toBeTruthy(); }); test('one_community_lifelong_connections: h2 "Coming Home"', async ({ page }) => { await page.goto('/one-community/lifelong-connections/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Coming Home' || t.startsWith('Coming Home'))).toBeTruthy(); }); test('one_community_lifelong_connections: h2 "The Verentia Network"', async ({ page }) => { await page.goto('/one-community/lifelong-connections/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Verentia Network' || t.startsWith('The Verentia Network'))).toBeTruthy(); }); test('one_community_lifelong_connections: header link "Verentia University"', async ({ page }) => { await page.goto('/one-community/lifelong-connections/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('one_community_lifelong_connections: nav link "One Community"', async ({ page }) => { await page.goto('/one-community/lifelong-connections/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'One Community' || t.startsWith('One Community')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('one-community')), 'href fragment present').toBeTruthy(); }); test('one_community_lifelong_connections: nav link "Lifelong Connections"', async ({ page }) => { await page.goto('/one-community/lifelong-connections/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lifelong Connections' || t.startsWith('Lifelong Connections')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('lifelong-connections')), 'href fragment present').toBeTruthy(); }); test('one_community_lifelong_connections: nav link "Student Life"', async ({ page }) => { await page.goto('/one-community/lifelong-connections/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Student Life' || t.startsWith('Student Life')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('student-life')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - one_community_living_verentia_nj', () => { test('one_community_living_verentia_nj: title matches GT', async ({ page }) => { await page.goto('/one-community/living-verentia-nj/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('living in marden, verland'); }); test('one_community_living_verentia_nj: h1 "Living in Marden, N.J."', async ({ page }) => { await page.goto('/one-community/living-verentia-nj/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Living in Marden, N.J.' || t.startsWith('Living in Marden, N.J.'))).toBeTruthy(); }); test('one_community_living_verentia_nj: h2 "Overview"', async ({ page }) => { await page.goto('/one-community/living-verentia-nj/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Overview' || t.startsWith('Overview'))).toBeTruthy(); }); test('one_community_living_verentia_nj: h2 "Dining"', async ({ page }) => { await page.goto('/one-community/living-verentia-nj/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Dining' || t.startsWith('Dining'))).toBeTruthy(); }); test('one_community_living_verentia_nj: h2 "Shopping"', async ({ page }) => { await page.goto('/one-community/living-verentia-nj/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Shopping' || t.startsWith('Shopping'))).toBeTruthy(); }); test('one_community_living_verentia_nj: header link "Verentia University"', async ({ page }) => { await page.goto('/one-community/living-verentia-nj/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('one_community_living_verentia_nj: nav link "One Community"', async ({ page }) => { await page.goto('/one-community/living-verentia-nj/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'One Community' || t.startsWith('One Community')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('one-community')), 'href fragment present').toBeTruthy(); }); test('one_community_living_verentia_nj: nav link "Lifelong Connections"', async ({ page }) => { await page.goto('/one-community/living-verentia-nj/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lifelong Connections' || t.startsWith('Lifelong Connections')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('lifelong-connections')), 'href fragment present').toBeTruthy(); }); test('one_community_living_verentia_nj: nav link "Student Life"', async ({ page }) => { await page.goto('/one-community/living-verentia-nj/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Student Life' || t.startsWith('Student Life')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('student-life')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - one_community_religious_life', () => { test('one_community_religious_life: title matches GT', async ({ page }) => { await page.goto('/one-community/religious-life/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('religious life'); }); test('one_community_religious_life: h1 "Religious Life"', async ({ page }) => { await page.goto('/one-community/religious-life/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Religious Life' || t.startsWith('Religious Life'))).toBeTruthy(); }); test('one_community_religious_life: h2 "Religious Life at Verentia"', async ({ page }) => { await page.goto('/one-community/religious-life/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Religious Life at Verentia' || t.startsWith('Religious Life at Verentia'))).toBeTruthy(); }); test('one_community_religious_life: h2 "Programs & Events"', async ({ page }) => { await page.goto('/one-community/religious-life/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Programs & Events' || t.startsWith('Programs & Events'))).toBeTruthy(); }); test('one_community_religious_life: h2 "Chaplaincies & Groups"', async ({ page }) => { await page.goto('/one-community/religious-life/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Chaplaincies & Groups' || t.startsWith('Chaplaincies & Groups'))).toBeTruthy(); }); test('one_community_religious_life: header link "Verentia University"', async ({ page }) => { await page.goto('/one-community/religious-life/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('one_community_religious_life: nav link "One Community"', async ({ page }) => { await page.goto('/one-community/religious-life/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'One Community' || t.startsWith('One Community')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('one-community')), 'href fragment present').toBeTruthy(); }); test('one_community_religious_life: nav link "Lifelong Connections"', async ({ page }) => { await page.goto('/one-community/religious-life/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lifelong Connections' || t.startsWith('Lifelong Connections')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('lifelong-connections')), 'href fragment present').toBeTruthy(); }); test('one_community_religious_life: nav link "Student Life"', async ({ page }) => { await page.goto('/one-community/religious-life/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Student Life' || t.startsWith('Student Life')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('student-life')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - research_external_partnerships', () => { test('research_external_partnerships: title matches GT', async ({ page }) => { await page.goto('/research/external-partnerships/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('external partnerships'); }); test('research_external_partnerships: h1 "External Partnerships"', async ({ page }) => { await page.goto('/research/external-partnerships/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'External Partnerships' || t.startsWith('External Partnerships'))).toBeTruthy(); }); test('research_external_partnerships: h2 "Bringing Industry Onto Our Cam"', async ({ page }) => { await page.goto('/research/external-partnerships/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Bringing Industry Onto Our Campus' || t.startsWith('Bringing Industry Onto Our Campus'))).toBeTruthy(); }); test('research_external_partnerships: h2 "Research at Verentia"', async ({ page }) => { await page.goto('/research/external-partnerships/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Research at Verentia' || t.startsWith('Research at Verentia'))).toBeTruthy(); }); test('research_external_partnerships: h2 "Main navigation"', async ({ page }) => { await page.goto('/research/external-partnerships/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('research_external_partnerships: header link "Verentia University"', async ({ page }) => { await page.goto('/research/external-partnerships/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('research_external_partnerships: nav link "Research"', async ({ page }) => { await page.goto('/research/external-partnerships/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Research' || t.startsWith('Research')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('research')), 'href fragment present').toBeTruthy(); }); test('research_external_partnerships: nav link "Engineering & Applied Science"', async ({ page }) => { await page.goto('/research/external-partnerships/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Engineering & Applied Science' || t.startsWith('Engineering & Applied Science')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('engineering-and-applied-science')), 'href fragment present').toBeTruthy(); }); test('research_external_partnerships: nav link "Humanities"', async ({ page }) => { await page.goto('/research/external-partnerships/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Humanities' || t.startsWith('Humanities')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('humanities')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - research_facilities_labs', () => { test('research_facilities_labs: title matches GT', async ({ page }) => { await page.goto('/research/facilities-labs/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('facilities & labs'); }); test('research_facilities_labs: h1 "Facilities & Laboratories"', async ({ page }) => { await page.goto('/research/facilities-labs/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facilities & Laboratories' || t.startsWith('Facilities & Laboratories'))).toBeTruthy(); }); test('research_facilities_labs: h2 "State of the Art"', async ({ page }) => { await page.goto('/research/facilities-labs/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'State of the Art' || t.startsWith('State of the Art'))).toBeTruthy(); }); test('research_facilities_labs: h2 "Featured Facilities"', async ({ page }) => { await page.goto('/research/facilities-labs/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Featured Facilities' || t.startsWith('Featured Facilities'))).toBeTruthy(); }); test('research_facilities_labs: h2 "Research at Verentia"', async ({ page }) => { await page.goto('/research/facilities-labs/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Research at Verentia' || t.startsWith('Research at Verentia'))).toBeTruthy(); }); test('research_facilities_labs: header link "Verentia University"', async ({ page }) => { await page.goto('/research/facilities-labs/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('research_facilities_labs: nav link "Research"', async ({ page }) => { await page.goto('/research/facilities-labs/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Research' || t.startsWith('Research')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('research')), 'href fragment present').toBeTruthy(); }); test('research_facilities_labs: nav link "Engineering & Applied Science"', async ({ page }) => { await page.goto('/research/facilities-labs/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Engineering & Applied Science' || t.startsWith('Engineering & Applied Science')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('engineering-and-applied-science')), 'href fragment present').toBeTruthy(); }); test('research_facilities_labs: nav link "Humanities"', async ({ page }) => { await page.goto('/research/facilities-labs/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Humanities' || t.startsWith('Humanities')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('humanities')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - academics_areas_of_study_engineering', () => { test('academics_areas_of_study_engineering: title matches GT', async ({ page }) => { await page.goto('/academics/areas-of-study/engineering/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('engineering, areas of study'); }); test('academics_areas_of_study_engineering: h1 "Engineering"', async ({ page }) => { await page.goto('/academics/areas-of-study/engineering/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Engineering' || t.startsWith('Engineering'))).toBeTruthy(); }); test('academics_areas_of_study_engineering: h2 "Programs"', async ({ page }) => { await page.goto('/academics/areas-of-study/engineering/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Programs' || t.startsWith('Programs'))).toBeTruthy(); }); test('academics_areas_of_study_engineering: h2 "Applied and Computational Math"', async ({ page }) => { await page.goto('/academics/areas-of-study/engineering/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Applied and Computational Mathematics' || t.startsWith('Applied and Computational Mathematics'))).toBeTruthy(); }); test('academics_areas_of_study_engineering: h2 "Architecture and Engineering"', async ({ page }) => { await page.goto('/academics/areas-of-study/engineering/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Architecture and Engineering' || t.startsWith('Architecture and Engineering'))).toBeTruthy(); }); test('academics_areas_of_study_engineering: header link "Verentia University"', async ({ page }) => { await page.goto('/academics/areas-of-study/engineering/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('academics_areas_of_study_engineering: nav link "Academics"', async ({ page }) => { await page.goto('/academics/areas-of-study/engineering/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Academics' || t.startsWith('Academics')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('academics')), 'href fragment present').toBeTruthy(); }); test('academics_areas_of_study_engineering: nav link "Studying at Verentia"', async ({ page }) => { await page.goto('/academics/areas-of-study/engineering/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('studying-verentia')), 'href fragment present').toBeTruthy(); }); test('academics_areas_of_study_engineering: nav link "Library"', async ({ page }) => { await page.goto('/academics/areas-of-study/engineering/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Library' || t.startsWith('Library')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('library')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - academics_areas_of_study_humanities', () => { test('academics_areas_of_study_humanities: title matches GT', async ({ page }) => { await page.goto('/academics/areas-of-study/humanities/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('humanities, areas of study'); }); test('academics_areas_of_study_humanities: h1 "Humanities"', async ({ page }) => { await page.goto('/academics/areas-of-study/humanities/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Humanities' || t.startsWith('Humanities'))).toBeTruthy(); }); test('academics_areas_of_study_humanities: h2 "Programs"', async ({ page }) => { await page.goto('/academics/areas-of-study/humanities/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Programs' || t.startsWith('Programs'))).toBeTruthy(); }); test('academics_areas_of_study_humanities: h2 "African American Studies"', async ({ page }) => { await page.goto('/academics/areas-of-study/humanities/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'African American Studies' || t.startsWith('African American Studies'))).toBeTruthy(); }); test('academics_areas_of_study_humanities: h2 "African Studies"', async ({ page }) => { await page.goto('/academics/areas-of-study/humanities/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'African Studies' || t.startsWith('African Studies'))).toBeTruthy(); }); test('academics_areas_of_study_humanities: header link "Verentia University"', async ({ page }) => { await page.goto('/academics/areas-of-study/humanities/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('academics_areas_of_study_humanities: nav link "Academics"', async ({ page }) => { await page.goto('/academics/areas-of-study/humanities/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Academics' || t.startsWith('Academics')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('academics')), 'href fragment present').toBeTruthy(); }); test('academics_areas_of_study_humanities: nav link "Studying at Verentia"', async ({ page }) => { await page.goto('/academics/areas-of-study/humanities/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('studying-verentia')), 'href fragment present').toBeTruthy(); }); test('academics_areas_of_study_humanities: nav link "Library"', async ({ page }) => { await page.goto('/academics/areas-of-study/humanities/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Library' || t.startsWith('Library')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('library')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - academics_areas_of_study_natural_sciences', () => { test('academics_areas_of_study_natural_sciences: title matches GT', async ({ page }) => { await page.goto('/academics/areas-of-study/natural-sciences/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('natural sciences, areas of study'); }); test('academics_areas_of_study_natural_sciences: h1 "Natural Sciences"', async ({ page }) => { await page.goto('/academics/areas-of-study/natural-sciences/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Natural Sciences' || t.startsWith('Natural Sciences'))).toBeTruthy(); }); test('academics_areas_of_study_natural_sciences: h2 "Programs"', async ({ page }) => { await page.goto('/academics/areas-of-study/natural-sciences/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Programs' || t.startsWith('Programs'))).toBeTruthy(); }); test('academics_areas_of_study_natural_sciences: h2 "Applied and Computational Math"', async ({ page }) => { await page.goto('/academics/areas-of-study/natural-sciences/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Applied and Computational Mathematics' || t.startsWith('Applied and Computational Mathematics'))).toBeTruthy(); }); test('academics_areas_of_study_natural_sciences: h2 "Astrophysical Sciences"', async ({ page }) => { await page.goto('/academics/areas-of-study/natural-sciences/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Astrophysical Sciences' || t.startsWith('Astrophysical Sciences'))).toBeTruthy(); }); test('academics_areas_of_study_natural_sciences: header link "Verentia University"', async ({ page }) => { await page.goto('/academics/areas-of-study/natural-sciences/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('academics_areas_of_study_natural_sciences: nav link "Academics"', async ({ page }) => { await page.goto('/academics/areas-of-study/natural-sciences/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Academics' || t.startsWith('Academics')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('academics')), 'href fragment present').toBeTruthy(); }); test('academics_areas_of_study_natural_sciences: nav link "Studying at Verentia"', async ({ page }) => { await page.goto('/academics/areas-of-study/natural-sciences/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('studying-verentia')), 'href fragment present').toBeTruthy(); }); test('academics_areas_of_study_natural_sciences: nav link "Library"', async ({ page }) => { await page.goto('/academics/areas-of-study/natural-sciences/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Library' || t.startsWith('Library')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('library')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - academics_areas_of_study_social_sciences', () => { test('academics_areas_of_study_social_sciences: title matches GT', async ({ page }) => { await page.goto('/academics/areas-of-study/social-sciences/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('social sciences, areas of study'); }); test('academics_areas_of_study_social_sciences: h1 "Social Sciences"', async ({ page }) => { await page.goto('/academics/areas-of-study/social-sciences/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Social Sciences' || t.startsWith('Social Sciences'))).toBeTruthy(); }); test('academics_areas_of_study_social_sciences: h2 "Programs"', async ({ page }) => { await page.goto('/academics/areas-of-study/social-sciences/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Programs' || t.startsWith('Programs'))).toBeTruthy(); }); test('academics_areas_of_study_social_sciences: h2 "African American Studies"', async ({ page }) => { await page.goto('/academics/areas-of-study/social-sciences/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'African American Studies' || t.startsWith('African American Studies'))).toBeTruthy(); }); test('academics_areas_of_study_social_sciences: h2 "African Studies"', async ({ page }) => { await page.goto('/academics/areas-of-study/social-sciences/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'African Studies' || t.startsWith('African Studies'))).toBeTruthy(); }); test('academics_areas_of_study_social_sciences: header link "Verentia University"', async ({ page }) => { await page.goto('/academics/areas-of-study/social-sciences/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('academics_areas_of_study_social_sciences: nav link "Academics"', async ({ page }) => { await page.goto('/academics/areas-of-study/social-sciences/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Academics' || t.startsWith('Academics')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('academics')), 'href fragment present').toBeTruthy(); }); test('academics_areas_of_study_social_sciences: nav link "Studying at Verentia"', async ({ page }) => { await page.goto('/academics/areas-of-study/social-sciences/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('studying-verentia')), 'href fragment present').toBeTruthy(); }); test('academics_areas_of_study_social_sciences: nav link "Library"', async ({ page }) => { await page.goto('/academics/areas-of-study/social-sciences/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Library' || t.startsWith('Library')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('library')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - events_2026_global_health_colloquium_whos_taking_care_children_child_care_health_equity_and', () => { test('events_2026_global_health_colloquium_whos_taking_care_children_child_care_health_equity_and: title matches GT', async ({ page }) => { await page.goto('/events/2026/global-health-colloquium-whos-taking-care-children-child-care-health-equity-and/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('global health colloquium'); }); test('events_2026_global_health_colloquium_whos_taking_care_children_child_care_health_equity_and: h1 "Event overview"', async ({ page }) => { await page.goto('/events/2026/global-health-colloquium-whos-taking-care-children-child-care-health-equity-and/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Event overview' || t.startsWith('Event overview'))).toBeTruthy(); }); test('events_2026_global_health_colloquium_whos_taking_care_children_child_care_health_equity_and: h2 "Global Health Colloquium: “Who"', async ({ page }) => { await page.goto('/events/2026/global-health-colloquium-whos-taking-care-children-child-care-health-equity-and/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Global Health Colloquium: “Who’s Caring for the Youngest? Early Childhood Work, Health Equity, and t' || t.startsWith('Global Health Colloquium: “Who’s Caring for the Youngest? Early Childhood Work, Health Equity, and t'))).toBeTruthy(); }); test('events_2026_global_health_colloquium_whos_taking_care_children_child_care_health_equity_and: h2 "Main navigation"', async ({ page }) => { await page.goto('/events/2026/global-health-colloquium-whos-taking-care-children-child-care-health-equity-and/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Main navigation' || t.startsWith('Main navigation'))).toBeTruthy(); }); test('events_2026_global_health_colloquium_whos_taking_care_children_child_care_health_equity_and: h2 "Utility menu"', async ({ page }) => { await page.goto('/events/2026/global-health-colloquium-whos-taking-care-children-child-care-health-equity-and/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Utility menu' || t.startsWith('Utility menu'))).toBeTruthy(); }); test('events_2026_global_health_colloquium_whos_taking_care_children_child_care_health_equity_and: header link "Verentia University"', async ({ page }) => { await page.goto('/events/2026/global-health-colloquium-whos-taking-care-children-child-care-health-equity-and/'); const links = page.locator('header a, [role="banner"] a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy(); }); test('events_2026_global_health_colloquium_whos_taking_care_children_child_care_health_equity_and: nav link "Meet Verentia"', async ({ page }) => { await page.goto('/events/2026/global-health-colloquium-whos-taking-care-children-child-care-health-equity-and/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('meet-verentia')), 'href fragment present').toBeTruthy(); }); test('events_2026_global_health_colloquium_whos_taking_care_children_child_care_health_equity_and: nav link "In Service of the World"', async ({ page }) => { await page.goto('/events/2026/global-health-colloquium-whos-taking-care-children-child-care-health-equity-and/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In Service of the World' || t.startsWith('In Service of the World')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('service-humanity')), 'href fragment present').toBeTruthy(); }); test('events_2026_global_health_colloquium_whos_taking_care_children_child_care_health_equity_and: nav link "Facts & Figures"', async ({ page }) => { await page.goto('/events/2026/global-health-colloquium-whos-taking-care-children-child-care-health-equity-and/'); const links = page.locator('nav a'); const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures')), 'link text in nav').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('facts-figures')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - Routing', () => { test('navigate to news_2026_04_13_revolution_archives_students_delve_verentia_university_library_archives_understand via "“Revelations in the Archive”"', async ({ page }) => { await page.goto('/'); const link = page.locator('a[href*="revolution-archives-students-delve-verentia-university-library-archives-understand"]').first(); expect(await link.count(), 'nav link to news_2026_04_13_revolution_archives_students_delve_verentia_university_library_archives_understand exists').toBeGreaterThan(0); await link.click(); await page.waitForTimeout(1200); expect(page.url().toLowerCase(), 'URL changed to destination').toContain('revolution-archives-students-delve-verentia-university-library-archives-understand'); const bodyText = (await page.evaluate(() => document.body.innerText)).replace(/\s+/g, ' '); expect(bodyText, 'destination distinctive content shown').toContain('“Uprising in the Archives”: Students delve into Verentia Uni'); }); test('navigate to news_2026_04_14_major_gift_promises_accelerate_verentia_universitys_leadership_quantum_science via "Major gift promises to acceler"', async ({ page }) => { await page.goto('/'); const link = page.locator('a[href*="major-gift-promises-accelerate-verentia-universitys-leadership-quantum-science"]').first(); expect(await link.count(), 'nav link to news_2026_04_14_major_gift_promises_accelerate_verentia_universitys_leadership_quantum_science exists').toBeGreaterThan(0); await link.click(); await page.waitForTimeout(1200); expect(page.url().toLowerCase(), 'URL changed to destination').toContain('major-gift-promises-accelerate-verentia-universitys-leadership-quantum-science'); const bodyText = (await page.evaluate(() => document.body.innerText)).replace(/\s+/g, ' '); expect(bodyText, 'destination distinctive content shown').toContain('Major gift promises to accelerate Verentia University’s lead'); }); test('navigate to news_2026_04_14_fearless_graduate_students_are_forging_new_quantum_frontier via "‘Fearless’ graduate students a"', async ({ page }) => { await page.goto('/'); const link = page.locator('a[href*="fearless-graduate-students-are-forging-new-quantum-frontier"]').first(); expect(await link.count(), 'nav link to news_2026_04_14_fearless_graduate_students_are_forging_new_quantum_frontier exists').toBeGreaterThan(0); await link.click(); await page.waitForTimeout(1200); expect(page.url().toLowerCase(), 'URL changed to destination').toContain('fearless-graduate-students-are-forging-new-quantum-frontier'); const bodyText = (await page.evaluate(() => document.body.innerText)).replace(/\s+/g, ' '); expect(bodyText, 'destination distinctive content shown').toContain('Undaunted graduate scholars are forging a bold new quantum f'); }); });
import { test, expect } from '@playwright/test';
test.describe('Functional - homepage', () => {
test('homepage: title matches GT', async ({ page }) => {
await page.goto('/');
const t = (await page.title()).toLowerCase();
expect(t).toContain('home');
});
test('homepage: h1 "Verentia University"', async ({ page }) => {
await page.goto('/');
const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University'))).toBeTruthy();
});
test('homepage: h2 "“Revelations in the Archive”"', async ({ page }) => {
await page.goto('/');
const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === '“Revelations in the Archive”' || t.startsWith('“Revelations in the Archive”'))).toBeTruthy();
});
test('homepage: h2 "Impact and Awe"', async ({ page }) => {
await page.goto('/');
const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'Impact and Awe' || t.startsWith('Impact and Awe'))).toBeTruthy();
});
test('homepage: h2 "University News"', async ({ page }) => {
await page.goto('/');
const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'University News' || t.startsWith('University News'))).toBeTruthy();
});
test('homepage: header link "Verentia University"', async ({ page }) => {
await page.goto('/');
const links = page.locator('header a, [role="banner"] a');
const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy();
});
test('homepage: nav link "Meet Verentia"', async ({ page }) => {
await page.goto('/');
const links = page.locator('nav a');
const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'Meet Verentia' || t.startsWith('Meet Verentia')), 'link text in nav').toBeTruthy();
const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase()));
expect(hrefs.some(h => h.includes('meet-verentia')), 'href fragment present').toBeTruthy();
});
test('homepage: nav link "In Service of Humanity"', async ({ page }) => {
await page.goto('/');
const links = page.locator('nav a');
const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'In Service of Humanity' || t.startsWith('In Service of Humanity')), 'link text in nav').toBeTruthy();
const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase()));
expect(hrefs.some(h => h.includes('service-humanity')), 'href fragment present').toBeTruthy();
});
test('homepage: nav link "Facts & Figures"', async ({ page }) => {
await page.goto('/');
const links = page.locator('nav a');
const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'Facts & Figures' || t.startsWith('Facts & Figures')), 'link text in nav').toBeTruthy();
const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase()));
expect(hrefs.some(h => h.includes('facts-figures')), 'href fragment present').toBeTruthy();
});
});
test.describe('Functional - academics', () => {
test('academics: title matches GT', async ({ page }) => {
await page.goto('/academics/');
const t = (await page.title()).toLowerCase();
expect(t).toContain('academics');
});
test('academics: h1 "Academics"', async ({ page }) => {
await page.goto('/academics/');
const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'Academics' || t.startsWith('Academics'))).toBeTruthy();
});
test('academics: h2 "Welcome to a Community of Disc"', async ({ page }) => {
await page.goto('/academics/');
const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'Welcome to a Community of Discovery' || t.startsWith('Welcome to a Community of Discovery'))).toBeTruthy();
});
test('academics: h2 "Studying at Verentia"', async ({ page }) => {
await page.goto('/academics/');
const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'Studying at Verentia' || t.startsWith('Studying at Verentia'))).toBeTruthy();
});
test('academics: h2 "Areas of Study"', async ({ page }) => {
await page.goto('/academics/');
const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'Areas of Study' || t.startsWith('Areas of Study'))).toBeTruthy();
});
test('academics: header link "Verentia University"', async ({ page }) => {
await page.goto('/academics/');
const links = page.locator('header a, [role="banner"] a');
const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'Verentia University' || t.startsWith('Verentia University')), 'link text in header').toBeTruthy();
});
test('academics: nav link "Academics"', async ({ page }) => {
await page.goto('/academics/');
const links = page.locator('nav a');
const texts = (await links.allTextContents()).map(s => s.replace(/\s+/g, ' ').trim());
expect(texts.some(t => t === 'Academics' || t.startsWith('Academics')), 'link text in nav').toBeTruthy();
const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase()));
expect(hrefs.some(h => h.includes('academics')), 'href fragment present').toBeTruthy();
});