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 "Welcome to the Formora Museum"', async ({ page }) => { await page.goto('/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Welcome to the Formora Museum' || t.startsWith('Welcome to the Formora Museum'))).toBeTruthy(); }); test('homepage: h1 "Elian Frost: The Archives"', async ({ page }) => { await page.goto('/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Elian Frost: The Archives' || t.startsWith('Elian Frost: The Archives'))).toBeTruthy(); }); test('homepage: h1 "RENZO: From the Studio Out"', async ({ page }) => { await page.goto('/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'RENZO: From the Studio Out' || t.startsWith('RENZO: From the Studio Out'))).toBeTruthy(); }); test('homepage: h1 "Discover more as a member"', async ({ page }) => { await page.goto('/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Discover more as a member' || t.startsWith('Discover more as a member'))).toBeTruthy(); }); test('homepage: header link "Formora LogoFormora Logo.Formo"', 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('homepage: footer link "Reserve tickets early"', async ({ page }) => { await page.goto('/'); 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 === 'Reserve tickets early' || t.startsWith('Reserve tickets early')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('homepage: footer link "Join as a member"', async ({ page }) => { await page.goto('/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('homepage: footer link "Support our work"', async ({ page }) => { await page.goto('/'); 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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - about_the_museum', () => { test('about_the_museum: title matches GT', async ({ page }) => { await page.goto('/about-the-museum/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('about the museum'); }); test('about_the_museum: h2 "The Story of the Formora Museu"', async ({ page }) => { await page.goto('/about-the-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Story of the Formora Museum' || t.startsWith('The Story of the Formora Museum'))).toBeTruthy(); }); test('about_the_museum: h2 "Our Vision, Mission and Values"', async ({ page }) => { await page.goto('/about-the-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our Vision, Mission and Values' || t.startsWith('Our Vision, Mission and Values'))).toBeTruthy(); }); test('about_the_museum: h2 "Governance"', async ({ page }) => { await page.goto('/about-the-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Governance' || t.startsWith('Governance'))).toBeTruthy(); }); test('about_the_museum: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/about-the-museum/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('about_the_museum: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/about-the-museum/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('about_the_museum: footer link "Become a member"', async ({ page }) => { await page.goto('/about-the-museum/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('about_the_museum: footer link "Support the museum"', async ({ page }) => { await page.goto('/about-the-museum/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - calendar', () => { test('calendar: title matches GT', async ({ page }) => { await page.goto('/calendar/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('calendar'); }); test('calendar: h1 "Calendar"', async ({ page }) => { await page.goto('/calendar/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Calendar' || t.startsWith('Calendar'))).toBeTruthy(); }); test('calendar: h2 "Thursday 28 May 2026"', async ({ page }) => { await page.goto('/calendar/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Thursday 28 May 2026' || t.startsWith('Thursday 28 May 2026'))).toBeTruthy(); }); test('calendar: h3 "Making Modern Life"', async ({ page }) => { await page.goto('/calendar/'); const texts = (await page.locator('h3').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Making Modern Life' || t.startsWith('Making Modern Life'))).toBeTruthy(); }); test('calendar: h3 "KENJI: From Tokyo with Love"', async ({ page }) => { await page.goto('/calendar/'); const texts = (await page.locator('h3').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'KENJI: From Tokyo with Love' || t.startsWith('KENJI: From Tokyo with Love'))).toBeTruthy(); }); test('calendar: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/calendar/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('calendar: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/calendar/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('calendar: footer link "Join as a member"', async ({ page }) => { await page.goto('/calendar/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('calendar: footer link "Donate to the museum"', async ({ page }) => { await page.goto('/calendar/'); 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 === 'Donate to the museum' || t.startsWith('Donate to the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - discover_your_membership', () => { test('discover_your_membership: title matches GT', async ({ page }) => { await page.goto('/discover-your-membership/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('discover your membership'); }); test('discover_your_membership: h1 "Uncover your membership"', async ({ page }) => { await page.goto('/discover-your-membership/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Uncover your membership' || t.startsWith('Uncover your membership'))).toBeTruthy(); }); test('discover_your_membership: h2 "Discover"', async ({ page }) => { await page.goto('/discover-your-membership/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Discover' || t.startsWith('Discover'))).toBeTruthy(); }); test('discover_your_membership: h2 "See it early"', async ({ page }) => { await page.goto('/discover-your-membership/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'See it early' || t.startsWith('See it early'))).toBeTruthy(); }); test('discover_your_membership: h2 "Secure early booking"', async ({ page }) => { await page.goto('/discover-your-membership/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Secure early booking' || t.startsWith('Secure early booking'))).toBeTruthy(); }); test('discover_your_membership: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/discover-your-membership/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('discover_your_membership: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/discover-your-membership/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('discover_your_membership: footer link "Become a member"', async ({ page }) => { await page.goto('/discover-your-membership/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('discover_your_membership: footer link "Support the museum"', async ({ page }) => { await page.goto('/discover-your-membership/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions', () => { test('exhibitions: title matches GT', async ({ page }) => { await page.goto('/exhibitions/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('exhibitions'); }); test('exhibitions: h2 "Ravenna Cole: The Archives"', async ({ page }) => { await page.goto('/exhibitions/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Ravenna Cole: The Archives' || t.startsWith('Ravenna Cole: The Archives'))).toBeTruthy(); }); test('exhibitions: h2 "RIKO: From Studio to Street"', async ({ page }) => { await page.goto('/exhibitions/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'RIKO: From Studio to Street' || t.startsWith('RIKO: From Studio to Street'))).toBeTruthy(); }); test('exhibitions: h2 "Designing for Change"', async ({ page }) => { await page.goto('/exhibitions/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Designing for Change' || t.startsWith('Designing for Change'))).toBeTruthy(); }); test('exhibitions: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions: footer link "Book tickets ahead"', async ({ page }) => { await page.goto('/exhibitions/'); 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 === 'Book tickets ahead' || t.startsWith('Book tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions: footer link "Back the museum"', async ({ page }) => { await page.goto('/exhibitions/'); 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 === 'Back the museum' || t.startsWith('Back the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - learning_and_research_design_museum_research', () => { test('learning_and_research_design_museum_research: title matches GT', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('design research'); }); test('learning_and_research_design_museum_research: h1 "Formora Museum Research"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Formora Museum Research' || t.startsWith('Formora Museum Research'))).toBeTruthy(); }); test('learning_and_research_design_museum_research: h2 "Recognised Research Organisati"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Recognised Research Organisation Status' || t.startsWith('Recognised Research Organisation Status'))).toBeTruthy(); }); test('learning_and_research_design_museum_research: h2 "Research at the Formora Museum"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Research at the Formora Museum' || t.startsWith('Research at the Formora Museum'))).toBeTruthy(); }); test('learning_and_research_design_museum_research: h2 "Green Futures Lab"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Green Futures Lab' || t.startsWith('Green Futures Lab'))).toBeTruthy(); }); test('learning_and_research_design_museum_research: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('learning_and_research_design_museum_research: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('learning_and_research_design_museum_research: footer link "Become a member"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('learning_and_research_design_museum_research: footer link "Support the museum"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - learning_and_research_design_museum_research_future_observatory', () => { test('learning_and_research_design_museum_research_future_observatory: title matches GT', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('tomorrow observatory'); }); test('learning_and_research_design_museum_research_future_observatory: h1 "Tomorrow Observatory"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Tomorrow Observatory' || t.startsWith('Tomorrow Observatory'))).toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory: h2 "About the programme"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'About the programme' || t.startsWith('About the programme'))).toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory: h2 "Shape the Green Transition"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Shape the Green Transition' || t.startsWith('Shape the Green Transition'))).toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory: h2 "Background"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Background' || t.startsWith('Background'))).toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory: footer link "Book tickets early"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/'); 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 === 'Book tickets early' || t.startsWith('Book tickets early')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory: footer link "Join as a member"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory: footer link "Support our museum"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - learning_and_research_design_museum_research_future_observatory_design_researchers_in_residence', () => { test('learning_and_research_design_museum_research_future_observatory_design_researchers_in_residence: title matches GT', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/design-researchers-in-residence/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('design researchers in residence'); }); test('learning_and_research_design_museum_research_future_observatory_design_researchers_in_residence: h1 "Design Researchers in Residenc"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/design-researchers-in-residence/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Researchers in Residence' || t.startsWith('Design Researchers in Residence'))).toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory_design_researchers_in_residence: h2 "The residency"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/design-researchers-in-residence/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The residency' || t.startsWith('The residency'))).toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory_design_researchers_in_residence: h2 "2025/26 Programme: Mineral"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/design-researchers-in-residence/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '2025/26 Programme: Mineral' || t.startsWith('2025/26 Programme: Mineral'))).toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory_design_researchers_in_residence: h2 "2024/25 Programme: Artificial"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/design-researchers-in-residence/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '2024/25 Programme: Artificial' || t.startsWith('2024/25 Programme: Artificial'))).toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory_design_researchers_in_residence: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/design-researchers-in-residence/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory_design_researchers_in_residence: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/design-researchers-in-residence/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory_design_researchers_in_residence: footer link "Join as a member"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/design-researchers-in-residence/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('learning_and_research_design_museum_research_future_observatory_design_researchers_in_residence: footer link "Support our museum"', async ({ page }) => { await page.goto('/learning-and-research/design-museum-research/future-observatory/design-researchers-in-residence/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - learning_at_the_museum', () => { test('learning_at_the_museum: title matches GT', async ({ page }) => { await page.goto('/learning-at-the-museum/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('learning at formora'); }); test('learning_at_the_museum: h1 "Learning at Formora"', async ({ page }) => { await page.goto('/learning-at-the-museum/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Learning at Formora' || t.startsWith('Learning at Formora'))).toBeTruthy(); }); test('learning_at_the_museum: h2 "What to expect"', async ({ page }) => { await page.goto('/learning-at-the-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('learning_at_the_museum: h2 "Schools and Colleges"', async ({ page }) => { await page.goto('/learning-at-the-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Schools and Colleges' || t.startsWith('Schools and Colleges'))).toBeTruthy(); }); test('learning_at_the_museum: h2 "Activities for children and yo"', async ({ page }) => { await page.goto('/learning-at-the-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Activities for children and young people' || t.startsWith('Activities for children and young people'))).toBeTruthy(); }); test('learning_at_the_museum: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/learning-at-the-museum/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('learning_at_the_museum: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/learning-at-the-museum/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('learning_at_the_museum: footer link "Become a member"', async ({ page }) => { await page.goto('/learning-at-the-museum/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('learning_at_the_museum: footer link "Support the museum"', async ({ page }) => { await page.goto('/learning-at-the-museum/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - learning_at_the_museum_ma_curating_contemporary_design', () => { test('learning_at_the_museum_ma_curating_contemporary_design: title matches GT', async ({ page }) => { await page.goto('/learning-at-the-museum/ma-curating-contemporary-design/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('ma curating modern design practice'); }); test('learning_at_the_museum_ma_curating_contemporary_design: h1 "MA Curating Modern Design Prac"', async ({ page }) => { await page.goto('/learning-at-the-museum/ma-curating-contemporary-design/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'MA Curating Modern Design Practice' || t.startsWith('MA Curating Modern Design Practice'))).toBeTruthy(); }); test('learning_at_the_museum_ma_curating_contemporary_design: h2 "Sign up for our next Postgradu"', async ({ page }) => { await page.goto('/learning-at-the-museum/ma-curating-contemporary-design/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Sign up for our next Postgraduate Open Day' || t.startsWith('Sign up for our next Postgraduate Open Day'))).toBeTruthy(); }); test('learning_at_the_museum_ma_curating_contemporary_design: h2 "Dr. Elin Marchetti, Course Dir"', async ({ page }) => { await page.goto('/learning-at-the-museum/ma-curating-contemporary-design/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Dr. Elin Marchetti, Course Director' || t.startsWith('Dr. Elin Marchetti, Course Director'))).toBeTruthy(); }); test('learning_at_the_museum_ma_curating_contemporary_design: h2 "Dr. Ruth Callenberg, Course Le"', async ({ page }) => { await page.goto('/learning-at-the-museum/ma-curating-contemporary-design/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Dr. Ruth Callenberg, Course Leader' || t.startsWith('Dr. Ruth Callenberg, Course Leader'))).toBeTruthy(); }); test('learning_at_the_museum_ma_curating_contemporary_design: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/learning-at-the-museum/ma-curating-contemporary-design/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('learning_at_the_museum_ma_curating_contemporary_design: footer link "Reserve tickets early"', async ({ page }) => { await page.goto('/learning-at-the-museum/ma-curating-contemporary-design/'); 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 === 'Reserve tickets early' || t.startsWith('Reserve tickets early')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('learning_at_the_museum_ma_curating_contemporary_design: footer link "Join as a member"', async ({ page }) => { await page.goto('/learning-at-the-museum/ma-curating-contemporary-design/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('learning_at_the_museum_ma_curating_contemporary_design: footer link "Give to the museum"', async ({ page }) => { await page.goto('/learning-at-the-museum/ma-curating-contemporary-design/'); 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 === 'Give to the museum' || t.startsWith('Give to the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - learning_at_the_museum_schools', () => { test('learning_at_the_museum_schools: title matches GT', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('schools'); }); test('learning_at_the_museum_schools: h1 "Schools"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Schools' || t.startsWith('Schools'))).toBeTruthy(); }); test('learning_at_the_museum_schools: h2 "Self-guided visits for learnin"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Self-guided visits for learning groups' || t.startsWith('Self-guided visits for learning groups'))).toBeTruthy(); }); test('learning_at_the_museum_schools: h2 "Workshops for schools"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Workshops for schools' || t.startsWith('Workshops for schools'))).toBeTruthy(); }); test('learning_at_the_museum_schools: h2 "Design Frontier"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Frontier' || t.startsWith('Design Frontier'))).toBeTruthy(); }); test('learning_at_the_museum_schools: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('learning_at_the_museum_schools: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('learning_at_the_museum_schools: footer link "Become a member"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('learning_at_the_museum_schools: footer link "Support the museum"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - our_international_work', () => { test('our_international_work: title matches GT', async ({ page }) => { await page.goto('/our-international-work/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('our international reach'); }); test('our_international_work: h1 "Our international reach"', async ({ page }) => { await page.goto('/our-international-work/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our international reach' || t.startsWith('Our international reach'))).toBeTruthy(); }); test('our_international_work: h2 "Travelling Showcases"', async ({ page }) => { await page.goto('/our-international-work/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Travelling Showcases' || t.startsWith('Travelling Showcases'))).toBeTruthy(); }); test('our_international_work: h2 "Advisory Services"', async ({ page }) => { await page.goto('/our-international-work/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Advisory Services' || t.startsWith('Advisory Services'))).toBeTruthy(); }); test('our_international_work: h2 "Worldwide Partnerships"', async ({ page }) => { await page.goto('/our-international-work/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Worldwide Partnerships' || t.startsWith('Worldwide Partnerships'))).toBeTruthy(); }); test('our_international_work: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/our-international-work/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('our_international_work: footer link "Book tickets ahead"', async ({ page }) => { await page.goto('/our-international-work/'); 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 === 'Book tickets ahead' || t.startsWith('Book tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('our_international_work: footer link "Join as a member"', async ({ page }) => { await page.goto('/our-international-work/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('our_international_work: footer link "Support our museum"', async ({ page }) => { await page.goto('/our-international-work/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - our_international_work_consultancy_services', () => { test('our_international_work_consultancy_services: title matches GT', async ({ page }) => { await page.goto('/our-international-work/consultancy-services/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('consultancy services'); }); test('our_international_work_consultancy_services: h1 "Consultancy Services"', async ({ page }) => { await page.goto('/our-international-work/consultancy-services/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Consultancy Services' || t.startsWith('Consultancy Services'))).toBeTruthy(); }); test('our_international_work_consultancy_services: h2 "Consultancy services"', async ({ page }) => { await page.goto('/our-international-work/consultancy-services/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Consultancy services' || t.startsWith('Consultancy services'))).toBeTruthy(); }); test('our_international_work_consultancy_services: h2 "Touring Exhibitions / Internat"', async ({ page }) => { await page.goto('/our-international-work/consultancy-services/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Touring Exhibitions / International Enquiries' || t.startsWith('Touring Exhibitions / International Enquiries'))).toBeTruthy(); }); test('our_international_work_consultancy_services: h2 "International Partnerships"', async ({ page }) => { await page.goto('/our-international-work/consultancy-services/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'International Partnerships' || t.startsWith('International Partnerships'))).toBeTruthy(); }); test('our_international_work_consultancy_services: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/our-international-work/consultancy-services/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('our_international_work_consultancy_services: footer link "Book early entry now"', async ({ page }) => { await page.goto('/our-international-work/consultancy-services/'); 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 === 'Book early entry now' || t.startsWith('Book early entry now')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('our_international_work_consultancy_services: footer link "Join as a member"', async ({ page }) => { await page.goto('/our-international-work/consultancy-services/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('our_international_work_consultancy_services: footer link "Support our gallery"', async ({ page }) => { await page.goto('/our-international-work/consultancy-services/'); 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 === 'Support our gallery' || t.startsWith('Support our gallery')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - our_international_work_international_partnerships', () => { test('our_international_work_international_partnerships: title matches GT', async ({ page }) => { await page.goto('/our-international-work/international-partnerships/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('international partnerships'); }); test('our_international_work_international_partnerships: h1 "Our International Alliances"', async ({ page }) => { await page.goto('/our-international-work/international-partnerships/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our International Alliances' || t.startsWith('Our International Alliances'))).toBeTruthy(); }); test('our_international_work_international_partnerships: h2 "Lumina Bay Culture Pavilion pa"', async ({ page }) => { await page.goto('/our-international-work/international-partnerships/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lumina Bay Culture Pavilion partnership' || t.startsWith('Lumina Bay Culture Pavilion partnership'))).toBeTruthy(); }); test('our_international_work_international_partnerships: h2 "What our collaborators tell us"', async ({ page }) => { await page.goto('/our-international-work/international-partnerships/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What our collaborators tell us' || t.startsWith('What our collaborators tell us'))).toBeTruthy(); }); test('our_international_work_international_partnerships: h2 "Our touring network"', async ({ page }) => { await page.goto('/our-international-work/international-partnerships/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our touring network' || t.startsWith('Our touring network'))).toBeTruthy(); }); test('our_international_work_international_partnerships: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/our-international-work/international-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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('our_international_work_international_partnerships: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/our-international-work/international-partnerships/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('our_international_work_international_partnerships: footer link "Become a member"', async ({ page }) => { await page.goto('/our-international-work/international-partnerships/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('our_international_work_international_partnerships: footer link "Support the museum"', async ({ page }) => { await page.goto('/our-international-work/international-partnerships/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - plan_your_visit_contact_information', () => { test('plan_your_visit_contact_information: title matches GT', async ({ page }) => { await page.goto('/plan-your-visit/contact-information/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('contact information'); }); test('plan_your_visit_contact_information: h1 "Contact information"', async ({ page }) => { await page.goto('/plan-your-visit/contact-information/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Contact information' || t.startsWith('Contact information'))).toBeTruthy(); }); test('plan_your_visit_contact_information: h2 "Ticket office: bookings, group"', async ({ page }) => { await page.goto('/plan-your-visit/contact-information/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Ticket office: bookings, group visits and access assistance' || t.startsWith('Ticket office: bookings, group visits and access assistance'))).toBeTruthy(); }); test('plan_your_visit_contact_information: h2 "Access assistance"', async ({ page }) => { await page.goto('/plan-your-visit/contact-information/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Access assistance' || t.startsWith('Access assistance'))).toBeTruthy(); }); test('plan_your_visit_contact_information: h2 "Media office"', async ({ page }) => { await page.goto('/plan-your-visit/contact-information/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Media office' || t.startsWith('Media office'))).toBeTruthy(); }); test('plan_your_visit_contact_information: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/plan-your-visit/contact-information/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('plan_your_visit_contact_information: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/plan-your-visit/contact-information/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('plan_your_visit_contact_information: footer link "Join as a member"', async ({ page }) => { await page.goto('/plan-your-visit/contact-information/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('plan_your_visit_contact_information: footer link "Support our museum"', async ({ page }) => { await page.goto('/plan-your-visit/contact-information/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - plan_your_visit_museum_shops', () => { test('plan_your_visit_museum_shops: title matches GT', async ({ page }) => { await page.goto('/plan-your-visit/museum-shops/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('museum shops'); }); test('plan_your_visit_museum_shops: h1 "Museum shops"', async ({ page }) => { await page.goto('/plan-your-visit/museum-shops/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Museum shops' || t.startsWith('Museum shops'))).toBeTruthy(); }); test('plan_your_visit_museum_shops: h2 "Waterfront Store"', async ({ page }) => { await page.goto('/plan-your-visit/museum-shops/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Waterfront Store' || t.startsWith('Waterfront Store'))).toBeTruthy(); }); test('plan_your_visit_museum_shops: h2 "Atrium Shop"', async ({ page }) => { await page.goto('/plan-your-visit/museum-shops/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Atrium Shop' || t.startsWith('Atrium Shop'))).toBeTruthy(); }); test('plan_your_visit_museum_shops: h2 "Exhibition Shop"', async ({ page }) => { await page.goto('/plan-your-visit/museum-shops/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Exhibition Shop' || t.startsWith('Exhibition Shop'))).toBeTruthy(); }); test('plan_your_visit_museum_shops: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/plan-your-visit/museum-shops/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('plan_your_visit_museum_shops: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/plan-your-visit/museum-shops/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('plan_your_visit_museum_shops: footer link "Join as a member"', async ({ page }) => { await page.goto('/plan-your-visit/museum-shops/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('plan_your_visit_museum_shops: footer link "Give to the museum"', async ({ page }) => { await page.goto('/plan-your-visit/museum-shops/'); 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 === 'Give to the museum' || t.startsWith('Give to the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - plan_your_visit_opening_hours', () => { test('plan_your_visit_opening_hours: title matches GT', async ({ page }) => { await page.goto('/plan-your-visit/opening-hours/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('opening hours'); }); test('plan_your_visit_opening_hours: h1 "Opening hours"', async ({ page }) => { await page.goto('/plan-your-visit/opening-hours/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Opening hours' || t.startsWith('Opening hours'))).toBeTruthy(); }); test('plan_your_visit_opening_hours: h2 "Chromatic Lab: The Sketches"', async ({ page }) => { await page.goto('/plan-your-visit/opening-hours/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Chromatic Lab: The Sketches' || t.startsWith('Chromatic Lab: The Sketches'))).toBeTruthy(); }); test('plan_your_visit_opening_hours: h2 "Pulse: the venue that shaped a"', async ({ page }) => { await page.goto('/plan-your-visit/opening-hours/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Pulse: the venue that shaped an era' || t.startsWith('Pulse: the venue that shaped an era'))).toBeTruthy(); }); test('plan_your_visit_opening_hours: h2 "Free displays"', async ({ page }) => { await page.goto('/plan-your-visit/opening-hours/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Free displays' || t.startsWith('Free displays'))).toBeTruthy(); }); test('plan_your_visit_opening_hours: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/plan-your-visit/opening-hours/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('plan_your_visit_opening_hours: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/plan-your-visit/opening-hours/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('plan_your_visit_opening_hours: footer link "Join as a member"', async ({ page }) => { await page.goto('/plan-your-visit/opening-hours/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('plan_your_visit_opening_hours: footer link "Give to Formora"', async ({ page }) => { await page.goto('/plan-your-visit/opening-hours/'); 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 === 'Give to Formora' || t.startsWith('Give to Formora')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - press_office', () => { test('press_office: title matches GT', async ({ page }) => { await page.goto('/press-office/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('press office'); }); test('press_office: h1 "Press Office"', async ({ page }) => { await page.goto('/press-office/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Press Office' || t.startsWith('Press Office'))).toBeTruthy(); }); test('press_office: h2 "Get in touch"', async ({ page }) => { await page.goto('/press-office/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Get in touch' || t.startsWith('Get in touch'))).toBeTruthy(); }); test('press_office: h2 "Press releases sharing news ab"', async ({ page }) => { await page.goto('/press-office/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Press releases sharing news about Formora Museum and its current and forthcoming exhibitions can be' || t.startsWith('Press releases sharing news about Formora Museum and its current and forthcoming exhibitions can be'))).toBeTruthy(); }); test('press_office: h2 "World’s first retrospective of"', async ({ page }) => { await page.goto('/press-office/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'World’s first retrospective of ground-breaking designer Kaito Renn to open at Formora Museum in Spri' || t.startsWith('World’s first retrospective of ground-breaking designer Kaito Renn to open at Formora Museum in Spri'))).toBeTruthy(); }); test('press_office: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/press-office/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('press_office: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/press-office/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('press_office: footer link "Become a member"', async ({ page }) => { await page.goto('/press-office/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('press_office: footer link "Give to the museum"', async ({ page }) => { await page.goto('/press-office/'); 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 === 'Give to the museum' || t.startsWith('Give to the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - privacy_policy', () => { test('privacy_policy: title matches GT', async ({ page }) => { await page.goto('/privacy-policy/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('privacy policy'); }); test('privacy_policy: h2 "Website Terms and Conditions"', async ({ page }) => { await page.goto('/privacy-policy/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Website Terms and Conditions' || t.startsWith('Website Terms and Conditions'))).toBeTruthy(); }); test('privacy_policy: h3 "Who we are"', async ({ page }) => { await page.goto('/privacy-policy/'); const texts = (await page.locator('h3').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Who we are' || t.startsWith('Who we are'))).toBeTruthy(); }); test('privacy_policy: h3 "Details we gather and how we u"', async ({ page }) => { await page.goto('/privacy-policy/'); const texts = (await page.locator('h3').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Details we gather and how we use them' || t.startsWith('Details we gather and how we use them'))).toBeTruthy(); }); test('privacy_policy: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/privacy-policy/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('privacy_policy: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/privacy-policy/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('privacy_policy: footer link "Become a member"', async ({ page }) => { await page.goto('/privacy-policy/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('privacy_policy: footer link "Support the museum"', async ({ page }) => { await page.goto('/privacy-policy/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - support_the_museum_individual_support', () => { test('support_the_museum_individual_support: title matches GT', async ({ page }) => { await page.goto('/support-the-museum/individual-support/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('individual support'); }); test('support_the_museum_individual_support: h1 "Individual Support"', async ({ page }) => { await page.goto('/support-the-museum/individual-support/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Individual Support' || t.startsWith('Individual Support'))).toBeTruthy(); }); test('support_the_museum_individual_support: h2 "Formora Circle"', async ({ page }) => { await page.goto('/support-the-museum/individual-support/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Formora Circle' || t.startsWith('Formora Circle'))).toBeTruthy(); }); test('support_the_museum_individual_support: h2 "Formora Fellows"', async ({ page }) => { await page.goto('/support-the-museum/individual-support/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Formora Fellows' || t.startsWith('Formora Fellows'))).toBeTruthy(); }); test('support_the_museum_individual_support: h2 "Formora Benefactors"', async ({ page }) => { await page.goto('/support-the-museum/individual-support/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Formora Benefactors' || t.startsWith('Formora Benefactors'))).toBeTruthy(); }); test('support_the_museum_individual_support: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/support-the-museum/individual-support/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('support_the_museum_individual_support: footer link "Reserve tickets now"', async ({ page }) => { await page.goto('/support-the-museum/individual-support/'); 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 === 'Reserve tickets now' || t.startsWith('Reserve tickets now')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('support_the_museum_individual_support: footer link "Become a friend"', async ({ page }) => { await page.goto('/support-the-museum/individual-support/'); 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 === 'Become a friend' || t.startsWith('Become a friend')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('support_the_museum_individual_support: footer link "Support our museum"', async ({ page }) => { await page.goto('/support-the-museum/individual-support/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - support_us_thank_you_for_your_support', () => { test('support_us_thank_you_for_your_support: title matches GT', async ({ page }) => { await page.goto('/support-us/thank-you-for-your-support/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('thank you for your support'); }); test('support_us_thank_you_for_your_support: h1 "Thank You for Your Support"', async ({ page }) => { await page.goto('/support-us/thank-you-for-your-support/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Thank You for Your Support' || t.startsWith('Thank You for Your Support'))).toBeTruthy(); }); test('support_us_thank_you_for_your_support: h2 "Formora Museum Founder"', async ({ page }) => { await page.goto('/support-us/thank-you-for-your-support/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Formora Museum Founder' || t.startsWith('Formora Museum Founder'))).toBeTruthy(); }); test('support_us_thank_you_for_your_support: h2 "Public Funders"', async ({ page }) => { await page.goto('/support-us/thank-you-for-your-support/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Public Funders' || t.startsWith('Public Funders'))).toBeTruthy(); }); test('support_us_thank_you_for_your_support: h2 "Principal Funders"', async ({ page }) => { await page.goto('/support-us/thank-you-for-your-support/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Principal Funders' || t.startsWith('Principal Funders'))).toBeTruthy(); }); test('support_us_thank_you_for_your_support: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/support-us/thank-you-for-your-support/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('support_us_thank_you_for_your_support: footer link "Reserve your tickets"', async ({ page }) => { await page.goto('/support-us/thank-you-for-your-support/'); 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 === 'Reserve your tickets' || t.startsWith('Reserve your tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('support_us_thank_you_for_your_support: footer link "Become a friend"', async ({ page }) => { await page.goto('/support-us/thank-you-for-your-support/'); 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 === 'Become a friend' || t.startsWith('Become a friend')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('support_us_thank_you_for_your_support: footer link "Support our museum"', async ({ page }) => { await page.goto('/support-us/thank-you-for-your-support/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - support_us_trusts_and_foundations', () => { test('support_us_trusts_and_foundations: title matches GT', async ({ page }) => { await page.goto('/support-us/trusts-and-foundations/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('trusts and foundations'); }); test('support_us_trusts_and_foundations: h1 "Trusts and Foundations"', async ({ page }) => { await page.goto('/support-us/trusts-and-foundations/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Trusts and Foundations' || t.startsWith('Trusts and Foundations'))).toBeTruthy(); }); test('support_us_trusts_and_foundations: h2 "Annual reach"', async ({ page }) => { await page.goto('/support-us/trusts-and-foundations/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Annual reach' || t.startsWith('Annual reach'))).toBeTruthy(); }); test('support_us_trusts_and_foundations: h2 "Trusts and Foundations who par"', async ({ page }) => { await page.goto('/support-us/trusts-and-foundations/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Trusts and Foundations who partner with us can expect:' || t.startsWith('Trusts and Foundations who partner with us can expect:'))).toBeTruthy(); }); test('support_us_trusts_and_foundations: h2 "We keep seeking support for th"', async ({ page }) => { await page.goto('/support-us/trusts-and-foundations/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'We keep seeking support for the museum and the work we do, which includes:' || t.startsWith('We keep seeking support for the museum and the work we do, which includes:'))).toBeTruthy(); }); test('support_us_trusts_and_foundations: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/support-us/trusts-and-foundations/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('support_us_trusts_and_foundations: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/support-us/trusts-and-foundations/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('support_us_trusts_and_foundations: footer link "Become a member"', async ({ page }) => { await page.goto('/support-us/trusts-and-foundations/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('support_us_trusts_and_foundations: footer link "Support the museum"', async ({ page }) => { await page.goto('/support-us/trusts-and-foundations/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - venue_hire', () => { test('venue_hire: title matches GT', async ({ page }) => { await page.goto('/venue-hire/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('venue hire'); }); test('venue_hire: h2 "Event spaces"', async ({ page }) => { await page.goto('/venue-hire/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Event spaces' || t.startsWith('Event spaces'))).toBeTruthy(); }); test('venue_hire: h2 "Events Catering"', async ({ page }) => { await page.goto('/venue-hire/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Events Catering' || t.startsWith('Events Catering'))).toBeTruthy(); }); test('venue_hire: h2 "Designed to Connect"', async ({ page }) => { await page.goto('/venue-hire/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Designed to Connect' || t.startsWith('Designed to Connect'))).toBeTruthy(); }); test('venue_hire: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/venue-hire/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('venue_hire: footer link "Buy tickets in advance"', async ({ page }) => { await page.goto('/venue-hire/'); 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 === 'Buy tickets in advance' || t.startsWith('Buy tickets in advance')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('venue_hire: footer link "Join as a member"', async ({ page }) => { await page.goto('/venue-hire/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('venue_hire: footer link "Support Formora"', async ({ page }) => { await page.goto('/venue-hire/'); 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 === 'Support Formora' || t.startsWith('Support Formora')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on', () => { test('whats_on: title matches GT', async ({ page }) => { await page.goto('/whats-on/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('what\'s on'); }); test('whats_on: h2 "Exhibitions and"', async ({ page }) => { await page.goto('/whats-on/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Exhibitions and' || t.startsWith('Exhibitions and'))).toBeTruthy(); }); test('whats_on: h2 "Talks, courses and workshops"', async ({ page }) => { await page.goto('/whats-on/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Talks, courses and workshops' || t.startsWith('Talks, courses and workshops'))).toBeTruthy(); }); test('whats_on: h2 "Riverside Festival of Architec"', async ({ page }) => { await page.goto('/whats-on/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Riverside Festival of Architecture 2026' || t.startsWith('Riverside Festival of Architecture 2026'))).toBeTruthy(); }); test('whats_on: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/whats-on/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on: footer link "Become a member"', async ({ page }) => { await page.goto('/whats-on/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on: footer link "Support the museum"', async ({ page }) => { await page.goto('/whats-on/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_families_and_young_people', () => { test('whats_on_families_and_young_people: title matches GT', async ({ page }) => { await page.goto('/whats-on/families-and-young-people/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('families and young people'); }); test('whats_on_families_and_young_people: h1 "Families and young people"', async ({ page }) => { await page.goto('/whats-on/families-and-young-people/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Families and young people' || t.startsWith('Families and young people'))).toBeTruthy(); }); test('whats_on_families_and_young_people: h2 "Family Day: Building Imagined "', async ({ page }) => { await page.goto('/whats-on/families-and-young-people/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Family Day: Building Imagined Worlds' || t.startsWith('Family Day: Building Imagined Worlds'))).toBeTruthy(); }); test('whats_on_families_and_young_people: h2 "Booking now: May 2026 Design C"', async ({ page }) => { await page.goto('/whats-on/families-and-young-people/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking now: May 2026 Design Camps' || t.startsWith('Booking now: May 2026 Design Camps'))).toBeTruthy(); }); test('whats_on_families_and_young_people: h2 "Design Camp for ages 7 to 10: "', async ({ page }) => { await page.goto('/whats-on/families-and-young-people/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Camp for ages 7 to 10: Clay Animation Lab' || t.startsWith('Design Camp for ages 7 to 10: Clay Animation Lab'))).toBeTruthy(); }); test('whats_on_families_and_young_people: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/families-and-young-people/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_families_and_young_people: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/whats-on/families-and-young-people/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_families_and_young_people: footer link "Become a member"', async ({ page }) => { await page.goto('/whats-on/families-and-young-people/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_families_and_young_people: footer link "Support our gallery"', async ({ page }) => { await page.goto('/whats-on/families-and-young-people/'); 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 === 'Support our gallery' || t.startsWith('Support our gallery')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops', () => { test('whats_on_talks_courses_and_workshops: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('talks, courses and workshops'); }); test('whats_on_talks_courses_and_workshops: h1 "Talks, classes and workshops"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Talks, classes and workshops' || t.startsWith('Talks, classes and workshops'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops: h2 "Design Camp for ages 7 to 10: " [dup#1]', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Camp for ages 7 to 10: Stop-Frame Clay Tales' || t.startsWith('Design Camp for ages 7 to 10: Stop-Frame Clay Tales'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops: h2 "Design Camp for ages 11 to 14:"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Camp for ages 11 to 14: Illustration Studio' || t.startsWith('Design Camp for ages 11 to 14: Illustration Studio'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops: h2 "Design Camp for ages 7 to 10: " [dup#2]', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Camp for ages 7 to 10: Recycled Prop Making' || t.startsWith('Design Camp for ages 7 to 10: Recycled Prop Making'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops: footer link "Become a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops: footer link "Support the museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - about_the_museum_design_museum_collection', () => { test('about_the_museum_design_museum_collection: title matches GT', async ({ page }) => { await page.goto('/about-the-museum/design-museum-collection/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('formora design collection'); }); test('about_the_museum_design_museum_collection: h1 "Formora Museum Collection"', async ({ page }) => { await page.goto('/about-the-museum/design-museum-collection/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Formora Museum Collection' || t.startsWith('Formora Museum Collection'))).toBeTruthy(); }); test('about_the_museum_design_museum_collection: h2 "What do you collect?"', async ({ page }) => { await page.goto('/about-the-museum/design-museum-collection/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What do you collect?' || t.startsWith('What do you collect?'))).toBeTruthy(); }); test('about_the_museum_design_museum_collection: h2 "When did you begin collecting?"', async ({ page }) => { await page.goto('/about-the-museum/design-museum-collection/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'When did you begin collecting?' || t.startsWith('When did you begin collecting?'))).toBeTruthy(); }); test('about_the_museum_design_museum_collection: h2 "Are you still collecting?"', async ({ page }) => { await page.goto('/about-the-museum/design-museum-collection/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Are you still collecting?' || t.startsWith('Are you still collecting?'))).toBeTruthy(); }); test('about_the_museum_design_museum_collection: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/about-the-museum/design-museum-collection/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('about_the_museum_design_museum_collection: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/about-the-museum/design-museum-collection/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_design_museum_collection: footer link "Become a member"', async ({ page }) => { await page.goto('/about-the-museum/design-museum-collection/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_design_museum_collection: footer link "Support the museum"', async ({ page }) => { await page.goto('/about-the-museum/design-museum-collection/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - about_the_museum_governance', () => { test('about_the_museum_governance: title matches GT', async ({ page }) => { await page.goto('/about-the-museum/governance/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('governance'); }); test('about_the_museum_governance: h1 "Governance"', async ({ page }) => { await page.goto('/about-the-museum/governance/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Governance' || t.startsWith('Governance'))).toBeTruthy(); }); test('about_the_museum_governance: h2 "Meet the Directorate"', async ({ page }) => { await page.goto('/about-the-museum/governance/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet the Directorate' || t.startsWith('Meet the Directorate'))).toBeTruthy(); }); test('about_the_museum_governance: h2 "Trustees"', async ({ page }) => { await page.goto('/about-the-museum/governance/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Trustees' || t.startsWith('Trustees'))).toBeTruthy(); }); test('about_the_museum_governance: h2 "Advisory Committees"', async ({ page }) => { await page.goto('/about-the-museum/governance/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Advisory Committees' || t.startsWith('Advisory Committees'))).toBeTruthy(); }); test('about_the_museum_governance: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/about-the-museum/governance/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('about_the_museum_governance: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/about-the-museum/governance/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_governance: footer link "Become a member"', async ({ page }) => { await page.goto('/about-the-museum/governance/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_governance: footer link "Support the museum"', async ({ page }) => { await page.goto('/about-the-museum/governance/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - about_the_museum_immunity_from_seizure', () => { test('about_the_museum_immunity_from_seizure: title matches GT', async ({ page }) => { await page.goto('/about-the-museum/immunity-from-seizure/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('immunity from seizure'); }); test('about_the_museum_immunity_from_seizure: h1 "Immunity from seizure"', async ({ page }) => { await page.goto('/about-the-museum/immunity-from-seizure/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Immunity from seizure' || t.startsWith('Immunity from seizure'))).toBeTruthy(); }); test('about_the_museum_immunity_from_seizure: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/about-the-museum/immunity-from-seizure/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('about_the_museum_immunity_from_seizure: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/about-the-museum/immunity-from-seizure/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_immunity_from_seizure: footer link "Become a member"', async ({ page }) => { await page.goto('/about-the-museum/immunity-from-seizure/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_immunity_from_seizure: footer link "Support the museum"', async ({ page }) => { await page.goto('/about-the-museum/immunity-from-seizure/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - about_the_museum_independent_research_organisation_iro_status', () => { test('about_the_museum_independent_research_organisation_iro_status: title matches GT', async ({ page }) => { await page.goto('/about-the-museum/independent-research-organisation-iro-status/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('independent research organisation (iro) '); }); test('about_the_museum_independent_research_organisation_iro_status: h1 "Independent Research Organisat"', async ({ page }) => { await page.goto('/about-the-museum/independent-research-organisation-iro-status/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Independent Research Organisation (IRO) Status' || t.startsWith('Independent Research Organisation (IRO) Status'))).toBeTruthy(); }); test('about_the_museum_independent_research_organisation_iro_status: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/about-the-museum/independent-research-organisation-iro-status/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('about_the_museum_independent_research_organisation_iro_status: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/about-the-museum/independent-research-organisation-iro-status/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_independent_research_organisation_iro_status: footer link "Become a member"', async ({ page }) => { await page.goto('/about-the-museum/independent-research-organisation-iro-status/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_independent_research_organisation_iro_status: footer link "Support the museum"', async ({ page }) => { await page.goto('/about-the-museum/independent-research-organisation-iro-status/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - about_the_museum_the_design_museums_dna', () => { test('about_the_museum_the_design_museums_dna: title matches GT', async ({ page }) => { await page.goto('/about-the-museum/the-design-museums-dna/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('formora\'s guiding dna'); }); test('about_the_museum_the_design_museums_dna: h1 "What Formora Stands For"', async ({ page }) => { await page.goto('/about-the-museum/the-design-museums-dna/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What Formora Stands For' || t.startsWith('What Formora Stands For'))).toBeTruthy(); }); test('about_the_museum_the_design_museums_dna: h2 "Our vision:"', async ({ page }) => { await page.goto('/about-the-museum/the-design-museums-dna/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our vision:' || t.startsWith('Our vision:'))).toBeTruthy(); }); test('about_the_museum_the_design_museums_dna: h2 "Our mission:"', async ({ page }) => { await page.goto('/about-the-museum/the-design-museums-dna/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our mission:' || t.startsWith('Our mission:'))).toBeTruthy(); }); test('about_the_museum_the_design_museums_dna: h2 "Our values:"', async ({ page }) => { await page.goto('/about-the-museum/the-design-museums-dna/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our values:' || t.startsWith('Our values:'))).toBeTruthy(); }); test('about_the_museum_the_design_museums_dna: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/about-the-museum/the-design-museums-dna/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('about_the_museum_the_design_museums_dna: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/about-the-museum/the-design-museums-dna/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_the_design_museums_dna: footer link "Join as a member"', async ({ page }) => { await page.goto('/about-the-museum/the-design-museums-dna/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_the_design_museums_dna: footer link "Support our museum"', async ({ page }) => { await page.goto('/about-the-museum/the-design-museums-dna/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - about_the_museum_the_story_of_the_design_museum', () => { test('about_the_museum_the_story_of_the_design_museum: title matches GT', async ({ page }) => { await page.goto('/about-the-museum/the-story-of-the-design-museum/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('the story of formora'); }); test('about_the_museum_the_story_of_the_design_museum: h1 "The Story of the Formora Museu"', async ({ page }) => { await page.goto('/about-the-museum/the-story-of-the-design-museum/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Story of the Formora Museum' || t.startsWith('The Story of the Formora Museum'))).toBeTruthy(); }); test('about_the_museum_the_story_of_the_design_museum: h2 "Born in 2004"', async ({ page }) => { await page.goto('/about-the-museum/the-story-of-the-design-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Born in 2004' || t.startsWith('Born in 2004'))).toBeTruthy(); }); test('about_the_museum_the_story_of_the_design_museum: h2 "Moving to Northgate"', async ({ page }) => { await page.goto('/about-the-museum/the-story-of-the-design-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Moving to Northgate' || t.startsWith('Moving to Northgate'))).toBeTruthy(); }); test('about_the_museum_the_story_of_the_design_museum: h2 "The Maker\'s Muse"', async ({ page }) => { await page.goto('/about-the-museum/the-story-of-the-design-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Maker\'s Muse' || t.startsWith('The Maker\'s Muse'))).toBeTruthy(); }); test('about_the_museum_the_story_of_the_design_museum: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/about-the-museum/the-story-of-the-design-museum/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('about_the_museum_the_story_of_the_design_museum: footer link "Reserve tickets now"', async ({ page }) => { await page.goto('/about-the-museum/the-story-of-the-design-museum/'); 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 === 'Reserve tickets now' || t.startsWith('Reserve tickets now')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_the_story_of_the_design_museum: footer link "Become a friend"', async ({ page }) => { await page.goto('/about-the-museum/the-story-of-the-design-museum/'); 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 === 'Become a friend' || t.startsWith('Become a friend')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_the_story_of_the_design_museum: footer link "Support our museum"', async ({ page }) => { await page.goto('/about-the-museum/the-story-of-the-design-museum/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - about_the_museum_transformation_2029', () => { test('about_the_museum_transformation_2029: title matches GT', async ({ page }) => { await page.goto('/about-the-museum/transformation-2029/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('renewal 2029'); }); test('about_the_museum_transformation_2029: h1 "Renewal 2029 Vision"', async ({ page }) => { await page.goto('/about-the-museum/transformation-2029/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Renewal 2029 Vision' || t.startsWith('Renewal 2029 Vision'))).toBeTruthy(); }); test('about_the_museum_transformation_2029: h2 "Mission, Vision and Values"', async ({ page }) => { await page.goto('/about-the-museum/transformation-2029/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Mission, Vision and Values' || t.startsWith('Mission, Vision and Values'))).toBeTruthy(); }); test('about_the_museum_transformation_2029: h3 "Our Guiding Objectives:"', async ({ page }) => { await page.goto('/about-the-museum/transformation-2029/'); const texts = (await page.locator('h3').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our Guiding Objectives:' || t.startsWith('Our Guiding Objectives:'))).toBeTruthy(); }); test('about_the_museum_transformation_2029: h3 "Our institution\'s goals will b"', async ({ page }) => { await page.goto('/about-the-museum/transformation-2029/'); const texts = (await page.locator('h3').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our institution\'s goals will be delivered through four transformational priorities:' || t.startsWith('Our institution\'s goals will be delivered through four transformational priorities:'))).toBeTruthy(); }); test('about_the_museum_transformation_2029: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/about-the-museum/transformation-2029/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('about_the_museum_transformation_2029: footer link "Reserve tickets now"', async ({ page }) => { await page.goto('/about-the-museum/transformation-2029/'); 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 === 'Reserve tickets now' || t.startsWith('Reserve tickets now')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_transformation_2029: footer link "Join as a member"', async ({ page }) => { await page.goto('/about-the-museum/transformation-2029/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_transformation_2029: footer link "Support our museum"', async ({ page }) => { await page.goto('/about-the-museum/transformation-2029/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - about_the_museum_volunteer_at_the_museum', () => { test('about_the_museum_volunteer_at_the_museum: title matches GT', async ({ page }) => { await page.goto('/about-the-museum/volunteer-at-the-museum/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('join the volunteer programme'); }); test('about_the_museum_volunteer_at_the_museum: h1 "Volunteering at Formora"', async ({ page }) => { await page.goto('/about-the-museum/volunteer-at-the-museum/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Volunteering at Formora' || t.startsWith('Volunteering at Formora'))).toBeTruthy(); }); test('about_the_museum_volunteer_at_the_museum: h2 "Volunteering opportunities"', async ({ page }) => { await page.goto('/about-the-museum/volunteer-at-the-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Volunteering opportunities' || t.startsWith('Volunteering opportunities'))).toBeTruthy(); }); test('about_the_museum_volunteer_at_the_museum: h2 "Work Experience"', async ({ page }) => { await page.goto('/about-the-museum/volunteer-at-the-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Work Experience' || t.startsWith('Work Experience'))).toBeTruthy(); }); test('about_the_museum_volunteer_at_the_museum: h3 "Gardening volunteers"', async ({ page }) => { await page.goto('/about-the-museum/volunteer-at-the-museum/'); const texts = (await page.locator('h3').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Gardening volunteers' || t.startsWith('Gardening volunteers'))).toBeTruthy(); }); test('about_the_museum_volunteer_at_the_museum: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/about-the-museum/volunteer-at-the-museum/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('about_the_museum_volunteer_at_the_museum: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/about-the-museum/volunteer-at-the-museum/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_volunteer_at_the_museum: footer link "Become a member"', async ({ page }) => { await page.goto('/about-the-museum/volunteer-at-the-museum/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_volunteer_at_the_museum: footer link "Support the museum"', async ({ page }) => { await page.goto('/about-the-museum/volunteer-at-the-museum/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - about_the_museum_work_with_us', () => { test('about_the_museum_work_with_us: title matches GT', async ({ page }) => { await page.goto('/about-the-museum/work-with-us/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('work with us'); }); test('about_the_museum_work_with_us: h1 "Work with us"', async ({ page }) => { await page.goto('/about-the-museum/work-with-us/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Work with us' || t.startsWith('Work with us'))).toBeTruthy(); }); test('about_the_museum_work_with_us: h2 "Careers"', async ({ page }) => { await page.goto('/about-the-museum/work-with-us/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Careers' || t.startsWith('Careers'))).toBeTruthy(); }); test('about_the_museum_work_with_us: h2 "Volunteer at the museum"', async ({ page }) => { await page.goto('/about-the-museum/work-with-us/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Volunteer at the museum' || t.startsWith('Volunteer at the museum'))).toBeTruthy(); }); test('about_the_museum_work_with_us: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/about-the-museum/work-with-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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('about_the_museum_work_with_us: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/about-the-museum/work-with-us/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_work_with_us: footer link "Become a member"', async ({ page }) => { await page.goto('/about-the-museum/work-with-us/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('about_the_museum_work_with_us: footer link "Support the museum"', async ({ page }) => { await page.goto('/about-the-museum/work-with-us/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - become_a_member_get_in_touch_with_membership', () => { test('become_a_member_get_in_touch_with_membership: title matches GT', async ({ page }) => { await page.goto('/become-a-member/get-in-touch-with-membership/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('contact our membership team'); }); test('become_a_member_get_in_touch_with_membership: h1 "Contact the Membership team"', async ({ page }) => { await page.goto('/become-a-member/get-in-touch-with-membership/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Contact the Membership team' || t.startsWith('Contact the Membership team'))).toBeTruthy(); }); test('become_a_member_get_in_touch_with_membership: h2 "Learn more about our Membershi"', async ({ page }) => { await page.goto('/become-a-member/get-in-touch-with-membership/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Learn more about our Membership' || t.startsWith('Learn more about our Membership'))).toBeTruthy(); }); test('become_a_member_get_in_touch_with_membership: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/become-a-member/get-in-touch-with-membership/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('become_a_member_get_in_touch_with_membership: footer link "Book tickets ahead"', async ({ page }) => { await page.goto('/become-a-member/get-in-touch-with-membership/'); 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 === 'Book tickets ahead' || t.startsWith('Book tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('become_a_member_get_in_touch_with_membership: footer link "Join as a member"', async ({ page }) => { await page.goto('/become-a-member/get-in-touch-with-membership/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('become_a_member_get_in_touch_with_membership: footer link "Support our museum"', async ({ page }) => { await page.goto('/become-a-member/get-in-touch-with-membership/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - become_a_member_give_the_gift_of_membership', () => { test('become_a_member_give_the_gift_of_membership: title matches GT', async ({ page }) => { await page.goto('/become-a-member/give-the-gift-of-membership/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('give the gift of membership'); }); test('become_a_member_give_the_gift_of_membership: h1 "Give the gift of membership"', async ({ page }) => { await page.goto('/become-a-member/give-the-gift-of-membership/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Give the gift of membership' || t.startsWith('Give the gift of membership'))).toBeTruthy(); }); test('become_a_member_give_the_gift_of_membership: h2 "Benefits"', async ({ page }) => { await page.goto('/become-a-member/give-the-gift-of-membership/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Benefits' || t.startsWith('Benefits'))).toBeTruthy(); }); test('become_a_member_give_the_gift_of_membership: h2 "Get in touch"', async ({ page }) => { await page.goto('/become-a-member/give-the-gift-of-membership/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Get in touch' || t.startsWith('Get in touch'))).toBeTruthy(); }); test('become_a_member_give_the_gift_of_membership: h2 "Membership FAQs"', async ({ page }) => { await page.goto('/become-a-member/give-the-gift-of-membership/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Membership FAQs' || t.startsWith('Membership FAQs'))).toBeTruthy(); }); test('become_a_member_give_the_gift_of_membership: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/become-a-member/give-the-gift-of-membership/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('become_a_member_give_the_gift_of_membership: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/become-a-member/give-the-gift-of-membership/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('become_a_member_give_the_gift_of_membership: footer link "Become a member"', async ({ page }) => { await page.goto('/become-a-member/give-the-gift-of-membership/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('become_a_member_give_the_gift_of_membership: footer link "Support the museum"', async ({ page }) => { await page.goto('/become-a-member/give-the-gift-of-membership/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - design_design_museum_publishing', () => { test('design_design_museum_publishing: title matches GT', async ({ page }) => { await page.goto('/design/design-museum-publishing/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('formora publishing'); }); test('design_design_museum_publishing: h1 "Formora Publishing House"', async ({ page }) => { await page.goto('/design/design-museum-publishing/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Formora Publishing House' || t.startsWith('Formora Publishing House'))).toBeTruthy(); }); test('design_design_museum_publishing: h2 "Lena Voss: Quiet Objects"', async ({ page }) => { await page.goto('/design/design-museum-publishing/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lena Voss: Quiet Objects' || t.startsWith('Lena Voss: Quiet Objects'))).toBeTruthy(); }); test('design_design_museum_publishing: h2 "Threads Reworked: The New Lang"', async ({ page }) => { await page.goto('/design/design-museum-publishing/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Threads Reworked: The New Language of Cloth' || t.startsWith('Threads Reworked: The New Language of Cloth'))).toBeTruthy(); }); test('design_design_museum_publishing: h2 "Forms of Feeling: Minimalism a"', async ({ page }) => { await page.goto('/design/design-museum-publishing/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Forms of Feeling: Minimalism and Design 1965 – Today' || t.startsWith('Forms of Feeling: Minimalism and Design 1965 – Today'))).toBeTruthy(); }); test('design_design_museum_publishing: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/design/design-museum-publishing/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('design_design_museum_publishing: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/design/design-museum-publishing/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('design_design_museum_publishing: footer link "Become a member"', async ({ page }) => { await page.goto('/design/design-museum-publishing/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('design_design_museum_publishing: footer link "Support the museum"', async ({ page }) => { await page.goto('/design/design-museum-publishing/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_ai_da_portrait_of_the_robot', () => { test('exhibitions_ai_da_portrait_of_the_robot: title matches GT', async ({ page }) => { await page.goto('/exhibitions/ai-da-portrait-of-the-robot/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('orla'); }); test('exhibitions_ai_da_portrait_of_the_robot: h1 "Orla-7: Portrait of the Machin"', async ({ page }) => { await page.goto('/exhibitions/ai-da-portrait-of-the-robot/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Orla-7: Portrait of the Machine' || t.startsWith('Orla-7: Portrait of the Machine'))).toBeTruthy(); }); test('exhibitions_ai_da_portrait_of_the_robot: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/ai-da-portrait-of-the-robot/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_ai_da_portrait_of_the_robot: h2 "The Meeting of Art and AI | Fo"', async ({ page }) => { await page.goto('/exhibitions/ai-da-portrait-of-the-robot/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Meeting of Art and AI | Formora Talks' || t.startsWith('The Meeting of Art and AI | Formora Talks'))).toBeTruthy(); }); test('exhibitions_ai_da_portrait_of_the_robot: h2 "Advance booking only"', async ({ page }) => { await page.goto('/exhibitions/ai-da-portrait-of-the-robot/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Advance booking only' || t.startsWith('Advance booking only'))).toBeTruthy(); }); test('exhibitions_ai_da_portrait_of_the_robot: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/ai-da-portrait-of-the-robot/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_ai_da_portrait_of_the_robot: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/ai-da-portrait-of-the-robot/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_ai_da_portrait_of_the_robot: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/ai-da-portrait-of-the-robot/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_ai_da_portrait_of_the_robot: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/ai-da-portrait-of-the-robot/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_ai_weiwei_making_sense', () => { test('exhibitions_ai_weiwei_making_sense: title matches GT', async ({ page }) => { await page.goto('/exhibitions/ai-weiwei-making-sense/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('mira vale'); }); test('exhibitions_ai_weiwei_making_sense: h1 "Mira Vale: Common Ground"', async ({ page }) => { await page.goto('/exhibitions/ai-weiwei-making-sense/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Mira Vale: Common Ground' || t.startsWith('Mira Vale: Common Ground'))).toBeTruthy(); }); test('exhibitions_ai_weiwei_making_sense: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/ai-weiwei-making-sense/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_ai_weiwei_making_sense: h2 "Booking Information"', async ({ page }) => { await page.goto('/exhibitions/ai-weiwei-making-sense/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking Information' || t.startsWith('Booking Information'))).toBeTruthy(); }); test('exhibitions_ai_weiwei_making_sense: h2 "5 Unmissable Highlights from #"', async ({ page }) => { await page.goto('/exhibitions/ai-weiwei-making-sense/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '5 Unmissable Highlights from #CommonGround' || t.startsWith('5 Unmissable Highlights from #CommonGround'))).toBeTruthy(); }); test('exhibitions_ai_weiwei_making_sense: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/ai-weiwei-making-sense/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_ai_weiwei_making_sense: footer link "Book tickets early"', async ({ page }) => { await page.goto('/exhibitions/ai-weiwei-making-sense/'); 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 === 'Book tickets early' || t.startsWith('Book tickets early')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_ai_weiwei_making_sense: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/ai-weiwei-making-sense/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_ai_weiwei_making_sense: footer link "Give to the museum"', async ({ page }) => { await page.goto('/exhibitions/ai-weiwei-making-sense/'); 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 === 'Give to the museum' || t.startsWith('Give to the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_antifurniture', () => { test('exhibitions_antifurniture: title matches GT', async ({ page }) => { await page.goto('/exhibitions/antifurniture/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('counterseating'); }); test('exhibitions_antifurniture: h1 "COUNTERSEATING"', async ({ page }) => { await page.goto('/exhibitions/antifurniture/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'COUNTERSEATING' || t.startsWith('COUNTERSEATING'))).toBeTruthy(); }); test('exhibitions_antifurniture: h2 "About the works"', async ({ page }) => { await page.goto('/exhibitions/antifurniture/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'About the works' || t.startsWith('About the works'))).toBeTruthy(); }); test('exhibitions_antifurniture: h2 "Visit information"', async ({ page }) => { await page.goto('/exhibitions/antifurniture/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Visit information' || t.startsWith('Visit information'))).toBeTruthy(); }); test('exhibitions_antifurniture: h2 "Acknowledgements"', async ({ page }) => { await page.goto('/exhibitions/antifurniture/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Acknowledgements' || t.startsWith('Acknowledgements'))).toBeTruthy(); }); test('exhibitions_antifurniture: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/antifurniture/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_antifurniture: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/exhibitions/antifurniture/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_antifurniture: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/antifurniture/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_antifurniture: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/antifurniture/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_ardagh_young_creatives_gathering_for_nature', () => { test('exhibitions_ardagh_young_creatives_gathering_for_nature: title matches GT', async ({ page }) => { await page.goto('/exhibitions/ardagh-young-creatives-gathering-for-nature/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('kindred young makers'); }); test('exhibitions_ardagh_young_creatives_gathering_for_nature: h1 "Kindred Young Makers: Coming T"', async ({ page }) => { await page.goto('/exhibitions/ardagh-young-creatives-gathering-for-nature/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Kindred Young Makers: Coming Together for Nature' || t.startsWith('Kindred Young Makers: Coming Together for Nature'))).toBeTruthy(); }); test('exhibitions_ardagh_young_creatives_gathering_for_nature: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/ardagh-young-creatives-gathering-for-nature/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_ardagh_young_creatives_gathering_for_nature: h2 "Visit Information"', async ({ page }) => { await page.goto('/exhibitions/ardagh-young-creatives-gathering-for-nature/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Visit Information' || t.startsWith('Visit Information'))).toBeTruthy(); }); test('exhibitions_ardagh_young_creatives_gathering_for_nature: h2 "About the programme"', async ({ page }) => { await page.goto('/exhibitions/ardagh-young-creatives-gathering-for-nature/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'About the programme' || t.startsWith('About the programme'))).toBeTruthy(); }); test('exhibitions_ardagh_young_creatives_gathering_for_nature: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/ardagh-young-creatives-gathering-for-nature/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_ardagh_young_creatives_gathering_for_nature: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/ardagh-young-creatives-gathering-for-nature/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_ardagh_young_creatives_gathering_for_nature: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/ardagh-young-creatives-gathering-for-nature/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_ardagh_young_creatives_gathering_for_nature: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/ardagh-young-creatives-gathering-for-nature/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_aurora', () => { test('exhibitions_aurora: title matches GT', async ({ page }) => { await page.goto('/exhibitions/aurora/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('verdant'); }); test('exhibitions_aurora: h1 "Verdant"', async ({ page }) => { await page.goto('/exhibitions/aurora/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verdant' || t.startsWith('Verdant'))).toBeTruthy(); }); test('exhibitions_aurora: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/aurora/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_aurora: h2 "What is Reflow Thinking?"', async ({ page }) => { await page.goto('/exhibitions/aurora/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What is Reflow Thinking?' || t.startsWith('What is Reflow Thinking?'))).toBeTruthy(); }); test('exhibitions_aurora: h2 "About Helion Systems"', async ({ page }) => { await page.goto('/exhibitions/aurora/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'About Helion Systems' || t.startsWith('About Helion Systems'))).toBeTruthy(); }); test('exhibitions_aurora: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/aurora/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_aurora: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/aurora/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_aurora: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/aurora/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_aurora: footer link "Support our work"', async ({ page }) => { await page.goto('/exhibitions/aurora/'); 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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_autonomous_morris', () => { test('exhibitions_autonomous_morris: title matches GT', async ({ page }) => { await page.goto('/exhibitions/autonomous-morris/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('kinetic wanderer'); }); test('exhibitions_autonomous_morris: h1 "Kinetic Wanderer"', async ({ page }) => { await page.goto('/exhibitions/autonomous-morris/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Kinetic Wanderer' || t.startsWith('Kinetic Wanderer'))).toBeTruthy(); }); test('exhibitions_autonomous_morris: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/autonomous-morris/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_autonomous_morris: h2 "Meet Marlo Venn"', async ({ page }) => { await page.goto('/exhibitions/autonomous-morris/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Marlo Venn' || t.startsWith('Meet Marlo Venn'))).toBeTruthy(); }); test('exhibitions_autonomous_morris: h2 "Sculpture Walk"', async ({ page }) => { await page.goto('/exhibitions/autonomous-morris/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Sculpture Walk' || t.startsWith('Sculpture Walk'))).toBeTruthy(); }); test('exhibitions_autonomous_morris: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/autonomous-morris/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_autonomous_morris: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/autonomous-morris/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_autonomous_morris: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/autonomous-morris/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_autonomous_morris: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/autonomous-morris/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_azzedine_alaa_the_couturier', () => { test('exhibitions_azzedine_alaa_the_couturier: title matches GT', async ({ page }) => { await page.goto('/exhibitions/azzedine-alaa-the-couturier/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('marisol vintra'); }); test('exhibitions_azzedine_alaa_the_couturier: h1 "Marisol Vintra: The Silhouette"', async ({ page }) => { await page.goto('/exhibitions/azzedine-alaa-the-couturier/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Marisol Vintra: The Silhouette' || t.startsWith('Marisol Vintra: The Silhouette'))).toBeTruthy(); }); test('exhibitions_azzedine_alaa_the_couturier: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/azzedine-alaa-the-couturier/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_azzedine_alaa_the_couturier: h2 "What the press said"', async ({ page }) => { await page.goto('/exhibitions/azzedine-alaa-the-couturier/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What the press said' || t.startsWith('What the press said'))).toBeTruthy(); }); test('exhibitions_azzedine_alaa_the_couturier: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/azzedine-alaa-the-couturier/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_azzedine_alaa_the_couturier: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/azzedine-alaa-the-couturier/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_azzedine_alaa_the_couturier: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/azzedine-alaa-the-couturier/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_azzedine_alaa_the_couturier: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/azzedine-alaa-the-couturier/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_beazley_designs_of_the_year', () => { test('exhibitions_beazley_designs_of_the_year: title matches GT', async ({ page }) => { await page.goto('/exhibitions/beazley-designs-of-the-year/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('lumina designs of the year'); }); test('exhibitions_beazley_designs_of_the_year: h1 "Lumina Designs of the Year"', async ({ page }) => { await page.goto('/exhibitions/beazley-designs-of-the-year/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lumina Designs of the Year' || t.startsWith('Lumina Designs of the Year'))).toBeTruthy(); }); test('exhibitions_beazley_designs_of_the_year: h2 "Sponsored by"', async ({ page }) => { await page.goto('/exhibitions/beazley-designs-of-the-year/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Sponsored by' || t.startsWith('Sponsored by'))).toBeTruthy(); }); test('exhibitions_beazley_designs_of_the_year: h2 "The Winners"', async ({ page }) => { await page.goto('/exhibitions/beazley-designs-of-the-year/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Winners' || t.startsWith('The Winners'))).toBeTruthy(); }); test('exhibitions_beazley_designs_of_the_year: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/beazley-designs-of-the-year/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_beazley_designs_of_the_year: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/beazley-designs-of-the-year/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_beazley_designs_of_the_year: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/beazley-designs-of-the-year/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_beazley_designs_of_the_year: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/beazley-designs-of-the-year/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_beazley_designs_of_the_year: footer link "Support the galleries"', async ({ page }) => { await page.goto('/exhibitions/beazley-designs-of-the-year/'); 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 === 'Support the galleries' || t.startsWith('Support the galleries')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_bethany_williams_alternative_systems', () => { test('exhibitions_bethany_williams_alternative_systems: title matches GT', async ({ page }) => { await page.goto('/exhibitions/bethany-williams-alternative-systems/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('marisol vance'); }); test('exhibitions_bethany_williams_alternative_systems: h1 "Marisol Vance: Circular Founda"', async ({ page }) => { await page.goto('/exhibitions/bethany-williams-alternative-systems/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Marisol Vance: Circular Foundations' || t.startsWith('Marisol Vance: Circular Foundations'))).toBeTruthy(); }); test('exhibitions_bethany_williams_alternative_systems: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/bethany-williams-alternative-systems/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_bethany_williams_alternative_systems: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/bethany-williams-alternative-systems/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_bethany_williams_alternative_systems: h2 "Enhance your visit with the fr"', async ({ page }) => { await page.goto('/exhibitions/bethany-williams-alternative-systems/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Enhance your visit with the free Formora Companion app' || t.startsWith('Enhance your visit with the free Formora Companion app'))).toBeTruthy(); }); test('exhibitions_bethany_williams_alternative_systems: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/bethany-williams-alternative-systems/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_bethany_williams_alternative_systems: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/bethany-williams-alternative-systems/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_bethany_williams_alternative_systems: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/bethany-williams-alternative-systems/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_bethany_williams_alternative_systems: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/bethany-williams-alternative-systems/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_blitz_the_club_that_shaped_the_80s', () => { test('exhibitions_blitz_the_club_that_shaped_the_80s: title matches GT', async ({ page }) => { await page.goto('/exhibitions/blitz-the-club-that-shaped-the-80s/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('aurora'); }); test('exhibitions_blitz_the_club_that_shaped_the_80s: h1 "Aurora: the club that shaped t"', async ({ page }) => { await page.goto('/exhibitions/blitz-the-club-that-shaped-the-80s/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Aurora: the club that shaped the 90s' || t.startsWith('Aurora: the club that shaped the 90s'))).toBeTruthy(); }); test('exhibitions_blitz_the_club_that_shaped_the_80s: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/blitz-the-club-that-shaped-the-80s/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_blitz_the_club_that_shaped_the_80s: h2 "Dress up Thursdays"', async ({ page }) => { await page.goto('/exhibitions/blitz-the-club-that-shaped-the-80s/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Dress up Thursdays' || t.startsWith('Dress up Thursdays'))).toBeTruthy(); }); test('exhibitions_blitz_the_club_that_shaped_the_80s: h2 "Ticket Information"', async ({ page }) => { await page.goto('/exhibitions/blitz-the-club-that-shaped-the-80s/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Ticket Information' || t.startsWith('Ticket Information'))).toBeTruthy(); }); test('exhibitions_blitz_the_club_that_shaped_the_80s: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/blitz-the-club-that-shaped-the-80s/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_blitz_the_club_that_shaped_the_80s: footer link "Reserve tickets online"', async ({ page }) => { await page.goto('/exhibitions/blitz-the-club-that-shaped-the-80s/'); 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 === 'Reserve tickets online' || t.startsWith('Reserve tickets online')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_blitz_the_club_that_shaped_the_80s: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/blitz-the-club-that-shaped-the-80s/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_blitz_the_club_that_shaped_the_80s: footer link "Support our work"', async ({ page }) => { await page.goto('/exhibitions/blitz-the-club-that-shaped-the-80s/'); 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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_changing_spaces_60_years_of_design_with_habitat', () => { test('exhibitions_changing_spaces_60_years_of_design_with_habitat: title matches GT', async ({ page }) => { await page.goto('/exhibitions/changing-spaces-60-years-of-design-with-habitat/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('living forms'); }); test('exhibitions_changing_spaces_60_years_of_design_with_habitat: h1 "Living Forms: Six Decades of E"', async ({ page }) => { await page.goto('/exhibitions/changing-spaces-60-years-of-design-with-habitat/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Living Forms: Six Decades of Everyday Design' || t.startsWith('Living Forms: Six Decades of Everyday Design'))).toBeTruthy(); }); test('exhibitions_changing_spaces_60_years_of_design_with_habitat: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/changing-spaces-60-years-of-design-with-habitat/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_changing_spaces_60_years_of_design_with_habitat: h2 "Ticket information"', async ({ page }) => { await page.goto('/exhibitions/changing-spaces-60-years-of-design-with-habitat/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Ticket information' || t.startsWith('Ticket information'))).toBeTruthy(); }); test('exhibitions_changing_spaces_60_years_of_design_with_habitat: h2 "In partnership with"', async ({ page }) => { await page.goto('/exhibitions/changing-spaces-60-years-of-design-with-habitat/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In partnership with' || t.startsWith('In partnership with'))).toBeTruthy(); }); test('exhibitions_changing_spaces_60_years_of_design_with_habitat: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/changing-spaces-60-years-of-design-with-habitat/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_changing_spaces_60_years_of_design_with_habitat: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/changing-spaces-60-years-of-design-with-habitat/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_changing_spaces_60_years_of_design_with_habitat: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/changing-spaces-60-years-of-design-with-habitat/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_changing_spaces_60_years_of_design_with_habitat: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/changing-spaces-60-years-of-design-with-habitat/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_design_researchers_in_residence_202526_mineral', () => { test('exhibitions_design_researchers_in_residence_202526_mineral: title matches GT', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-202526-mineral/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('design researchers in residence'); }); test('exhibitions_design_researchers_in_residence_202526_mineral: h1 "Design Researchers in Residenc"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-202526-mineral/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Researchers in Residence: 2025/26 Mineral' || t.startsWith('Design Researchers in Residence: 2025/26 Mineral'))).toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_202526_mineral: h2 "2025/26 Theme: Mineral"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-202526-mineral/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '2025/26 Theme: Mineral' || t.startsWith('2025/26 Theme: Mineral'))).toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_202526_mineral: h2 "Callum Sethran Reyes"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-202526-mineral/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Callum Sethran Reyes' || t.startsWith('Callum Sethran Reyes'))).toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_202526_mineral: h2 "Mira Vossen"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-202526-mineral/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Mira Vossen' || t.startsWith('Mira Vossen'))).toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_202526_mineral: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-202526-mineral/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_202526_mineral: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-202526-mineral/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_202526_mineral: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-202526-mineral/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_202526_mineral: footer link "Support our work"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-202526-mineral/'); 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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_design_researchers_in_residence_artificial', () => { test('exhibitions_design_researchers_in_residence_artificial: title matches GT', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-artificial/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('design researchers in residence'); }); test('exhibitions_design_researchers_in_residence_artificial: h1 "Design Researchers in Residenc"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-artificial/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Researchers in Residence: Artificial' || t.startsWith('Design Researchers in Residence: Artificial'))).toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_artificial: h2 "What you\'ll see"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-artificial/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What you\'ll see' || t.startsWith('What you\'ll see'))).toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_artificial: h2 "2024/25 Focus: Artificial"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-artificial/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '2024/25 Focus: Artificial' || t.startsWith('2024/25 Focus: Artificial'))).toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_artificial: h2 "Visitor information"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-artificial/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Visitor information' || t.startsWith('Visitor information'))).toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_artificial: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-artificial/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_artificial: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-artificial/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_artificial: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-artificial/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_artificial: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-artificial/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_design_researchers_in_residence_solar_display', () => { test('exhibitions_design_researchers_in_residence_solar_display: title matches GT', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-solar-display/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('solar'); }); test('exhibitions_design_researchers_in_residence_solar_display: h1 "Solar: Design Researchers in R"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-solar-display/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Solar: Design Researchers in Residence Display' || t.startsWith('Solar: Design Researchers in Residence Display'))).toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_solar_display: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-solar-display/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_solar_display: h2 "Nadia Calvert"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-solar-display/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Nadia Calvert' || t.startsWith('Nadia Calvert'))).toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_solar_display: h2 "Elsa Marden"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-solar-display/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Elsa Marden' || t.startsWith('Elsa Marden'))).toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_solar_display: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-solar-display/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_solar_display: footer link "Get advance tickets"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-solar-display/'); 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 === 'Get advance tickets' || t.startsWith('Get advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_solar_display: footer link "Join as member"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-solar-display/'); 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 === 'Join as member' || t.startsWith('Join as member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_design_researchers_in_residence_solar_display: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/design-researchers-in-residence-solar-display/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_design_ventura_2021_2022', () => { test('exhibitions_design_ventura_2021_2022: title matches GT', async ({ page }) => { await page.goto('/exhibitions/design-ventura-2021-2022/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('design horizon 2021'); }); test('exhibitions_design_ventura_2021_2022: h1 "Design Horizon 2021-2022"', async ({ page }) => { await page.goto('/exhibitions/design-ventura-2021-2022/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Horizon 2021-2022' || t.startsWith('Design Horizon 2021-2022'))).toBeTruthy(); }); test('exhibitions_design_ventura_2021_2022: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/design-ventura-2021-2022/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_design_ventura_2021_2022: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/design-ventura-2021-2022/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_design_ventura_2021_2022: h2 "Get closer through membership"', async ({ page }) => { await page.goto('/exhibitions/design-ventura-2021-2022/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Get closer through membership' || t.startsWith('Get closer through membership'))).toBeTruthy(); }); test('exhibitions_design_ventura_2021_2022: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/design-ventura-2021-2022/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_design_ventura_2021_2022: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/design-ventura-2021-2022/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_design_ventura_2021_2022: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/design-ventura-2021-2022/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_design_ventura_2021_2022: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/design-ventura-2021-2022/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_designer_maker_user', () => { test('exhibitions_designer_maker_user: title matches GT', async ({ page }) => { await page.goto('/exhibitions/designer-maker-user/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('vision craft life'); }); test('exhibitions_designer_maker_user: h1 "Vision Craft Life"', async ({ page }) => { await page.goto('/exhibitions/designer-maker-user/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Vision Craft Life' || t.startsWith('Vision Craft Life'))).toBeTruthy(); }); test('exhibitions_designer_maker_user: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/designer-maker-user/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_designer_maker_user: h2 "Visit information"', async ({ page }) => { await page.goto('/exhibitions/designer-maker-user/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Visit information' || t.startsWith('Visit information'))).toBeTruthy(); }); test('exhibitions_designer_maker_user: h2 "Family Discovery Trail"', async ({ page }) => { await page.goto('/exhibitions/designer-maker-user/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Family Discovery Trail' || t.startsWith('Family Discovery Trail'))).toBeTruthy(); }); test('exhibitions_designer_maker_user: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/designer-maker-user/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_designer_maker_user: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/designer-maker-user/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_designer_maker_user: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/designer-maker-user/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_designer_maker_user: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/designer-maker-user/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_designing_for_our_future_selves', () => { test('exhibitions_designing_for_our_future_selves: title matches GT', async ({ page }) => { await page.goto('/exhibitions/designing-for-our-future-selves/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('designing for longer, fuller lives'); }); test('exhibitions_designing_for_our_future_selves: h1 "Designing for Longer, Fuller L"', async ({ page }) => { await page.goto('/exhibitions/designing-for-our-future-selves/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Designing for Longer, Fuller Lives' || t.startsWith('Designing for Longer, Fuller Lives'))).toBeTruthy(); }); test('exhibitions_designing_for_our_future_selves: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/designing-for-our-future-selves/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_designing_for_our_future_selves: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/designing-for-our-future-selves/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_designing_for_our_future_selves: h2 "Meet Your Future Self"', async ({ page }) => { await page.goto('/exhibitions/designing-for-our-future-selves/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Meet Your Future Self' || t.startsWith('Meet Your Future Self'))).toBeTruthy(); }); test('exhibitions_designing_for_our_future_selves: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/designing-for-our-future-selves/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_designing_for_our_future_selves: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/designing-for-our-future-selves/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_designing_for_our_future_selves: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/designing-for-our-future-selves/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_designing_for_our_future_selves: footer link "Support our work"', async ({ page }) => { await page.goto('/exhibitions/designing-for-our-future-selves/'); 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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_dwellings_rehomed', () => { test('exhibitions_dwellings_rehomed: title matches GT', async ({ page }) => { await page.goto('/exhibitions/dwellings-rehomed/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('nests, reimagined'); }); test('exhibitions_dwellings_rehomed: h1 "Nests, Reimagined"', async ({ page }) => { await page.goto('/exhibitions/dwellings-rehomed/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Nests, Reimagined' || t.startsWith('Nests, Reimagined'))).toBeTruthy(); }); test('exhibitions_dwellings_rehomed: h2 "What you\'ll see"', async ({ page }) => { await page.goto('/exhibitions/dwellings-rehomed/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What you\'ll see' || t.startsWith('What you\'ll see'))).toBeTruthy(); }); test('exhibitions_dwellings_rehomed: h2 "Fieldwork Co."', async ({ page }) => { await page.goto('/exhibitions/dwellings-rehomed/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Fieldwork Co.' || t.startsWith('Fieldwork Co.'))).toBeTruthy(); }); test('exhibitions_dwellings_rehomed: h2 "Birdsong Union"', async ({ page }) => { await page.goto('/exhibitions/dwellings-rehomed/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Birdsong Union' || t.startsWith('Birdsong Union'))).toBeTruthy(); }); test('exhibitions_dwellings_rehomed: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/dwellings-rehomed/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_dwellings_rehomed: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/dwellings-rehomed/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_dwellings_rehomed: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/dwellings-rehomed/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_dwellings_rehomed: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/dwellings-rehomed/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_email_is_dead', () => { test('exhibitions_email_is_dead: title matches GT', async ({ page }) => { await page.goto('/exhibitions/email-is-dead/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('signal l̶o̶s̶t̶'); }); test('exhibitions_email_is_dead: h1 "Signal L̶o̶s̶t̶"', async ({ page }) => { await page.goto('/exhibitions/email-is-dead/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Signal L̶o̶s̶t̶' || t.startsWith('Signal L̶o̶s̶t̶'))).toBeTruthy(); }); test('exhibitions_email_is_dead: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/email-is-dead/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_email_is_dead: h2 "About Postwave Studio"', async ({ page }) => { await page.goto('/exhibitions/email-is-dead/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'About Postwave Studio' || t.startsWith('About Postwave Studio'))).toBeTruthy(); }); test('exhibitions_email_is_dead: h2 "Ticket information"', async ({ page }) => { await page.goto('/exhibitions/email-is-dead/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Ticket information' || t.startsWith('Ticket information'))).toBeTruthy(); }); test('exhibitions_email_is_dead: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/email-is-dead/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_email_is_dead: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/email-is-dead/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_email_is_dead: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/email-is-dead/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_email_is_dead: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/email-is-dead/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_enzo_mari', () => { test('exhibitions_enzo_mari: title matches GT', async ({ page }) => { await page.goto('/exhibitions/enzo-mari/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('elio sarti'); }); test('exhibitions_enzo_mari: h1 "Elio Sarti"', async ({ page }) => { await page.goto('/exhibitions/enzo-mari/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Elio Sarti' || t.startsWith('Elio Sarti'))).toBeTruthy(); }); test('exhibitions_enzo_mari: h2 "Inside the show"', async ({ page }) => { await page.goto('/exhibitions/enzo-mari/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Inside the show' || t.startsWith('Inside the show'))).toBeTruthy(); }); test('exhibitions_enzo_mari: h2 "Press reviews"', async ({ page }) => { await page.goto('/exhibitions/enzo-mari/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Press reviews' || t.startsWith('Press reviews'))).toBeTruthy(); }); test('exhibitions_enzo_mari: h2 "Tickets and Entry"', async ({ page }) => { await page.goto('/exhibitions/enzo-mari/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Tickets and Entry' || t.startsWith('Tickets and Entry'))).toBeTruthy(); }); test('exhibitions_enzo_mari: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/enzo-mari/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_enzo_mari: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/enzo-mari/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_enzo_mari: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/enzo-mari/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_enzo_mari: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/enzo-mari/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_es_devlin', () => { test('exhibitions_es_devlin: title matches GT', async ({ page }) => { await page.goto('/exhibitions/es-devlin/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('vera lindqvist'); }); test('exhibitions_es_devlin: h1 "Vera Lindqvist"', async ({ page }) => { await page.goto('/exhibitions/es-devlin/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Vera Lindqvist' || t.startsWith('Vera Lindqvist'))).toBeTruthy(); }); test('exhibitions_es_devlin: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/es-devlin/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_es_devlin: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/es-devlin/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_es_devlin: h2 "Plan your visit"', async ({ page }) => { await page.goto('/exhibitions/es-devlin/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Plan your visit' || t.startsWith('Plan your visit'))).toBeTruthy(); }); test('exhibitions_es_devlin: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/es-devlin/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_es_devlin: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/es-devlin/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_es_devlin: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/es-devlin/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_es_devlin: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/es-devlin/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_fables_for_our_time', () => { test('exhibitions_fables_for_our_time: title matches GT', async ({ page }) => { await page.goto('/exhibitions/fables-for-our-time/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('whispers of the wild'); }); test('exhibitions_fables_for_our_time: h1 "Whispers of the Wild"', async ({ page }) => { await page.goto('/exhibitions/fables-for-our-time/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Whispers of the Wild' || t.startsWith('Whispers of the Wild'))).toBeTruthy(); }); test('exhibitions_fables_for_our_time: h2 "Background"', async ({ page }) => { await page.goto('/exhibitions/fables-for-our-time/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Background' || t.startsWith('Background'))).toBeTruthy(); }); test('exhibitions_fables_for_our_time: h2 "Hear from the designers behind"', async ({ page }) => { await page.goto('/exhibitions/fables-for-our-time/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Hear from the designers behind Whispers of the Wild' || t.startsWith('Hear from the designers behind Whispers of the Wild'))).toBeTruthy(); }); test('exhibitions_fables_for_our_time: h2 "Whispers of the Wild: A Conver"', async ({ page }) => { await page.goto('/exhibitions/fables-for-our-time/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Whispers of the Wild: A Conversation with Vireo Atelier and Priya Anand' || t.startsWith('Whispers of the Wild: A Conversation with Vireo Atelier and Priya Anand'))).toBeTruthy(); }); test('exhibitions_fables_for_our_time: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/fables-for-our-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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_fables_for_our_time: footer link "Book tickets online"', async ({ page }) => { await page.goto('/exhibitions/fables-for-our-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 === 'Book tickets online' || t.startsWith('Book tickets online')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_fables_for_our_time: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/fables-for-our-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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_fables_for_our_time: footer link "Give to Formora"', async ({ page }) => { await page.goto('/exhibitions/fables-for-our-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 === 'Give to Formora' || t.startsWith('Give to Formora')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_ferrari_under_the_skin', () => { test('exhibitions_ferrari_under_the_skin: title matches GT', async ({ page }) => { await page.goto('/exhibitions/ferrari-under-the-skin/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('velmara'); }); test('exhibitions_ferrari_under_the_skin: h1 "Velmara: Under the Hood"', async ({ page }) => { await page.goto('/exhibitions/ferrari-under-the-skin/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Velmara: Under the Hood' || t.startsWith('Velmara: Under the Hood'))).toBeTruthy(); }); test('exhibitions_ferrari_under_the_skin: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/ferrari-under-the-skin/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_ferrari_under_the_skin: h2 "Aldo Maresca"', async ({ page }) => { await page.goto('/exhibitions/ferrari-under-the-skin/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Aldo Maresca' || t.startsWith('Aldo Maresca'))).toBeTruthy(); }); test('exhibitions_ferrari_under_the_skin: h2 "The cars"', async ({ page }) => { await page.goto('/exhibitions/ferrari-under-the-skin/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The cars' || t.startsWith('The cars'))).toBeTruthy(); }); test('exhibitions_ferrari_under_the_skin: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/ferrari-under-the-skin/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_ferrari_under_the_skin: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/exhibitions/ferrari-under-the-skin/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_ferrari_under_the_skin: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/ferrari-under-the-skin/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_ferrari_under_the_skin: footer link "Support Formora"', async ({ page }) => { await page.goto('/exhibitions/ferrari-under-the-skin/'); 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 === 'Support Formora' || t.startsWith('Support Formora')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_football_designing_the_beautiful_game', () => { test('exhibitions_football_designing_the_beautiful_game: title matches GT', async ({ page }) => { await page.goto('/exhibitions/football-designing-the-beautiful-game/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('football'); }); test('exhibitions_football_designing_the_beautiful_game: h1 "Football: Designing the Beauti"', async ({ page }) => { await page.goto('/exhibitions/football-designing-the-beautiful-game/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Football: Designing the Beautiful Game' || t.startsWith('Football: Designing the Beautiful Game'))).toBeTruthy(); }); test('exhibitions_football_designing_the_beautiful_game: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/football-designing-the-beautiful-game/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_football_designing_the_beautiful_game: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/football-designing-the-beautiful-game/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_football_designing_the_beautiful_game: h2 "Lena Farrow: The Future Is Fea"', async ({ page }) => { await page.goto('/exhibitions/football-designing-the-beautiful-game/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lena Farrow: The Future Is Featherlight' || t.startsWith('Lena Farrow: The Future Is Featherlight'))).toBeTruthy(); }); test('exhibitions_football_designing_the_beautiful_game: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/football-designing-the-beautiful-game/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_football_designing_the_beautiful_game: footer link "Reserve tickets early"', async ({ page }) => { await page.goto('/exhibitions/football-designing-the-beautiful-game/'); 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 === 'Reserve tickets early' || t.startsWith('Reserve tickets early')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_football_designing_the_beautiful_game: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/football-designing-the-beautiful-game/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_football_designing_the_beautiful_game: footer link "Give to our gallery"', async ({ page }) => { await page.goto('/exhibitions/football-designing-the-beautiful-game/'); 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 === 'Give to our gallery' || t.startsWith('Give to our gallery')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_fred_perry_a_british_icon', () => { test('exhibitions_fred_perry_a_british_icon: title matches GT', async ({ page }) => { await page.goto('/exhibitions/fred-perry-a-british-icon/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('halden'); }); test('exhibitions_fred_perry_a_british_icon: h1 "Halden: A Modern Classic"', async ({ page }) => { await page.goto('/exhibitions/fred-perry-a-british-icon/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Halden: A Modern Classic' || t.startsWith('Halden: A Modern Classic'))).toBeTruthy(); }); test('exhibitions_fred_perry_a_british_icon: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/fred-perry-a-british-icon/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_fred_perry_a_british_icon: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/fred-perry-a-british-icon/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_fred_perry_a_british_icon: h2 "2023 Exhibitions"', async ({ page }) => { await page.goto('/exhibitions/fred-perry-a-british-icon/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '2023 Exhibitions' || t.startsWith('2023 Exhibitions'))).toBeTruthy(); }); test('exhibitions_fred_perry_a_british_icon: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/fred-perry-a-british-icon/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_fred_perry_a_british_icon: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/fred-perry-a-british-icon/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_fred_perry_a_british_icon: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/fred-perry-a-british-icon/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_fred_perry_a_british_icon: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/fred-perry-a-british-icon/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_future_exhibitions_and_displays', () => { test('exhibitions_future_exhibitions_and_displays: title matches GT', async ({ page }) => { await page.goto('/exhibitions/future-exhibitions-and-displays/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('upcoming exhibitions and displays'); }); test('exhibitions_future_exhibitions_and_displays: h1 "Upcoming exhibitions and displ"', async ({ page }) => { await page.goto('/exhibitions/future-exhibitions-and-displays/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Upcoming exhibitions and displays' || t.startsWith('Upcoming exhibitions and displays'))).toBeTruthy(); }); test('exhibitions_future_exhibitions_and_displays: h2 "Design Fellows in Residence: S"', async ({ page }) => { await page.goto('/exhibitions/future-exhibitions-and-displays/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Fellows in Residence: Sediment' || t.startsWith('Design Fellows in Residence: Sediment'))).toBeTruthy(); }); test('exhibitions_future_exhibitions_and_displays: h2 "Ivo Maran"', async ({ page }) => { await page.goto('/exhibitions/future-exhibitions-and-displays/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Ivo Maran' || t.startsWith('Ivo Maran'))).toBeTruthy(); }); test('exhibitions_future_exhibitions_and_displays: h2 "The New Material Vision"', async ({ page }) => { await page.goto('/exhibitions/future-exhibitions-and-displays/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The New Material Vision' || t.startsWith('The New Material Vision'))).toBeTruthy(); }); test('exhibitions_future_exhibitions_and_displays: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/future-exhibitions-and-displays/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_future_exhibitions_and_displays: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/exhibitions/future-exhibitions-and-displays/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_future_exhibitions_and_displays: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/future-exhibitions-and-displays/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_future_exhibitions_and_displays: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/future-exhibitions-and-displays/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_future_observatory_display', () => { test('exhibitions_future_observatory_display: title matches GT', async ({ page }) => { await page.goto('/exhibitions/future-observatory-display/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('regenerative field display'); }); test('exhibitions_future_observatory_display: h1 "Regenerative Field display"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-display/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Regenerative Field display' || t.startsWith('Regenerative Field display'))).toBeTruthy(); }); test('exhibitions_future_observatory_display: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-display/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_future_observatory_display: h2 "SALTWORKS"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-display/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'SALTWORKS' || t.startsWith('SALTWORKS'))).toBeTruthy(); }); test('exhibitions_future_observatory_display: h2 "Hidden Field Lab"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-display/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Hidden Field Lab' || t.startsWith('Hidden Field Lab'))).toBeTruthy(); }); test('exhibitions_future_observatory_display: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-display/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_future_observatory_display: footer link "Book tickets ahead"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-display/'); 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 === 'Book tickets ahead' || t.startsWith('Book tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_future_observatory_display: footer link "Become a friend"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-display/'); 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 === 'Become a friend' || t.startsWith('Become a friend')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_future_observatory_display: footer link "Support our gallery"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-display/'); 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 === 'Support our gallery' || t.startsWith('Support our gallery')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_future_observatory_tomorrows_wardrobe', () => { test('exhibitions_future_observatory_tomorrows_wardrobe: title matches GT', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tomorrows-wardrobe/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('horizon lab'); }); test('exhibitions_future_observatory_tomorrows_wardrobe: h1 "Horizon Lab: Dressing for Tomo"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tomorrows-wardrobe/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Horizon Lab: Dressing for Tomorrow' || t.startsWith('Horizon Lab: Dressing for Tomorrow'))).toBeTruthy(); }); test('exhibitions_future_observatory_tomorrows_wardrobe: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tomorrows-wardrobe/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_future_observatory_tomorrows_wardrobe: h2 "Visit information"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tomorrows-wardrobe/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Visit information' || t.startsWith('Visit information'))).toBeTruthy(); }); test('exhibitions_future_observatory_tomorrows_wardrobe: h2 "In partnership with"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tomorrows-wardrobe/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In partnership with' || t.startsWith('In partnership with'))).toBeTruthy(); }); test('exhibitions_future_observatory_tomorrows_wardrobe: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tomorrows-wardrobe/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_future_observatory_tomorrows_wardrobe: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tomorrows-wardrobe/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_future_observatory_tomorrows_wardrobe: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tomorrows-wardrobe/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_future_observatory_tomorrows_wardrobe: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tomorrows-wardrobe/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_future_observatory_tools_for_transition', () => { test('exhibitions_future_observatory_tools_for_transition: title matches GT', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tools-for-transition/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('horizon observatory'); }); test('exhibitions_future_observatory_tools_for_transition: h1 "Horizon Observatory: Systems f"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tools-for-transition/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Horizon Observatory: Systems for Renewal' || t.startsWith('Horizon Observatory: Systems for Renewal'))).toBeTruthy(); }); test('exhibitions_future_observatory_tools_for_transition: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tools-for-transition/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_future_observatory_tools_for_transition: h2 "Commissions"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tools-for-transition/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Commissions' || t.startsWith('Commissions'))).toBeTruthy(); }); test('exhibitions_future_observatory_tools_for_transition: h2 "The Horizon Commons"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tools-for-transition/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Horizon Commons' || t.startsWith('The Horizon Commons'))).toBeTruthy(); }); test('exhibitions_future_observatory_tools_for_transition: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tools-for-transition/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_future_observatory_tools_for_transition: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tools-for-transition/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_future_observatory_tools_for_transition: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tools-for-transition/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_future_observatory_tools_for_transition: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/future-observatory-tools-for-transition/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_grazie_enzo_contemporary_responses_to_enzo_mari', () => { test('exhibitions_grazie_enzo_contemporary_responses_to_enzo_mari: title matches GT', async ({ page }) => { await page.goto('/exhibitions/grazie-enzo-contemporary-responses-to-enzo-mari/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('merci aldo'); }); test('exhibitions_grazie_enzo_contemporary_responses_to_enzo_mari: h1 "Merci Aldo: Contemporary Respo"', async ({ page }) => { await page.goto('/exhibitions/grazie-enzo-contemporary-responses-to-enzo-mari/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Merci Aldo: Contemporary Responses to Aldo Ferro' || t.startsWith('Merci Aldo: Contemporary Responses to Aldo Ferro'))).toBeTruthy(); }); test('exhibitions_grazie_enzo_contemporary_responses_to_enzo_mari: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/grazie-enzo-contemporary-responses-to-enzo-mari/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_grazie_enzo_contemporary_responses_to_enzo_mari: h2 "A Studio for Everyday Making"', async ({ page }) => { await page.goto('/exhibitions/grazie-enzo-contemporary-responses-to-enzo-mari/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'A Studio for Everyday Making' || t.startsWith('A Studio for Everyday Making'))).toBeTruthy(); }); test('exhibitions_grazie_enzo_contemporary_responses_to_enzo_mari: h2 "Matteo Grandi"', async ({ page }) => { await page.goto('/exhibitions/grazie-enzo-contemporary-responses-to-enzo-mari/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Matteo Grandi' || t.startsWith('Matteo Grandi'))).toBeTruthy(); }); test('exhibitions_grazie_enzo_contemporary_responses_to_enzo_mari: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/grazie-enzo-contemporary-responses-to-enzo-mari/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_grazie_enzo_contemporary_responses_to_enzo_mari: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/grazie-enzo-contemporary-responses-to-enzo-mari/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_grazie_enzo_contemporary_responses_to_enzo_mari: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/grazie-enzo-contemporary-responses-to-enzo-mari/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_grazie_enzo_contemporary_responses_to_enzo_mari: footer link "Support the gallery"', async ({ page }) => { await page.goto('/exhibitions/grazie-enzo-contemporary-responses-to-enzo-mari/'); 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 === 'Support the gallery' || t.startsWith('Support the gallery')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_harland_miller_at_the_design_museum', () => { test('exhibitions_harland_miller_at_the_design_museum: title matches GT', async ({ page }) => { await page.goto('/exhibitions/harland-miller-at-the-design-museum/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('oren vale at the formora museum'); }); test('exhibitions_harland_miller_at_the_design_museum: h1 "Oren Vale at the Formora Museu"', async ({ page }) => { await page.goto('/exhibitions/harland-miller-at-the-design-museum/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Oren Vale at the Formora Museum' || t.startsWith('Oren Vale at the Formora Museum'))).toBeTruthy(); }); test('exhibitions_harland_miller_at_the_design_museum: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/harland-miller-at-the-design-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_harland_miller_at_the_design_museum: h2 "Visit Information"', async ({ page }) => { await page.goto('/exhibitions/harland-miller-at-the-design-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Visit Information' || t.startsWith('Visit Information'))).toBeTruthy(); }); test('exhibitions_harland_miller_at_the_design_museum: h2 "Oren Vale at the Formora Museu"', async ({ page }) => { await page.goto('/exhibitions/harland-miller-at-the-design-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Oren Vale at the Formora Museum Shop' || t.startsWith('Oren Vale at the Formora Museum Shop'))).toBeTruthy(); }); test('exhibitions_harland_miller_at_the_design_museum: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/harland-miller-at-the-design-museum/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_harland_miller_at_the_design_museum: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/harland-miller-at-the-design-museum/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_harland_miller_at_the_design_museum: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/harland-miller-at-the-design-museum/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_harland_miller_at_the_design_museum: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/harland-miller-at-the-design-museum/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_homage_to_carnival', () => { test('exhibitions_homage_to_carnival: title matches GT', async ({ page }) => { await page.goto('/exhibitions/homage-to-carnival/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('tribute to the tides'); }); test('exhibitions_homage_to_carnival: h1 "Tribute to the Tides"', async ({ page }) => { await page.goto('/exhibitions/homage-to-carnival/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Tribute to the Tides' || t.startsWith('Tribute to the Tides'))).toBeTruthy(); }); test('exhibitions_homage_to_carnival: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/homage-to-carnival/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_homage_to_carnival: h2 "About the artist Ines Valadar"', async ({ page }) => { await page.goto('/exhibitions/homage-to-carnival/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'About the artist Ines Valadar' || t.startsWith('About the artist Ines Valadar'))).toBeTruthy(); }); test('exhibitions_homage_to_carnival: h2 "Riverside Art Trail"', async ({ page }) => { await page.goto('/exhibitions/homage-to-carnival/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Riverside Art Trail' || t.startsWith('Riverside Art Trail'))).toBeTruthy(); }); test('exhibitions_homage_to_carnival: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/homage-to-carnival/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_homage_to_carnival: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/homage-to-carnival/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_homage_to_carnival: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/homage-to-carnival/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_homage_to_carnival: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/homage-to-carnival/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_hope_to_nope_graphics_and_politics_2008_18', () => { test('exhibitions_hope_to_nope_graphics_and_politics_2008_18: title matches GT', async ({ page }) => { await page.goto('/exhibitions/hope-to-nope-graphics-and-politics-2008-18/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('vote to void'); }); test('exhibitions_hope_to_nope_graphics_and_politics_2008_18: h1 "Vote to Void: Graphics and Pro"', async ({ page }) => { await page.goto('/exhibitions/hope-to-nope-graphics-and-politics-2008-18/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Vote to Void: Graphics and Protest 2010-20' || t.startsWith('Vote to Void: Graphics and Protest 2010-20'))).toBeTruthy(); }); test('exhibitions_hope_to_nope_graphics_and_politics_2008_18: h2 "Exhibition free from 3 to 14 O"', async ({ page }) => { await page.goto('/exhibitions/hope-to-nope-graphics-and-politics-2008-18/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Exhibition free from 3 to 14 October' || t.startsWith('Exhibition free from 3 to 14 October'))).toBeTruthy(); }); test('exhibitions_hope_to_nope_graphics_and_politics_2008_18: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/hope-to-nope-graphics-and-politics-2008-18/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_hope_to_nope_graphics_and_politics_2008_18: h2 "Vote to Void In-Depth"', async ({ page }) => { await page.goto('/exhibitions/hope-to-nope-graphics-and-politics-2008-18/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Vote to Void In-Depth' || t.startsWith('Vote to Void In-Depth'))).toBeTruthy(); }); test('exhibitions_hope_to_nope_graphics_and_politics_2008_18: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/hope-to-nope-graphics-and-politics-2008-18/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_hope_to_nope_graphics_and_politics_2008_18: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/hope-to-nope-graphics-and-politics-2008-18/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_hope_to_nope_graphics_and_politics_2008_18: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/hope-to-nope-graphics-and-politics-2008-18/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_hope_to_nope_graphics_and_politics_2008_18: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/hope-to-nope-graphics-and-politics-2008-18/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_how_to_build_a_low_carbon_home', () => { test('exhibitions_how_to_build_a_low_carbon_home: title matches GT', async ({ page }) => { await page.goto('/exhibitions/how-to-build-a-low-carbon-home/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('building the low'); }); test('exhibitions_how_to_build_a_low_carbon_home: h1 "Building the Low-Carbon Home"', async ({ page }) => { await page.goto('/exhibitions/how-to-build-a-low-carbon-home/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Building the Low-Carbon Home' || t.startsWith('Building the Low-Carbon Home'))).toBeTruthy(); }); test('exhibitions_how_to_build_a_low_carbon_home: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/how-to-build-a-low-carbon-home/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_how_to_build_a_low_carbon_home: h2 "Visit Information"', async ({ page }) => { await page.goto('/exhibitions/how-to-build-a-low-carbon-home/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Visit Information' || t.startsWith('Visit Information'))).toBeTruthy(); }); test('exhibitions_how_to_build_a_low_carbon_home: h2 "Green Horizon Lab"', async ({ page }) => { await page.goto('/exhibitions/how-to-build-a-low-carbon-home/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Green Horizon Lab' || t.startsWith('Green Horizon Lab'))).toBeTruthy(); }); test('exhibitions_how_to_build_a_low_carbon_home: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/how-to-build-a-low-carbon-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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_how_to_build_a_low_carbon_home: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/how-to-build-a-low-carbon-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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_how_to_build_a_low_carbon_home: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/how-to-build-a-low-carbon-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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_how_to_build_a_low_carbon_home: footer link "Support our work"', async ({ page }) => { await page.goto('/exhibitions/how-to-build-a-low-carbon-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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_loewe_craft_prize_2018', () => { test('exhibitions_loewe_craft_prize_2018: title matches GT', async ({ page }) => { await page.goto('/exhibitions/loewe-craft-prize-2018/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('formora craft prize 2018'); }); test('exhibitions_loewe_craft_prize_2018: h1 "Formora Craft Prize 2018"', async ({ page }) => { await page.goto('/exhibitions/loewe-craft-prize-2018/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Formora Craft Prize 2018' || t.startsWith('Formora Craft Prize 2018'))).toBeTruthy(); }); test('exhibitions_loewe_craft_prize_2018: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/loewe-craft-prize-2018/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_loewe_craft_prize_2018: h2 "The selected finalists for the"', async ({ page }) => { await page.goto('/exhibitions/loewe-craft-prize-2018/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The selected finalists for the Formora Craft Prize 2018 are:' || t.startsWith('The selected finalists for the Formora Craft Prize 2018 are:'))).toBeTruthy(); }); test('exhibitions_loewe_craft_prize_2018: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/loewe-craft-prize-2018/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_loewe_craft_prize_2018: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/loewe-craft-prize-2018/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_loewe_craft_prize_2018: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/loewe-craft-prize-2018/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_loewe_craft_prize_2018: footer link "Support our work"', async ({ page }) => { await page.goto('/exhibitions/loewe-craft-prize-2018/'); 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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_margaret_calvert_woman_at_work', () => { test('exhibitions_margaret_calvert_woman_at_work: title matches GT', async ({ page }) => { await page.goto('/exhibitions/margaret-calvert-woman-at-work/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('ada renwick'); }); test('exhibitions_margaret_calvert_woman_at_work: h1 "Ada Renwick: Designing in Publ"', async ({ page }) => { await page.goto('/exhibitions/margaret-calvert-woman-at-work/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Ada Renwick: Designing in Public' || t.startsWith('Ada Renwick: Designing in Public'))).toBeTruthy(); }); test('exhibitions_margaret_calvert_woman_at_work: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/margaret-calvert-woman-at-work/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_margaret_calvert_woman_at_work: h2 "Advance booking only"', async ({ page }) => { await page.goto('/exhibitions/margaret-calvert-woman-at-work/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Advance booking only' || t.startsWith('Advance booking only'))).toBeTruthy(); }); test('exhibitions_margaret_calvert_woman_at_work: h2 "Get closer with membership"', async ({ page }) => { await page.goto('/exhibitions/margaret-calvert-woman-at-work/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Get closer with membership' || t.startsWith('Get closer with membership'))).toBeTruthy(); }); test('exhibitions_margaret_calvert_woman_at_work: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/margaret-calvert-woman-at-work/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_margaret_calvert_woman_at_work: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/margaret-calvert-woman-at-work/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_margaret_calvert_woman_at_work: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/margaret-calvert-woman-at-work/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_margaret_calvert_woman_at_work: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/margaret-calvert-woman-at-work/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_marina_willer_x_pith_sketching_with_stickers', () => { test('exhibitions_marina_willer_x_pith_sketching_with_stickers: title matches GT', async ({ page }) => { await page.goto('/exhibitions/marina-willer-x-pith-sketching-with-stickers/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('lena verrow x verso'); }); test('exhibitions_marina_willer_x_pith_sketching_with_stickers: h1 "Lena Verrow x Verso: Sketching"', async ({ page }) => { await page.goto('/exhibitions/marina-willer-x-pith-sketching-with-stickers/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lena Verrow x Verso: Sketching with Stickers' || t.startsWith('Lena Verrow x Verso: Sketching with Stickers'))).toBeTruthy(); }); test('exhibitions_marina_willer_x_pith_sketching_with_stickers: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/marina-willer-x-pith-sketching-with-stickers/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_marina_willer_x_pith_sketching_with_stickers: h2 "Lena Verrow"', async ({ page }) => { await page.goto('/exhibitions/marina-willer-x-pith-sketching-with-stickers/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Lena Verrow' || t.startsWith('Lena Verrow'))).toBeTruthy(); }); test('exhibitions_marina_willer_x_pith_sketching_with_stickers: h2 "Verso®"', async ({ page }) => { await page.goto('/exhibitions/marina-willer-x-pith-sketching-with-stickers/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Verso®' || t.startsWith('Verso®'))).toBeTruthy(); }); test('exhibitions_marina_willer_x_pith_sketching_with_stickers: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/marina-willer-x-pith-sketching-with-stickers/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_marina_willer_x_pith_sketching_with_stickers: footer link "Book tickets online"', async ({ page }) => { await page.goto('/exhibitions/marina-willer-x-pith-sketching-with-stickers/'); 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 === 'Book tickets online' || t.startsWith('Book tickets online')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_marina_willer_x_pith_sketching_with_stickers: footer link "Join as member"', async ({ page }) => { await page.goto('/exhibitions/marina-willer-x-pith-sketching-with-stickers/'); 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 === 'Join as member' || t.startsWith('Join as member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_marina_willer_x_pith_sketching_with_stickers: footer link "Give a donation"', async ({ page }) => { await page.goto('/exhibitions/marina-willer-x-pith-sketching-with-stickers/'); 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 === 'Give a donation' || t.startsWith('Give a donation')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_momentum_a_design_narrative_by_istituto_marangoni_london', () => { test('exhibitions_momentum_a_design_narrative_by_istituto_marangoni_london: title matches GT', async ({ page }) => { await page.goto('/exhibitions/momentum-a-design-narrative-by-istituto-marangoni-london/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('threshold'); }); test('exhibitions_momentum_a_design_narrative_by_istituto_marangoni_london: h1 "Threshold: A Design Narrative "', async ({ page }) => { await page.goto('/exhibitions/momentum-a-design-narrative-by-istituto-marangoni-london/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Threshold: A Design Narrative by the Meridian College of Design' || t.startsWith('Threshold: A Design Narrative by the Meridian College of Design'))).toBeTruthy(); }); test('exhibitions_momentum_a_design_narrative_by_istituto_marangoni_london: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/momentum-a-design-narrative-by-istituto-marangoni-london/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_momentum_a_design_narrative_by_istituto_marangoni_london: h2 "In partnership with"', async ({ page }) => { await page.goto('/exhibitions/momentum-a-design-narrative-by-istituto-marangoni-london/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In partnership with' || t.startsWith('In partnership with'))).toBeTruthy(); }); test('exhibitions_momentum_a_design_narrative_by_istituto_marangoni_london: h2 "Visitor essentials"', async ({ page }) => { await page.goto('/exhibitions/momentum-a-design-narrative-by-istituto-marangoni-london/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Visitor essentials' || t.startsWith('Visitor essentials'))).toBeTruthy(); }); test('exhibitions_momentum_a_design_narrative_by_istituto_marangoni_london: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/momentum-a-design-narrative-by-istituto-marangoni-london/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_momentum_a_design_narrative_by_istituto_marangoni_london: footer link "Book tickets ahead"', async ({ page }) => { await page.goto('/exhibitions/momentum-a-design-narrative-by-istituto-marangoni-london/'); 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 === 'Book tickets ahead' || t.startsWith('Book tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_momentum_a_design_narrative_by_istituto_marangoni_london: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/momentum-a-design-narrative-by-istituto-marangoni-london/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_momentum_a_design_narrative_by_istituto_marangoni_london: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/momentum-a-design-narrative-by-istituto-marangoni-london/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_more_than_human', () => { test('exhibitions_more_than_human: title matches GT', async ({ page }) => { await page.goto('/exhibitions/more-than-human/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('kinship'); }); test('exhibitions_more_than_human: h1 "Kinship"', async ({ page }) => { await page.goto('/exhibitions/more-than-human/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Kinship' || t.startsWith('Kinship'))).toBeTruthy(); }); test('exhibitions_more_than_human: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/more-than-human/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_more_than_human: h2 "Booking Information"', async ({ page }) => { await page.goto('/exhibitions/more-than-human/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking Information' || t.startsWith('Booking Information'))).toBeTruthy(); }); test('exhibitions_more_than_human: h2 "Accessibility guide"', async ({ page }) => { await page.goto('/exhibitions/more-than-human/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Accessibility guide' || t.startsWith('Accessibility guide'))).toBeTruthy(); }); test('exhibitions_more_than_human: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/more-than-human/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_more_than_human: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/exhibitions/more-than-human/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_more_than_human: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/more-than-human/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_more_than_human: footer link "Support our work"', async ({ page }) => { await page.goto('/exhibitions/more-than-human/'); 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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_moving_to_mars', () => { test('exhibitions_moving_to_mars: title matches GT', async ({ page }) => { await page.goto('/exhibitions/moving-to-mars/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('moving to mars'); }); test('exhibitions_moving_to_mars: h1 "Moving to Mars"', async ({ page }) => { await page.goto('/exhibitions/moving-to-mars/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Moving to Mars' || t.startsWith('Moving to Mars'))).toBeTruthy(); }); test('exhibitions_moving_to_mars: h2 "What the Press said"', async ({ page }) => { await page.goto('/exhibitions/moving-to-mars/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What the Press said' || t.startsWith('What the Press said'))).toBeTruthy(); }); test('exhibitions_moving_to_mars: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/moving-to-mars/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_moving_to_mars: h2 "Walk the Red Planet"', async ({ page }) => { await page.goto('/exhibitions/moving-to-mars/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Walk the Red Planet' || t.startsWith('Walk the Red Planet'))).toBeTruthy(); }); test('exhibitions_moving_to_mars: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/moving-to-mars/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_moving_to_mars: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/exhibitions/moving-to-mars/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_moving_to_mars: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/moving-to-mars/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_moving_to_mars: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/moving-to-mars/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_nigo_from_japan_with_love', () => { test('exhibitions_nigo_from_japan_with_love: title matches GT', async ({ page }) => { await page.goto('/exhibitions/nigo-from-japan-with-love/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('luma'); }); test('exhibitions_nigo_from_japan_with_love: h1 "LUMA: A Life Among Objects"', async ({ page }) => { await page.goto('/exhibitions/nigo-from-japan-with-love/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'LUMA: A Life Among Objects' || t.startsWith('LUMA: A Life Among Objects'))).toBeTruthy(); }); test('exhibitions_nigo_from_japan_with_love: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/nigo-from-japan-with-love/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_nigo_from_japan_with_love: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/nigo-from-japan-with-love/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_nigo_from_japan_with_love: h2 "Marisol: From Sea to Studio"', async ({ page }) => { await page.goto('/exhibitions/nigo-from-japan-with-love/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Marisol: From Sea to Studio' || t.startsWith('Marisol: From Sea to Studio'))).toBeTruthy(); }); test('exhibitions_nigo_from_japan_with_love: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/nigo-from-japan-with-love/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_nigo_from_japan_with_love: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/exhibitions/nigo-from-japan-with-love/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_nigo_from_japan_with_love: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/nigo-from-japan-with-love/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_nigo_from_japan_with_love: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/nigo-from-japan-with-love/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_objects_of_desire_surrealism_and_design_1924_today', () => { test('exhibitions_objects_of_desire_surrealism_and_design_1924_today: title matches GT', async ({ page }) => { await page.goto('/exhibitions/objects-of-desire-surrealism-and-design-1924-today/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('realms of reverie'); }); test('exhibitions_objects_of_desire_surrealism_and_design_1924_today: h1 "Realms of Reverie: Surrealism "', async ({ page }) => { await page.goto('/exhibitions/objects-of-desire-surrealism-and-design-1924-today/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Realms of Reverie: Surrealism and Design 1924 – Today' || t.startsWith('Realms of Reverie: Surrealism and Design 1924 – Today'))).toBeTruthy(); }); test('exhibitions_objects_of_desire_surrealism_and_design_1924_today: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/objects-of-desire-surrealism-and-design-1924-today/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_objects_of_desire_surrealism_and_design_1924_today: h2 "Ticket Information"', async ({ page }) => { await page.goto('/exhibitions/objects-of-desire-surrealism-and-design-1924-today/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Ticket Information' || t.startsWith('Ticket Information'))).toBeTruthy(); }); test('exhibitions_objects_of_desire_surrealism_and_design_1924_today: h2 "Get closer with membership"', async ({ page }) => { await page.goto('/exhibitions/objects-of-desire-surrealism-and-design-1924-today/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Get closer with membership' || t.startsWith('Get closer with membership'))).toBeTruthy(); }); test('exhibitions_objects_of_desire_surrealism_and_design_1924_today: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/objects-of-desire-surrealism-and-design-1924-today/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_objects_of_desire_surrealism_and_design_1924_today: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/objects-of-desire-surrealism-and-design-1924-today/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_objects_of_desire_surrealism_and_design_1924_today: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/objects-of-desire-surrealism-and-design-1924-today/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_objects_of_desire_surrealism_and_design_1924_today: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/objects-of-desire-surrealism-and-design-1924-today/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_open_monuments_by_melek_zeynep_bulut', () => { test('exhibitions_open_monuments_by_melek_zeynep_bulut: title matches GT', async ({ page }) => { await page.goto('/exhibitions/open-monuments-by-melek-zeynep-bulut/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('living thresholds by ravenna costa'); }); test('exhibitions_open_monuments_by_melek_zeynep_bulut: h1 "Living Thresholds by Ravenna C"', async ({ page }) => { await page.goto('/exhibitions/open-monuments-by-melek-zeynep-bulut/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Living Thresholds by Ravenna Costa' || t.startsWith('Living Thresholds by Ravenna Costa'))).toBeTruthy(); }); test('exhibitions_open_monuments_by_melek_zeynep_bulut: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/open-monuments-by-melek-zeynep-bulut/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_open_monuments_by_melek_zeynep_bulut: h2 "About the project"', async ({ page }) => { await page.goto('/exhibitions/open-monuments-by-melek-zeynep-bulut/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'About the project' || t.startsWith('About the project'))).toBeTruthy(); }); test('exhibitions_open_monuments_by_melek_zeynep_bulut: h2 "About the artist"', async ({ page }) => { await page.goto('/exhibitions/open-monuments-by-melek-zeynep-bulut/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'About the artist' || t.startsWith('About the artist'))).toBeTruthy(); }); test('exhibitions_open_monuments_by_melek_zeynep_bulut: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/open-monuments-by-melek-zeynep-bulut/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_open_monuments_by_melek_zeynep_bulut: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/open-monuments-by-melek-zeynep-bulut/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_open_monuments_by_melek_zeynep_bulut: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/open-monuments-by-melek-zeynep-bulut/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_open_monuments_by_melek_zeynep_bulut: footer link "Support our work"', async ({ page }) => { await page.goto('/exhibitions/open-monuments-by-melek-zeynep-bulut/'); 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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_past_exhibitions', () => { test('exhibitions_past_exhibitions: title matches GT', async ({ page }) => { await page.goto('/exhibitions/past-exhibitions/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('past exhibitions'); }); test('exhibitions_past_exhibitions: h1 "Past Exhibitions"', async ({ page }) => { await page.goto('/exhibitions/past-exhibitions/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Past Exhibitions' || t.startsWith('Past Exhibitions'))).toBeTruthy(); }); test('exhibitions_past_exhibitions: h2 "2026"', async ({ page }) => { await page.goto('/exhibitions/past-exhibitions/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '2026' || t.startsWith('2026'))).toBeTruthy(); }); test('exhibitions_past_exhibitions: h2 "2025"', async ({ page }) => { await page.goto('/exhibitions/past-exhibitions/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '2025' || t.startsWith('2025'))).toBeTruthy(); }); test('exhibitions_past_exhibitions: h2 "2024"', async ({ page }) => { await page.goto('/exhibitions/past-exhibitions/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === '2024' || t.startsWith('2024'))).toBeTruthy(); }); test('exhibitions_past_exhibitions: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/past-exhibitions/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_past_exhibitions: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/exhibitions/past-exhibitions/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_past_exhibitions: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/past-exhibitions/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_past_exhibitions: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/past-exhibitions/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_platform_bethan_laura_wood', () => { test('exhibitions_platform_bethan_laura_wood: title matches GT', async ({ page }) => { await page.goto('/exhibitions/platform-bethan-laura-wood/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('prospect'); }); test('exhibitions_platform_bethan_laura_wood: h1 "PROSPECT: Marisol Vantetti"', async ({ page }) => { await page.goto('/exhibitions/platform-bethan-laura-wood/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'PROSPECT: Marisol Vantetti' || t.startsWith('PROSPECT: Marisol Vantetti'))).toBeTruthy(); }); test('exhibitions_platform_bethan_laura_wood: h2 "Marisol Vantetti"', async ({ page }) => { await page.goto('/exhibitions/platform-bethan-laura-wood/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Marisol Vantetti' || t.startsWith('Marisol Vantetti'))).toBeTruthy(); }); test('exhibitions_platform_bethan_laura_wood: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/platform-bethan-laura-wood/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_platform_bethan_laura_wood: h2 "PROSPECT: Marisol Vantetti Cat"', async ({ page }) => { await page.goto('/exhibitions/platform-bethan-laura-wood/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'PROSPECT: Marisol Vantetti Catalogue' || t.startsWith('PROSPECT: Marisol Vantetti Catalogue'))).toBeTruthy(); }); test('exhibitions_platform_bethan_laura_wood: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/platform-bethan-laura-wood/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_platform_bethan_laura_wood: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/exhibitions/platform-bethan-laura-wood/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_platform_bethan_laura_wood: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/platform-bethan-laura-wood/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_platform_bethan_laura_wood: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/platform-bethan-laura-wood/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_rebel_30_years_of_london_fashion', () => { test('exhibitions_rebel_30_years_of_london_fashion: title matches GT', async ({ page }) => { await page.goto('/exhibitions/rebel-30-years-of-london-fashion/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('uprising'); }); test('exhibitions_rebel_30_years_of_london_fashion: h1 "UPRISING: Three Decades of Des"', async ({ page }) => { await page.goto('/exhibitions/rebel-30-years-of-london-fashion/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'UPRISING: Three Decades of Design' || t.startsWith('UPRISING: Three Decades of Design'))).toBeTruthy(); }); test('exhibitions_rebel_30_years_of_london_fashion: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/rebel-30-years-of-london-fashion/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_rebel_30_years_of_london_fashion: h2 "Booking Information"', async ({ page }) => { await page.goto('/exhibitions/rebel-30-years-of-london-fashion/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking Information' || t.startsWith('Booking Information'))).toBeTruthy(); }); test('exhibitions_rebel_30_years_of_london_fashion: h2 "Members go free"', async ({ page }) => { await page.goto('/exhibitions/rebel-30-years-of-london-fashion/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Members go free' || t.startsWith('Members go free'))).toBeTruthy(); }); test('exhibitions_rebel_30_years_of_london_fashion: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/rebel-30-years-of-london-fashion/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_rebel_30_years_of_london_fashion: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/exhibitions/rebel-30-years-of-london-fashion/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_rebel_30_years_of_london_fashion: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/rebel-30-years-of-london-fashion/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_rebel_30_years_of_london_fashion: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/rebel-30-years-of-london-fashion/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_splash_a_century_of_swimming_and_style', () => { test('exhibitions_splash_a_century_of_swimming_and_style: title matches GT', async ({ page }) => { await page.goto('/exhibitions/splash-a-century-of-swimming-and-style/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('splash! a century of swimming and style'); }); test('exhibitions_splash_a_century_of_swimming_and_style: h1 "Splash! A Century of Swimming "', async ({ page }) => { await page.goto('/exhibitions/splash-a-century-of-swimming-and-style/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Splash! A Century of Swimming and Style' || t.startsWith('Splash! A Century of Swimming and Style'))).toBeTruthy(); }); test('exhibitions_splash_a_century_of_swimming_and_style: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/splash-a-century-of-swimming-and-style/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_splash_a_century_of_swimming_and_style: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/splash-a-century-of-swimming-and-style/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_splash_a_century_of_swimming_and_style: h2 "Access: Large Print Guide & Se"', async ({ page }) => { await page.goto('/exhibitions/splash-a-century-of-swimming-and-style/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Access: Large Print Guide & Sensory Map' || t.startsWith('Access: Large Print Guide & Sensory Map'))).toBeTruthy(); }); test('exhibitions_splash_a_century_of_swimming_and_style: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/splash-a-century-of-swimming-and-style/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_splash_a_century_of_swimming_and_style: footer link "Get advance tickets"', async ({ page }) => { await page.goto('/exhibitions/splash-a-century-of-swimming-and-style/'); 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 === 'Get advance tickets' || t.startsWith('Get advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_splash_a_century_of_swimming_and_style: footer link "Join as member"', async ({ page }) => { await page.goto('/exhibitions/splash-a-century-of-swimming-and-style/'); 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 === 'Join as member' || t.startsWith('Join as member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_splash_a_century_of_swimming_and_style: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/splash-a-century-of-swimming-and-style/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_stanley_kubrick_the_exhibition', () => { test('exhibitions_stanley_kubrick_the_exhibition: title matches GT', async ({ page }) => { await page.goto('/exhibitions/stanley-kubrick-the-exhibition/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('rowan vesper'); }); test('exhibitions_stanley_kubrick_the_exhibition: h1 "Rowan Vesper: The Exhibition"', async ({ page }) => { await page.goto('/exhibitions/stanley-kubrick-the-exhibition/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Rowan Vesper: The Exhibition' || t.startsWith('Rowan Vesper: The Exhibition'))).toBeTruthy(); }); test('exhibitions_stanley_kubrick_the_exhibition: h2 "Thanks to"', async ({ page }) => { await page.goto('/exhibitions/stanley-kubrick-the-exhibition/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Thanks to' || t.startsWith('Thanks to'))).toBeTruthy(); }); test('exhibitions_stanley_kubrick_the_exhibition: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/stanley-kubrick-the-exhibition/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_stanley_kubrick_the_exhibition: h2 "Ticketing information"', async ({ page }) => { await page.goto('/exhibitions/stanley-kubrick-the-exhibition/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Ticketing information' || t.startsWith('Ticketing information'))).toBeTruthy(); }); test('exhibitions_stanley_kubrick_the_exhibition: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/stanley-kubrick-the-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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_stanley_kubrick_the_exhibition: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/exhibitions/stanley-kubrick-the-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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_stanley_kubrick_the_exhibition: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/stanley-kubrick-the-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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_stanley_kubrick_the_exhibition: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/stanley-kubrick-the-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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_the_future_of_ageing', () => { test('exhibitions_the_future_of_ageing: title matches GT', async ({ page }) => { await page.goto('/exhibitions/the-future-of-ageing/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('designing later life'); }); test('exhibitions_the_future_of_ageing: h1 "Designing Later Life"', async ({ page }) => { await page.goto('/exhibitions/the-future-of-ageing/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Designing Later Life' || t.startsWith('Designing Later Life'))).toBeTruthy(); }); test('exhibitions_the_future_of_ageing: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/the-future-of-ageing/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_the_future_of_ageing: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/the-future-of-ageing/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_the_future_of_ageing: h2 "Designing for Dignity & Deligh"', async ({ page }) => { await page.goto('/exhibitions/the-future-of-ageing/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Designing for Dignity & Delight' || t.startsWith('Designing for Dignity & Delight'))).toBeTruthy(); }); test('exhibitions_the_future_of_ageing: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/the-future-of-ageing/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_the_future_of_ageing: footer link "Book tickets ahead"', async ({ page }) => { await page.goto('/exhibitions/the-future-of-ageing/'); 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 === 'Book tickets ahead' || t.startsWith('Book tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_future_of_ageing: footer link "Join as member"', async ({ page }) => { await page.goto('/exhibitions/the-future-of-ageing/'); 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 === 'Join as member' || t.startsWith('Join as member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_future_of_ageing: footer link "Give to Formora"', async ({ page }) => { await page.goto('/exhibitions/the-future-of-ageing/'); 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 === 'Give to Formora' || t.startsWith('Give to Formora')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_the_nue_black_aesthetic', () => { test('exhibitions_the_nue_black_aesthetic: title matches GT', async ({ page }) => { await page.goto('/exhibitions/the-nue-black-aesthetic/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('the shape of belonging'); }); test('exhibitions_the_nue_black_aesthetic: h1 "The Shape of Belonging"', async ({ page }) => { await page.goto('/exhibitions/the-nue-black-aesthetic/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Shape of Belonging' || t.startsWith('The Shape of Belonging'))).toBeTruthy(); }); test('exhibitions_the_nue_black_aesthetic: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/the-nue-black-aesthetic/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_the_nue_black_aesthetic: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/the-nue-black-aesthetic/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_the_nue_black_aesthetic: h2 "Plan your visit"', async ({ page }) => { await page.goto('/exhibitions/the-nue-black-aesthetic/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Plan your visit' || t.startsWith('Plan your visit'))).toBeTruthy(); }); test('exhibitions_the_nue_black_aesthetic: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/the-nue-black-aesthetic/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_the_nue_black_aesthetic: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/the-nue-black-aesthetic/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_nue_black_aesthetic: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/the-nue-black-aesthetic/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_nue_black_aesthetic: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/the-nue-black-aesthetic/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_the_oak_collection', () => { test('exhibitions_the_oak_collection: title matches GT', async ({ page }) => { await page.goto('/exhibitions/the-oak-collection/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('the oak collection'); }); test('exhibitions_the_oak_collection: h1 "The Oak Collection"', async ({ page }) => { await page.goto('/exhibitions/the-oak-collection/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Oak Collection' || t.startsWith('The Oak Collection'))).toBeTruthy(); }); test('exhibitions_the_oak_collection: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/the-oak-collection/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_the_oak_collection: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/the-oak-collection/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_the_oak_collection: h2 "Membership"', async ({ page }) => { await page.goto('/exhibitions/the-oak-collection/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Membership' || t.startsWith('Membership'))).toBeTruthy(); }); test('exhibitions_the_oak_collection: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/the-oak-collection/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_the_oak_collection: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/the-oak-collection/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_oak_collection: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/the-oak-collection/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_oak_collection: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/the-oak-collection/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_the_offbeat_sari', () => { test('exhibitions_the_offbeat_sari: title matches GT', async ({ page }) => { await page.goto('/exhibitions/the-offbeat-sari/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('the kinetic loom'); }); test('exhibitions_the_offbeat_sari: h1 "The Kinetic Loom"', async ({ page }) => { await page.goto('/exhibitions/the-offbeat-sari/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Kinetic Loom' || t.startsWith('The Kinetic Loom'))).toBeTruthy(); }); test('exhibitions_the_offbeat_sari: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/the-offbeat-sari/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_the_offbeat_sari: h2 "Booking Information"', async ({ page }) => { await page.goto('/exhibitions/the-offbeat-sari/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking Information' || t.startsWith('Booking Information'))).toBeTruthy(); }); test('exhibitions_the_offbeat_sari: h2 "Unmissable highlights from #Th"', async ({ page }) => { await page.goto('/exhibitions/the-offbeat-sari/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Unmissable highlights from #TheKineticLoom' || t.startsWith('Unmissable highlights from #TheKineticLoom'))).toBeTruthy(); }); test('exhibitions_the_offbeat_sari: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/the-offbeat-sari/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_the_offbeat_sari: footer link "Book tickets ahead"', async ({ page }) => { await page.goto('/exhibitions/the-offbeat-sari/'); 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 === 'Book tickets ahead' || t.startsWith('Book tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_offbeat_sari: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/the-offbeat-sari/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_offbeat_sari: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/the-offbeat-sari/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_the_ralph_saltzman_prize_2022', () => { test('exhibitions_the_ralph_saltzman_prize_2022: title matches GT', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2022/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('the marlowe vance prize 2022'); }); test('exhibitions_the_ralph_saltzman_prize_2022: h1 "The Marlowe Vance Prize 2022"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2022/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Marlowe Vance Prize 2022' || t.startsWith('The Marlowe Vance Prize 2022'))).toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2022: h2 "In honour of Marlowe Vance"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2022/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In honour of Marlowe Vance' || t.startsWith('In honour of Marlowe Vance'))).toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2022: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2022/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2022: h2 "About the selection process"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2022/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'About the selection process' || t.startsWith('About the selection process'))).toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2022: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2022/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2022: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2022/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2022: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2022/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2022: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2022/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_the_ralph_saltzman_prize_2023', () => { test('exhibitions_the_ralph_saltzman_prize_2023: title matches GT', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2023/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('the halden rowe prize 2023'); }); test('exhibitions_the_ralph_saltzman_prize_2023: h1 "The Halden Rowe Prize 2023"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2023/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Halden Rowe Prize 2023' || t.startsWith('The Halden Rowe Prize 2023'))).toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2023: h2 "In honour of Halden Rowe"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2023/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In honour of Halden Rowe' || t.startsWith('In honour of Halden Rowe'))).toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2023: h2 "Halden T. Rowe"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2023/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Halden T. Rowe' || t.startsWith('Halden T. Rowe'))).toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2023: h2 "Visit information"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2023/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Visit information' || t.startsWith('Visit information'))).toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2023: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2023/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2023: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2023/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2023: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2023/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2023: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2023/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_the_ralph_saltzman_prize_2025', () => { test('exhibitions_the_ralph_saltzman_prize_2025: title matches GT', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2025/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('the elias vantry prize 2025'); }); test('exhibitions_the_ralph_saltzman_prize_2025: h1 "The Elias Vantry Prize 2025"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2025/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Elias Vantry Prize 2025' || t.startsWith('The Elias Vantry Prize 2025'))).toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2025: h2 "In honour of Elias Vantry"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2025/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In honour of Elias Vantry' || t.startsWith('In honour of Elias Vantry'))).toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2025: h2 "Elias Vantry"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2025/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Elias Vantry' || t.startsWith('Elias Vantry'))).toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2025: h2 "Q&A with Nadia Vantry"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2025/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Q&A with Nadia Vantry' || t.startsWith('Q&A with Nadia Vantry'))).toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2025: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2025/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2025: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2025/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2025: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2025/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_ralph_saltzman_prize_2025: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/the-ralph-saltzman-prize-2025/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_the_world_of_tim_burton', () => { test('exhibitions_the_world_of_tim_burton: title matches GT', async ({ page }) => { await page.goto('/exhibitions/the-world-of-tim-burton/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('the world of milo vane'); }); test('exhibitions_the_world_of_tim_burton: h1 "The World of Milo Vane"', async ({ page }) => { await page.goto('/exhibitions/the-world-of-tim-burton/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The World of Milo Vane' || t.startsWith('The World of Milo Vane'))).toBeTruthy(); }); test('exhibitions_the_world_of_tim_burton: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/the-world-of-tim-burton/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_the_world_of_tim_burton: h2 "From the Press"', async ({ page }) => { await page.goto('/exhibitions/the-world-of-tim-burton/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'From the Press' || t.startsWith('From the Press'))).toBeTruthy(); }); test('exhibitions_the_world_of_tim_burton: h2 "In partnership with Ashford & "', async ({ page }) => { await page.goto('/exhibitions/the-world-of-tim-burton/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'In partnership with Ashford & Vale' || t.startsWith('In partnership with Ashford & Vale'))).toBeTruthy(); }); test('exhibitions_the_world_of_tim_burton: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/the-world-of-tim-burton/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_the_world_of_tim_burton: footer link "Book tickets ahead"', async ({ page }) => { await page.goto('/exhibitions/the-world-of-tim-burton/'); 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 === 'Book tickets ahead' || t.startsWith('Book tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_world_of_tim_burton: footer link "Join the museum"', async ({ page }) => { await page.goto('/exhibitions/the-world-of-tim-burton/'); 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 === 'Join the museum' || t.startsWith('Join the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_the_world_of_tim_burton: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/the-world-of-tim-burton/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_touring_exhibitions', () => { test('exhibitions_touring_exhibitions: title matches GT', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('touring exhibitions'); }); test('exhibitions_touring_exhibitions: h1 "Touring Exhibitions"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Touring Exhibitions' || t.startsWith('Touring Exhibitions'))).toBeTruthy(); }); test('exhibitions_touring_exhibitions: h2 "Exhibitions for Hire"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Exhibitions for Hire' || t.startsWith('Exhibitions for Hire'))).toBeTruthy(); }); test('exhibitions_touring_exhibitions: h2 "See a Touring Exhibition"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'See a Touring Exhibition' || t.startsWith('See a Touring Exhibition'))).toBeTruthy(); }); test('exhibitions_touring_exhibitions: h2 "Touring Exhibitions / Internat"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Touring Exhibitions / International Enquiries' || t.startsWith('Touring Exhibitions / International Enquiries'))).toBeTruthy(); }); test('exhibitions_touring_exhibitions: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_touring_exhibitions: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_touring_exhibitions: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_touring_exhibitions: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_weird_sensation_feels_good_the_world_of_asmr', () => { test('exhibitions_weird_sensation_feels_good_the_world_of_asmr: title matches GT', async ({ page }) => { await page.goto('/exhibitions/weird-sensation-feels-good-the-world-of-asmr/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('soft static'); }); test('exhibitions_weird_sensation_feels_good_the_world_of_asmr: h1 "SOFT STATIC: Inside the Sensor"', async ({ page }) => { await page.goto('/exhibitions/weird-sensation-feels-good-the-world-of-asmr/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'SOFT STATIC: Inside the Sensory World of ASMR' || t.startsWith('SOFT STATIC: Inside the Sensory World of ASMR'))).toBeTruthy(); }); test('exhibitions_weird_sensation_feels_good_the_world_of_asmr: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/weird-sensation-feels-good-the-world-of-asmr/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_weird_sensation_feels_good_the_world_of_asmr: h2 "List of Contributors"', async ({ page }) => { await page.goto('/exhibitions/weird-sensation-feels-good-the-world-of-asmr/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'List of Contributors' || t.startsWith('List of Contributors'))).toBeTruthy(); }); test('exhibitions_weird_sensation_feels_good_the_world_of_asmr: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/weird-sensation-feels-good-the-world-of-asmr/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_weird_sensation_feels_good_the_world_of_asmr: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/weird-sensation-feels-good-the-world-of-asmr/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_weird_sensation_feels_good_the_world_of_asmr: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/exhibitions/weird-sensation-feels-good-the-world-of-asmr/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_weird_sensation_feels_good_the_world_of_asmr: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/weird-sensation-feels-good-the-world-of-asmr/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_weird_sensation_feels_good_the_world_of_asmr: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/weird-sensation-feels-good-the-world-of-asmr/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_wes_anderson_the_archives', () => { test('exhibitions_wes_anderson_the_archives: title matches GT', async ({ page }) => { await page.goto('/exhibitions/wes-anderson-the-archives/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('emil thorne'); }); test('exhibitions_wes_anderson_the_archives: h1 "Emil Thorne: The Archives"', async ({ page }) => { await page.goto('/exhibitions/wes-anderson-the-archives/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Emil Thorne: The Archives' || t.startsWith('Emil Thorne: The Archives'))).toBeTruthy(); }); test('exhibitions_wes_anderson_the_archives: h2 "What to expect"', async ({ page }) => { await page.goto('/exhibitions/wes-anderson-the-archives/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('exhibitions_wes_anderson_the_archives: h2 "Booking information"', async ({ page }) => { await page.goto('/exhibitions/wes-anderson-the-archives/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('exhibitions_wes_anderson_the_archives: h2 "Cassian Vale: The Archives Exh"', async ({ page }) => { await page.goto('/exhibitions/wes-anderson-the-archives/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Cassian Vale: The Archives Exhibition Book' || t.startsWith('Cassian Vale: The Archives Exhibition Book'))).toBeTruthy(); }); test('exhibitions_wes_anderson_the_archives: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/wes-anderson-the-archives/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_wes_anderson_the_archives: footer link "Buy advance passes"', async ({ page }) => { await page.goto('/exhibitions/wes-anderson-the-archives/'); 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 === 'Buy advance passes' || t.startsWith('Buy advance passes')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_wes_anderson_the_archives: footer link "Join as a member"', async ({ page }) => { await page.goto('/exhibitions/wes-anderson-the-archives/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_wes_anderson_the_archives: footer link "Support our work"', async ({ page }) => { await page.goto('/exhibitions/wes-anderson-the-archives/'); 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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - learning_at_the_museum_schools_self_guided_visits_for_learning_groups', () => { test('learning_at_the_museum_schools_self_guided_visits_for_learning_groups: title matches GT', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/self-guided-visits-for-learning-groups/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('self'); }); test('learning_at_the_museum_schools_self_guided_visits_for_learning_groups: h1 "Self-guided visits for educati"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/self-guided-visits-for-learning-groups/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Self-guided visits for education groups' || t.startsWith('Self-guided visits for education groups'))).toBeTruthy(); }); test('learning_at_the_museum_schools_self_guided_visits_for_learning_groups: h2 "How to book a visit"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/self-guided-visits-for-learning-groups/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'How to book a visit' || t.startsWith('How to book a visit'))).toBeTruthy(); }); test('learning_at_the_museum_schools_self_guided_visits_for_learning_groups: h2 "Form and Function - Permanent "', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/self-guided-visits-for-learning-groups/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Form and Function - Permanent Collection' || t.startsWith('Form and Function - Permanent Collection'))).toBeTruthy(); }); test('learning_at_the_museum_schools_self_guided_visits_for_learning_groups: h2 "Pulse: the club that shaped th"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/self-guided-visits-for-learning-groups/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Pulse: the club that shaped the 80s' || t.startsWith('Pulse: the club that shaped the 80s'))).toBeTruthy(); }); test('learning_at_the_museum_schools_self_guided_visits_for_learning_groups: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/self-guided-visits-for-learning-groups/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('learning_at_the_museum_schools_self_guided_visits_for_learning_groups: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/self-guided-visits-for-learning-groups/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('learning_at_the_museum_schools_self_guided_visits_for_learning_groups: footer link "Join as a member"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/self-guided-visits-for-learning-groups/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('learning_at_the_museum_schools_self_guided_visits_for_learning_groups: footer link "Support our work"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/self-guided-visits-for-learning-groups/'); 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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - learning_at_the_museum_schools_workshops_for_schools', () => { test('learning_at_the_museum_schools_workshops_for_schools: title matches GT', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/workshops-for-schools/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('workshops for schools'); }); test('learning_at_the_museum_schools_workshops_for_schools: h1 "Design labs for schools"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/workshops-for-schools/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design labs for schools' || t.startsWith('Design labs for schools'))).toBeTruthy(); }); test('learning_at_the_museum_schools_workshops_for_schools: h2 "What happens"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/workshops-for-schools/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What happens' || t.startsWith('What happens'))).toBeTruthy(); }); test('learning_at_the_museum_schools_workshops_for_schools: h2 "Booking your session"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/workshops-for-schools/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking your session' || t.startsWith('Booking your session'))).toBeTruthy(); }); test('learning_at_the_museum_schools_workshops_for_schools: h2 "Design, Make, Reflect"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/workshops-for-schools/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design, Make, Reflect' || t.startsWith('Design, Make, Reflect'))).toBeTruthy(); }); test('learning_at_the_museum_schools_workshops_for_schools: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/workshops-for-schools/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('learning_at_the_museum_schools_workshops_for_schools: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/workshops-for-schools/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('learning_at_the_museum_schools_workshops_for_schools: footer link "Become a friend"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/workshops-for-schools/'); 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 === 'Become a friend' || t.startsWith('Become a friend')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('learning_at_the_museum_schools_workshops_for_schools: footer link "Support our museum"', async ({ page }) => { await page.goto('/learning-at-the-museum/schools/workshops-for-schools/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - plan_your_visit_faq_for_visitors', () => { test('plan_your_visit_faq_for_visitors: title matches GT', async ({ page }) => { await page.goto('/plan-your-visit/faq-for-visitors/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('faq for visitors'); }); test('plan_your_visit_faq_for_visitors: h1 "Visitor questions"', async ({ page }) => { await page.goto('/plan-your-visit/faq-for-visitors/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Visitor questions' || t.startsWith('Visitor questions'))).toBeTruthy(); }); test('plan_your_visit_faq_for_visitors: h2 "Are you planning your visit to"', async ({ page }) => { await page.goto('/plan-your-visit/faq-for-visitors/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Are you planning your visit to Formora?' || t.startsWith('Are you planning your visit to Formora?'))).toBeTruthy(); }); test('plan_your_visit_faq_for_visitors: h2 "May I bring my assistance dog "', async ({ page }) => { await page.goto('/plan-your-visit/faq-for-visitors/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'May I bring my assistance dog to the museum?' || t.startsWith('May I bring my assistance dog to the museum?'))).toBeTruthy(); }); test('plan_your_visit_faq_for_visitors: h2 "Where can I find details about"', async ({ page }) => { await page.goto('/plan-your-visit/faq-for-visitors/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Where can I find details about accessibility across the museum?' || t.startsWith('Where can I find details about accessibility across the museum?'))).toBeTruthy(); }); test('plan_your_visit_faq_for_visitors: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/plan-your-visit/faq-for-visitors/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('plan_your_visit_faq_for_visitors: footer link "Book tickets ahead"', async ({ page }) => { await page.goto('/plan-your-visit/faq-for-visitors/'); 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 === 'Book tickets ahead' || t.startsWith('Book tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('plan_your_visit_faq_for_visitors: footer link "Join as a member"', async ({ page }) => { await page.goto('/plan-your-visit/faq-for-visitors/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('plan_your_visit_faq_for_visitors: footer link "Support our museum"', async ({ page }) => { await page.goto('/plan-your-visit/faq-for-visitors/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - plan_your_visit_food_drink_qa_with_matthew_williamson', () => { test('plan_your_visit_food_drink_qa_with_matthew_williamson: title matches GT', async ({ page }) => { await page.goto('/plan-your-visit/food-drink/qa-with-matthew-williamson/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('in conversation'); }); test('plan_your_visit_food_drink_qa_with_matthew_williamson: h1 "Q&A with designer Marcus Eller"', async ({ page }) => { await page.goto('/plan-your-visit/food-drink/qa-with-matthew-williamson/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Q&A with designer Marcus Ellery' || t.startsWith('Q&A with designer Marcus Ellery'))).toBeTruthy(); }); test('plan_your_visit_food_drink_qa_with_matthew_williamson: h2 "Q: What inspired your vision f"', async ({ page }) => { await page.goto('/plan-your-visit/food-drink/qa-with-matthew-williamson/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Q: What inspired your vision for the Studio Kitchen?' || t.startsWith('Q: What inspired your vision for the Studio Kitchen?'))).toBeTruthy(); }); test('plan_your_visit_food_drink_qa_with_matthew_williamson: h2 "Q: What did you enjoy most abo"', async ({ page }) => { await page.goto('/plan-your-visit/food-drink/qa-with-matthew-williamson/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Q: What did you enjoy most about this project?' || t.startsWith('Q: What did you enjoy most about this project?'))).toBeTruthy(); }); test('plan_your_visit_food_drink_qa_with_matthew_williamson: h2 "Q: How would you sum up the st"', async ({ page }) => { await page.goto('/plan-your-visit/food-drink/qa-with-matthew-williamson/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Q: How would you sum up the style behind your design?' || t.startsWith('Q: How would you sum up the style behind your design?'))).toBeTruthy(); }); test('plan_your_visit_food_drink_qa_with_matthew_williamson: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/plan-your-visit/food-drink/qa-with-matthew-williamson/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('plan_your_visit_food_drink_qa_with_matthew_williamson: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/plan-your-visit/food-drink/qa-with-matthew-williamson/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('plan_your_visit_food_drink_qa_with_matthew_williamson: footer link "Become a member"', async ({ page }) => { await page.goto('/plan-your-visit/food-drink/qa-with-matthew-williamson/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('plan_your_visit_food_drink_qa_with_matthew_williamson: footer link "Support the museum"', async ({ page }) => { await page.goto('/plan-your-visit/food-drink/qa-with-matthew-williamson/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - plan_your_visit_stay_connected', () => { test('plan_your_visit_stay_connected: title matches GT', async ({ page }) => { await page.goto('/plan-your-visit/stay-connected/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('stay connected'); }); test('plan_your_visit_stay_connected: h1 "Stay Connected"', async ({ page }) => { await page.goto('/plan-your-visit/stay-connected/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Stay Connected' || t.startsWith('Stay Connected'))).toBeTruthy(); }); test('plan_your_visit_stay_connected: h2 "What to expect"', async ({ page }) => { await page.goto('/plan-your-visit/stay-connected/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('plan_your_visit_stay_connected: h2 "Connect via app or website"', async ({ page }) => { await page.goto('/plan-your-visit/stay-connected/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Connect via app or website' || t.startsWith('Connect via app or website'))).toBeTruthy(); }); test('plan_your_visit_stay_connected: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/plan-your-visit/stay-connected/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('plan_your_visit_stay_connected: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/plan-your-visit/stay-connected/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('plan_your_visit_stay_connected: footer link "Become a member"', async ({ page }) => { await page.goto('/plan-your-visit/stay-connected/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('plan_your_visit_stay_connected: footer link "Support the museum"', async ({ page }) => { await page.goto('/plan-your-visit/stay-connected/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - support_us_corporate_support_nyetimber', () => { test('support_us_corporate_support_nyetimber: title matches GT', async ({ page }) => { await page.goto('/support-us/corporate-support/nyetimber/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('larkspire'); }); test('support_us_corporate_support_nyetimber: h1 "Larkspire"', async ({ page }) => { await page.goto('/support-us/corporate-support/nyetimber/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Larkspire' || t.startsWith('Larkspire'))).toBeTruthy(); }); test('support_us_corporate_support_nyetimber: h2 "Eat & drink"', async ({ page }) => { await page.goto('/support-us/corporate-support/nyetimber/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Eat & drink' || t.startsWith('Eat & drink'))).toBeTruthy(); }); test('support_us_corporate_support_nyetimber: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/support-us/corporate-support/nyetimber/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('support_us_corporate_support_nyetimber: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/support-us/corporate-support/nyetimber/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('support_us_corporate_support_nyetimber: footer link "Become a member"', async ({ page }) => { await page.goto('/support-us/corporate-support/nyetimber/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('support_us_corporate_support_nyetimber: footer link "Support the museum"', async ({ page }) => { await page.goto('/support-us/corporate-support/nyetimber/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - support_us_ticket_mate_fund', () => { test('support_us_ticket_mate_fund: title matches GT', async ({ page }) => { await page.goto('/support-us/ticket-mate-fund/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('shared seats fund'); }); test('support_us_ticket_mate_fund: h1 "Shared Seats Fund"', async ({ page }) => { await page.goto('/support-us/ticket-mate-fund/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Shared Seats Fund' || t.startsWith('Shared Seats Fund'))).toBeTruthy(); }); test('support_us_ticket_mate_fund: h2 "How to get involved"', async ({ page }) => { await page.goto('/support-us/ticket-mate-fund/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'How to get involved' || t.startsWith('How to get involved'))).toBeTruthy(); }); test('support_us_ticket_mate_fund: h2 "Ways to donate exhibition tick"', async ({ page }) => { await page.goto('/support-us/ticket-mate-fund/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Ways to donate exhibition tickets' || t.startsWith('Ways to donate exhibition tickets'))).toBeTruthy(); }); test('support_us_ticket_mate_fund: h2 "Our partner groups"', async ({ page }) => { await page.goto('/support-us/ticket-mate-fund/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our partner groups' || t.startsWith('Our partner groups'))).toBeTruthy(); }); test('support_us_ticket_mate_fund: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/support-us/ticket-mate-fund/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('support_us_ticket_mate_fund: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/support-us/ticket-mate-fund/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('support_us_ticket_mate_fund: footer link "Become a member"', async ({ page }) => { await page.goto('/support-us/ticket-mate-fund/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('support_us_ticket_mate_fund: footer link "Support the museum"', async ({ page }) => { await page.goto('/support-us/ticket-mate-fund/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - venue_hire_approved_suppliers', () => { test('venue_hire_approved_suppliers: title matches GT', async ({ page }) => { await page.goto('/venue-hire/approved-suppliers/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('approved suppliers'); }); test('venue_hire_approved_suppliers: h1 "Our Approved Suppliers"', async ({ page }) => { await page.goto('/venue-hire/approved-suppliers/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our Approved Suppliers' || t.startsWith('Our Approved Suppliers'))).toBeTruthy(); }); test('venue_hire_approved_suppliers: h2 "View Approved Suppliers"', async ({ page }) => { await page.goto('/venue-hire/approved-suppliers/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'View Approved Suppliers' || t.startsWith('View Approved Suppliers'))).toBeTruthy(); }); test('venue_hire_approved_suppliers: h2 "Environmental Impact Roadmap"', async ({ page }) => { await page.goto('/venue-hire/approved-suppliers/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Environmental Impact Roadmap' || t.startsWith('Environmental Impact Roadmap'))).toBeTruthy(); }); test('venue_hire_approved_suppliers: h2 "Enquire Today"', async ({ page }) => { await page.goto('/venue-hire/approved-suppliers/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Enquire Today' || t.startsWith('Enquire Today'))).toBeTruthy(); }); test('venue_hire_approved_suppliers: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/venue-hire/approved-suppliers/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('venue_hire_approved_suppliers: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/venue-hire/approved-suppliers/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('venue_hire_approved_suppliers: footer link "Become a member"', async ({ page }) => { await page.goto('/venue-hire/approved-suppliers/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('venue_hire_approved_suppliers: footer link "Support the museum"', async ({ page }) => { await page.goto('/venue-hire/approved-suppliers/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - venue_hire_brand_activations_and_exclusive_events', () => { test('venue_hire_brand_activations_and_exclusive_events: title matches GT', async ({ page }) => { await page.goto('/venue-hire/brand-activations-and-exclusive-events/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('brand activations and exclusive events'); }); test('venue_hire_brand_activations_and_exclusive_events: h1 "Brand Activations and Exclusiv"', async ({ page }) => { await page.goto('/venue-hire/brand-activations-and-exclusive-events/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Brand Activations and Exclusive Events' || t.startsWith('Brand Activations and Exclusive Events'))).toBeTruthy(); }); test('venue_hire_brand_activations_and_exclusive_events: h2 "Designed to Connect: Activatio"', async ({ page }) => { await page.goto('/venue-hire/brand-activations-and-exclusive-events/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Designed to Connect: Activations and Displays' || t.startsWith('Designed to Connect: Activations and Displays'))).toBeTruthy(); }); test('venue_hire_brand_activations_and_exclusive_events: h2 "Exclusive Hire"', async ({ page }) => { await page.goto('/venue-hire/brand-activations-and-exclusive-events/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Exclusive Hire' || t.startsWith('Exclusive Hire'))).toBeTruthy(); }); test('venue_hire_brand_activations_and_exclusive_events: h2 "The Atrium and Mezzanine"', async ({ page }) => { await page.goto('/venue-hire/brand-activations-and-exclusive-events/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Atrium and Mezzanine' || t.startsWith('The Atrium and Mezzanine'))).toBeTruthy(); }); test('venue_hire_brand_activations_and_exclusive_events: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/venue-hire/brand-activations-and-exclusive-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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('venue_hire_brand_activations_and_exclusive_events: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/venue-hire/brand-activations-and-exclusive-events/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('venue_hire_brand_activations_and_exclusive_events: footer link "Join as a member"', async ({ page }) => { await page.goto('/venue-hire/brand-activations-and-exclusive-events/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('venue_hire_brand_activations_and_exclusive_events: footer link "Support our museum"', async ({ page }) => { await page.goto('/venue-hire/brand-activations-and-exclusive-events/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - venue_hire_design_museum_events_catering', () => { test('venue_hire_design_museum_events_catering: title matches GT', async ({ page }) => { await page.goto('/venue-hire/design-museum-events-catering/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('formora events catering'); }); test('venue_hire_design_museum_events_catering: h1 "Formora Museum Events Catering"', async ({ page }) => { await page.goto('/venue-hire/design-museum-events-catering/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Formora Museum Events Catering' || t.startsWith('Formora Museum Events Catering'))).toBeTruthy(); }); test('venue_hire_design_museum_events_catering: h2 "Responsibly sourced bespoke me"', async ({ page }) => { await page.goto('/venue-hire/design-museum-events-catering/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Responsibly sourced bespoke menus' || t.startsWith('Responsibly sourced bespoke menus'))).toBeTruthy(); }); test('venue_hire_design_museum_events_catering: h2 "Events Packages"', async ({ page }) => { await page.goto('/venue-hire/design-museum-events-catering/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Events Packages' || t.startsWith('Events Packages'))).toBeTruthy(); }); test('venue_hire_design_museum_events_catering: h2 "Enquire Today"', async ({ page }) => { await page.goto('/venue-hire/design-museum-events-catering/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Enquire Today' || t.startsWith('Enquire Today'))).toBeTruthy(); }); test('venue_hire_design_museum_events_catering: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/venue-hire/design-museum-events-catering/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('venue_hire_design_museum_events_catering: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/venue-hire/design-museum-events-catering/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('venue_hire_design_museum_events_catering: footer link "Become a member"', async ({ page }) => { await page.goto('/venue-hire/design-museum-events-catering/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('venue_hire_design_museum_events_catering: footer link "Support the museum"', async ({ page }) => { await page.goto('/venue-hire/design-museum-events-catering/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - venue_hire_enquire_about_venue_hire', () => { test('venue_hire_enquire_about_venue_hire: title matches GT', async ({ page }) => { await page.goto('/venue-hire/enquire-about-venue-hire/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('enquire about venue hire'); }); test('venue_hire_enquire_about_venue_hire: h1 "Enquire about venue hire"', async ({ page }) => { await page.goto('/venue-hire/enquire-about-venue-hire/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Enquire about venue hire' || t.startsWith('Enquire about venue hire'))).toBeTruthy(); }); test('venue_hire_enquire_about_venue_hire: h2 "Venue Hire Enquiry"', async ({ page }) => { await page.goto('/venue-hire/enquire-about-venue-hire/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Venue Hire Enquiry' || t.startsWith('Venue Hire Enquiry'))).toBeTruthy(); }); test('venue_hire_enquire_about_venue_hire: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/venue-hire/enquire-about-venue-hire/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('venue_hire_enquire_about_venue_hire: footer link "Book tickets ahead"', async ({ page }) => { await page.goto('/venue-hire/enquire-about-venue-hire/'); 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 === 'Book tickets ahead' || t.startsWith('Book tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('venue_hire_enquire_about_venue_hire: footer link "Join as a member"', async ({ page }) => { await page.goto('/venue-hire/enquire-about-venue-hire/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('venue_hire_enquire_about_venue_hire: footer link "Support Formora"', async ({ page }) => { await page.goto('/venue-hire/enquire-about-venue-hire/'); 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 === 'Support Formora' || t.startsWith('Support Formora')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - venue_hire_environmental_impact_roadmap', () => { test('venue_hire_environmental_impact_roadmap: title matches GT', async ({ page }) => { await page.goto('/venue-hire/environmental-impact-roadmap/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('environmental impact roadmap'); }); test('venue_hire_environmental_impact_roadmap: h1 "Our Environmental Impact Plan"', async ({ page }) => { await page.goto('/venue-hire/environmental-impact-roadmap/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our Environmental Impact Plan' || t.startsWith('Our Environmental Impact Plan'))).toBeTruthy(); }); test('venue_hire_environmental_impact_roadmap: h2 "Get our full Environmental Imp"', async ({ page }) => { await page.goto('/venue-hire/environmental-impact-roadmap/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Get our full Environmental Impact Roadmap' || t.startsWith('Get our full Environmental Impact Roadmap'))).toBeTruthy(); }); test('venue_hire_environmental_impact_roadmap: h2 "Yearly Environmental Report"', async ({ page }) => { await page.goto('/venue-hire/environmental-impact-roadmap/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Yearly Environmental Report' || t.startsWith('Yearly Environmental Report'))).toBeTruthy(); }); test('venue_hire_environmental_impact_roadmap: h2 "Building a greener tomorrow"', async ({ page }) => { await page.goto('/venue-hire/environmental-impact-roadmap/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Building a greener tomorrow' || t.startsWith('Building a greener tomorrow'))).toBeTruthy(); }); test('venue_hire_environmental_impact_roadmap: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/venue-hire/environmental-impact-roadmap/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('venue_hire_environmental_impact_roadmap: footer link "Book tickets ahead"', async ({ page }) => { await page.goto('/venue-hire/environmental-impact-roadmap/'); 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 === 'Book tickets ahead' || t.startsWith('Book tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('venue_hire_environmental_impact_roadmap: footer link "Join as a member"', async ({ page }) => { await page.goto('/venue-hire/environmental-impact-roadmap/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('venue_hire_environmental_impact_roadmap: footer link "Support our museum"', async ({ page }) => { await page.goto('/venue-hire/environmental-impact-roadmap/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - venue_hire_filming_photography_at_the_design_museum', () => { test('venue_hire_filming_photography_at_the_design_museum: title matches GT', async ({ page }) => { await page.goto('/venue-hire/filming-photography-at-the-design-museum/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('filming & photography at formora'); }); test('venue_hire_filming_photography_at_the_design_museum: h1 "Filming & Photography at Formo"', async ({ page }) => { await page.goto('/venue-hire/filming-photography-at-the-design-museum/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Filming & Photography at Formora' || t.startsWith('Filming & Photography at Formora'))).toBeTruthy(); }); test('venue_hire_filming_photography_at_the_design_museum: h2 "Every filming project must com"', async ({ page }) => { await page.goto('/venue-hire/filming-photography-at-the-design-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Every filming project must complete the following steps before any work can begin on our premises.' || t.startsWith('Every filming project must complete the following steps before any work can begin on our premises.'))).toBeTruthy(); }); test('venue_hire_filming_photography_at_the_design_museum: h2 "Our House Rules"', async ({ page }) => { await page.goto('/venue-hire/filming-photography-at-the-design-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Our House Rules' || t.startsWith('Our House Rules'))).toBeTruthy(); }); test('venue_hire_filming_photography_at_the_design_museum: h2 "Get in touch"', async ({ page }) => { await page.goto('/venue-hire/filming-photography-at-the-design-museum/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Get in touch' || t.startsWith('Get in touch'))).toBeTruthy(); }); test('venue_hire_filming_photography_at_the_design_museum: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/venue-hire/filming-photography-at-the-design-museum/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('venue_hire_filming_photography_at_the_design_museum: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/venue-hire/filming-photography-at-the-design-museum/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('venue_hire_filming_photography_at_the_design_museum: footer link "Become a member"', async ({ page }) => { await page.goto('/venue-hire/filming-photography-at-the-design-museum/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('venue_hire_filming_photography_at_the_design_museum: footer link "Support the museum"', async ({ page }) => { await page.goto('/venue-hire/filming-photography-at-the-design-museum/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - venue_hire_tour_packages_unique_offers', () => { test('venue_hire_tour_packages_unique_offers: title matches GT', async ({ page }) => { await page.goto('/venue-hire/tour-packages-unique-offers/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('tour packages & unique offers'); }); test('venue_hire_tour_packages_unique_offers: h1 "Tour Packages & Special Offers"', async ({ page }) => { await page.goto('/venue-hire/tour-packages-unique-offers/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Tour Packages & Special Offers' || t.startsWith('Tour Packages & Special Offers'))).toBeTruthy(); }); test('venue_hire_tour_packages_unique_offers: h2 "Tours & Group Packages"', async ({ page }) => { await page.goto('/venue-hire/tour-packages-unique-offers/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Tours & Group Packages' || t.startsWith('Tours & Group Packages'))).toBeTruthy(); }); test('venue_hire_tour_packages_unique_offers: h2 "Curated Gifts"', async ({ page }) => { await page.goto('/venue-hire/tour-packages-unique-offers/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Curated Gifts' || t.startsWith('Curated Gifts'))).toBeTruthy(); }); test('venue_hire_tour_packages_unique_offers: h2 "Workshops and Learning"', async ({ page }) => { await page.goto('/venue-hire/tour-packages-unique-offers/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Workshops and Learning' || t.startsWith('Workshops and Learning'))).toBeTruthy(); }); test('venue_hire_tour_packages_unique_offers: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/venue-hire/tour-packages-unique-offers/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('venue_hire_tour_packages_unique_offers: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/venue-hire/tour-packages-unique-offers/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('venue_hire_tour_packages_unique_offers: footer link "Join as a member"', async ({ page }) => { await page.goto('/venue-hire/tour-packages-unique-offers/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('venue_hire_tour_packages_unique_offers: footer link "Support our museum"', async ({ page }) => { await page.goto('/venue-hire/tour-packages-unique-offers/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - venue_hire_view_and_download_the_events_brochure', () => { test('venue_hire_view_and_download_the_events_brochure: title matches GT', async ({ page }) => { await page.goto('/venue-hire/view-and-download-the-events-brochure/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('explore and download our venue hire broc'); }); test('venue_hire_view_and_download_the_events_brochure: h1 "Explore and download our Venue"', async ({ page }) => { await page.goto('/venue-hire/view-and-download-the-events-brochure/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Explore and download our Venue Hire brochure' || t.startsWith('Explore and download our Venue Hire brochure'))).toBeTruthy(); }); test('venue_hire_view_and_download_the_events_brochure: h2 "Sign up to our business newsle"', async ({ page }) => { await page.goto('/venue-hire/view-and-download-the-events-brochure/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Sign up to our business newsletters' || t.startsWith('Sign up to our business newsletters'))).toBeTruthy(); }); test('venue_hire_view_and_download_the_events_brochure: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/venue-hire/view-and-download-the-events-brochure/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('venue_hire_view_and_download_the_events_brochure: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/venue-hire/view-and-download-the-events-brochure/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('venue_hire_view_and_download_the_events_brochure: footer link "Become a member"', async ({ page }) => { await page.goto('/venue-hire/view-and-download-the-events-brochure/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('venue_hire_view_and_download_the_events_brochure: footer link "Support the centre"', async ({ page }) => { await page.goto('/venue-hire/view-and-download-the-events-brochure/'); 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 === 'Support the centre' || t.startsWith('Support the centre')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_artists_in_the_wes_anderson_universe_from_canvas_to_screen', () => { test('whats_on_talks_courses_and_workshops_artists_in_the_wes_anderson_universe_from_canvas_to_screen: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/artists-in-the-wes-anderson-universe-from-canvas-to-screen/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('painters behind the amber corridor'); }); test('whats_on_talks_courses_and_workshops_artists_in_the_wes_anderson_universe_from_canvas_to_screen: h1 "Painters in the Elias Marrow U"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/artists-in-the-wes-anderson-universe-from-canvas-to-screen/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Painters in the Elias Marrow Universe: From Studio to Screen' || t.startsWith('Painters in the Elias Marrow Universe: From Studio to Screen'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_artists_in_the_wes_anderson_universe_from_canvas_to_screen: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/artists-in-the-wes-anderson-universe-from-canvas-to-screen/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_artists_in_the_wes_anderson_universe_from_canvas_to_screen: h2 "Marek Ivano"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/artists-in-the-wes-anderson-universe-from-canvas-to-screen/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Marek Ivano' || t.startsWith('Marek Ivano'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_artists_in_the_wes_anderson_universe_from_canvas_to_screen: h2 "Colin Hartwell"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/artists-in-the-wes-anderson-universe-from-canvas-to-screen/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Colin Hartwell' || t.startsWith('Colin Hartwell'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_artists_in_the_wes_anderson_universe_from_canvas_to_screen: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/artists-in-the-wes-anderson-universe-from-canvas-to-screen/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_artists_in_the_wes_anderson_universe_from_canvas_to_screen: footer link "Buy tickets in advance"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/artists-in-the-wes-anderson-universe-from-canvas-to-screen/'); 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 === 'Buy tickets in advance' || t.startsWith('Buy tickets in advance')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_artists_in_the_wes_anderson_universe_from_canvas_to_screen: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/artists-in-the-wes-anderson-universe-from-canvas-to-screen/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_artists_in_the_wes_anderson_universe_from_canvas_to_screen: footer link "Support our museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/artists-in-the-wes-anderson-universe-from-canvas-to-screen/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_audio_described_tour_of_nigo_from_japan_with_love', () => { test('whats_on_talks_courses_and_workshops_audio_described_tour_of_nigo_from_japan_with_love: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/audio-described-tour-of-nigo-from-japan-with-love/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('audio'); }); test('whats_on_talks_courses_and_workshops_audio_described_tour_of_nigo_from_japan_with_love: h1 "Audio-Described Tour of MARLO:"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/audio-described-tour-of-nigo-from-japan-with-love/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Audio-Described Tour of MARLO: Threads of Tomorrow' || t.startsWith('Audio-Described Tour of MARLO: Threads of Tomorrow'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_audio_described_tour_of_nigo_from_japan_with_love: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/audio-described-tour-of-nigo-from-japan-with-love/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_audio_described_tour_of_nigo_from_japan_with_love: h2 "Booking information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/audio-described-tour-of-nigo-from-japan-with-love/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_audio_described_tour_of_nigo_from_japan_with_love: h2 "Booking information for member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/audio-described-tour-of-nigo-from-japan-with-love/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information for members:' || t.startsWith('Booking information for members:'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_audio_described_tour_of_nigo_from_japan_with_love: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/audio-described-tour-of-nigo-from-japan-with-love/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_audio_described_tour_of_nigo_from_japan_with_love: footer link "Reserve tickets early"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/audio-described-tour-of-nigo-from-japan-with-love/'); 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 === 'Reserve tickets early' || t.startsWith('Reserve tickets early')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_audio_described_tour_of_nigo_from_japan_with_love: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/audio-described-tour-of-nigo-from-japan-with-love/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_audio_described_tour_of_nigo_from_japan_with_love: footer link "Support our work"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/audio-described-tour-of-nigo-from-japan-with-love/'); 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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_bsl_tour_architecture_of_the_museum_and_platform', () => { test('whats_on_talks_courses_and_workshops_bsl_tour_architecture_of_the_museum_and_platform: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/bsl-tour-architecture-of-the-museum-and-platform/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('bsl tour'); }); test('whats_on_talks_courses_and_workshops_bsl_tour_architecture_of_the_museum_and_platform: h1 "BSL Tour: The Building of the "', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/bsl-tour-architecture-of-the-museum-and-platform/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'BSL Tour: The Building of the Museum and PLATFORM' || t.startsWith('BSL Tour: The Building of the Museum and PLATFORM'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_bsl_tour_architecture_of_the_museum_and_platform: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/bsl-tour-architecture-of-the-museum-and-platform/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_bsl_tour_architecture_of_the_museum_and_platform: h2 "Marcus Halloway"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/bsl-tour-architecture-of-the-museum-and-platform/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Marcus Halloway' || t.startsWith('Marcus Halloway'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_bsl_tour_architecture_of_the_museum_and_platform: h2 "Booking information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/bsl-tour-architecture-of-the-museum-and-platform/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_bsl_tour_architecture_of_the_museum_and_platform: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/bsl-tour-architecture-of-the-museum-and-platform/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_bsl_tour_architecture_of_the_museum_and_platform: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/bsl-tour-architecture-of-the-museum-and-platform/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_bsl_tour_architecture_of_the_museum_and_platform: footer link "Become a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/bsl-tour-architecture-of-the-museum-and-platform/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_bsl_tour_architecture_of_the_museum_and_platform: footer link "Support the museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/bsl-tour-architecture-of-the-museum-and-platform/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_building_resilience_demonstrators_for_a_changing_climate', () => { test('whats_on_talks_courses_and_workshops_building_resilience_demonstrators_for_a_changing_climate: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/building-resilience-demonstrators-for-a-changing-climate/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('building resilience'); }); test('whats_on_talks_courses_and_workshops_building_resilience_demonstrators_for_a_changing_climate: h1 "Building Resilience: Prototype"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/building-resilience-demonstrators-for-a-changing-climate/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Building Resilience: Prototypes for a Warming Urban World' || t.startsWith('Building Resilience: Prototypes for a Warming Urban World'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_building_resilience_demonstrators_for_a_changing_climate: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/building-resilience-demonstrators-for-a-changing-climate/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_building_resilience_demonstrators_for_a_changing_climate: h2 "Booking information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/building-resilience-demonstrators-for-a-changing-climate/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_building_resilience_demonstrators_for_a_changing_climate: h2 "Booking information for Member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/building-resilience-demonstrators-for-a-changing-climate/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information for Members:' || t.startsWith('Booking information for Members:'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_building_resilience_demonstrators_for_a_changing_climate: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/building-resilience-demonstrators-for-a-changing-climate/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_building_resilience_demonstrators_for_a_changing_climate: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/building-resilience-demonstrators-for-a-changing-climate/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_building_resilience_demonstrators_for_a_changing_climate: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/building-resilience-demonstrators-for-a-changing-climate/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_building_resilience_demonstrators_for_a_changing_climate: footer link "Support our museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/building-resilience-demonstrators-for-a-changing-climate/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_curating_design_between_word_and_world', () => { test('whats_on_talks_courses_and_workshops_curating_design_between_word_and_world: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curating-design-between-word-and-world/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('curating design'); }); test('whats_on_talks_courses_and_workshops_curating_design_between_word_and_world: h1 "Curating Design: Between Word "', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curating-design-between-word-and-world/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Curating Design: Between Word and World' || t.startsWith('Curating Design: Between Word and World'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curating_design_between_word_and_world: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curating-design-between-word-and-world/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curating_design_between_word_and_world: h2 "Keynote: Lena Marchetti"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curating-design-between-word-and-world/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Keynote: Lena Marchetti' || t.startsWith('Keynote: Lena Marchetti'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curating_design_between_word_and_world: h2 "Booking information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curating-design-between-word-and-world/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curating_design_between_word_and_world: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curating-design-between-word-and-world/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curating_design_between_word_and_world: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curating-design-between-word-and-world/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curating_design_between_word_and_world: footer link "Become a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curating-design-between-word-and-world/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curating_design_between_word_and_world: footer link "Support the museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curating-design-between-word-and-world/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_curator_tour_of_nigo_from_japan_with_love', () => { test('whats_on_talks_courses_and_workshops_curator_tour_of_nigo_from_japan_with_love: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-nigo-from-japan-with-love/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('curator tour of velo'); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_nigo_from_japan_with_love: h1 "Curator Tour of VELO: A Life i"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-nigo-from-japan-with-love/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Curator Tour of VELO: A Life in Colour' || t.startsWith('Curator Tour of VELO: A Life in Colour'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_nigo_from_japan_with_love: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-nigo-from-japan-with-love/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_nigo_from_japan_with_love: h2 "Booking information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-nigo-from-japan-with-love/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_nigo_from_japan_with_love: h2 "YUMA: A Life Made by Hand"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-nigo-from-japan-with-love/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'YUMA: A Life Made by Hand' || t.startsWith('YUMA: A Life Made by Hand'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_nigo_from_japan_with_love: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-nigo-from-japan-with-love/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_nigo_from_japan_with_love: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-nigo-from-japan-with-love/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_nigo_from_japan_with_love: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-nigo-from-japan-with-love/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_nigo_from_japan_with_love: footer link "Support our museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-nigo-from-japan-with-love/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_curator_tour_of_platform_simone_brewster', () => { test('whats_on_talks_courses_and_workshops_curator_tour_of_platform_simone_brewster: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-platform-simone-brewster/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('curator tour of spectrum'); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_platform_simone_brewster: h1 "Curator Tour of SPECTRUM: Mara"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-platform-simone-brewster/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Curator Tour of SPECTRUM: Mara Solano' || t.startsWith('Curator Tour of SPECTRUM: Mara Solano'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_platform_simone_brewster: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-platform-simone-brewster/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_platform_simone_brewster: h2 "Yara Okonkwo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-platform-simone-brewster/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Yara Okonkwo' || t.startsWith('Yara Okonkwo'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_platform_simone_brewster: h2 "Booking information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-platform-simone-brewster/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking information' || t.startsWith('Booking information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_platform_simone_brewster: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-platform-simone-brewster/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_platform_simone_brewster: footer link "Book tickets early"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-platform-simone-brewster/'); 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 === 'Book tickets early' || t.startsWith('Book tickets early')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_platform_simone_brewster: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-platform-simone-brewster/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_curator_tour_of_platform_simone_brewster: footer link "Give to Formora"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/curator-tour-of-platform-simone-brewster/'); 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 === 'Give to Formora' || t.startsWith('Give to Formora')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_create_a_shoe_prototype', () => { test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_create_a_shoe_prototype: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-create-a-shoe-prototype/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('design camp for ages 11 to 14'); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_create_a_shoe_prototype: h1 "Design Camp for ages 11 to 14:"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-create-a-shoe-prototype/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Camp for ages 11 to 14: Craft a Shoe Prototype' || t.startsWith('Design Camp for ages 11 to 14: Craft a Shoe Prototype'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_create_a_shoe_prototype: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-create-a-shoe-prototype/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_create_a_shoe_prototype: h2 "Additional information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-create-a-shoe-prototype/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Additional information' || t.startsWith('Additional information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_create_a_shoe_prototype: h2 "Elias Marchetti"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-create-a-shoe-prototype/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Elias Marchetti' || t.startsWith('Elias Marchetti'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_create_a_shoe_prototype: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-create-a-shoe-prototype/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_create_a_shoe_prototype: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-create-a-shoe-prototype/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_create_a_shoe_prototype: footer link "Become a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-create-a-shoe-prototype/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_create_a_shoe_prototype: footer link "Support the museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-create-a-shoe-prototype/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_designing_with_light_and_shadow', () => { test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_designing_with_light_and_shadow: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-designing-with-light-and-shadow/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('design camp for ages 11 to 14'); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_designing_with_light_and_shadow: h1 "Design Camp for ages 11 to 14:"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-designing-with-light-and-shadow/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Camp for ages 11 to 14: Creating with Sunlight and Shadow' || t.startsWith('Design Camp for ages 11 to 14: Creating with Sunlight and Shadow'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_designing_with_light_and_shadow: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-designing-with-light-and-shadow/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_designing_with_light_and_shadow: h2 "Additional information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-designing-with-light-and-shadow/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Additional information' || t.startsWith('Additional information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_designing_with_light_and_shadow: h2 "What past participants have sa"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-designing-with-light-and-shadow/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What past participants have said' || t.startsWith('What past participants have said'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_designing_with_light_and_shadow: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-designing-with-light-and-shadow/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_designing_with_light_and_shadow: footer link "Get advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-designing-with-light-and-shadow/'); 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 === 'Get advance tickets' || t.startsWith('Get advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_designing_with_light_and_shadow: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-designing-with-light-and-shadow/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_designing_with_light_and_shadow: footer link "Support our museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-designing-with-light-and-shadow/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_digital_illustration', () => { test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_digital_illustration: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-digital-illustration/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('creative camp for ages 11 to 14'); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_digital_illustration: h1 "Creative Camp for ages 11 to 1"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-digital-illustration/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Creative Camp for ages 11 to 14: Digital Illustration' || t.startsWith('Creative Camp for ages 11 to 14: Digital Illustration'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_digital_illustration: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-digital-illustration/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_digital_illustration: h2 "Additional information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-digital-illustration/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Additional information' || t.startsWith('Additional information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_digital_illustration: h2 "Testimonials from previous wor"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-digital-illustration/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Testimonials from previous workshops' || t.startsWith('Testimonials from previous workshops'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_digital_illustration: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-digital-illustration/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_digital_illustration: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-digital-illustration/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_digital_illustration: footer link "Become a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-digital-illustration/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_11_to_14_digital_illustration: footer link "Support the museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-11-to-14-digital-illustration/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_create_in_clay', () => { test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_create_in_clay: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-create-in-clay/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('design camp for ages 7 to 10'); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_create_in_clay: h1 "Design Camp for ages 7 to 10: "', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-create-in-clay/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Camp for ages 7 to 10: Working with Clay' || t.startsWith('Design Camp for ages 7 to 10: Working with Clay'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_create_in_clay: h2 "About the day"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-create-in-clay/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'About the day' || t.startsWith('About the day'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_create_in_clay: h2 "Further details here"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-create-in-clay/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Further details here' || t.startsWith('Further details here'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_create_in_clay: h2 "Rowan Ashcroft"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-create-in-clay/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Rowan Ashcroft' || t.startsWith('Rowan Ashcroft'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_create_in_clay: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-create-in-clay/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_create_in_clay: footer link "Get advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-create-in-clay/'); 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 === 'Get advance tickets' || t.startsWith('Get advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_create_in_clay: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-create-in-clay/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_create_in_clay: footer link "Support our museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-create-in-clay/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_designing_with_light_and_shadow', () => { test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_designing_with_light_and_shadow: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-designing-with-light-and-shadow/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('design camp for ages 7 to 10'); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_designing_with_light_and_shadow: h1 "Design Camp for ages 7 to 10: "', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-designing-with-light-and-shadow/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Camp for ages 7 to 10: Creating with Sunlight and Shade' || t.startsWith('Design Camp for ages 7 to 10: Creating with Sunlight and Shade'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_designing_with_light_and_shadow: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-designing-with-light-and-shadow/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_designing_with_light_and_shadow: h2 "Additional information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-designing-with-light-and-shadow/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Additional information' || t.startsWith('Additional information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_designing_with_light_and_shadow: h2 "Testimonials from previous wor"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-designing-with-light-and-shadow/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Testimonials from previous workshops' || t.startsWith('Testimonials from previous workshops'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_designing_with_light_and_shadow: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-designing-with-light-and-shadow/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_designing_with_light_and_shadow: footer link "Get advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-designing-with-light-and-shadow/'); 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 === 'Get advance tickets' || t.startsWith('Get advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_designing_with_light_and_shadow: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-designing-with-light-and-shadow/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_designing_with_light_and_shadow: footer link "Support our museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-designing-with-light-and-shadow/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_stop_motion_with_clay', () => { test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_stop_motion_with_clay: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-stop-motion-with-clay/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('studio camp for ages 7 to 10'); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_stop_motion_with_clay: h1 "Studio Camp for ages 7 to 10: "', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-stop-motion-with-clay/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Studio Camp for ages 7 to 10: Clay Stop-Motion Play' || t.startsWith('Studio Camp for ages 7 to 10: Clay Stop-Motion Play'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_stop_motion_with_clay: h2 "Sold out"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-stop-motion-with-clay/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Sold out' || t.startsWith('Sold out'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_stop_motion_with_clay: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-stop-motion-with-clay/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_stop_motion_with_clay: h2 "Additional information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-stop-motion-with-clay/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Additional information' || t.startsWith('Additional information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_stop_motion_with_clay: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-stop-motion-with-clay/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_stop_motion_with_clay: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-stop-motion-with-clay/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_stop_motion_with_clay: footer link "Become a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-stop-motion-with-clay/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_stop_motion_with_clay: footer link "Support the museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-stop-motion-with-clay/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_sustainable_prop_making', () => { test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_sustainable_prop_making: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-sustainable-prop-making/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('design camp for ages 7 to 10'); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_sustainable_prop_making: h1 "Design Camp for ages 7 to 10: "', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-sustainable-prop-making/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Camp for ages 7 to 10: Building Props from Waste' || t.startsWith('Design Camp for ages 7 to 10: Building Props from Waste'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_sustainable_prop_making: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-sustainable-prop-making/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_sustainable_prop_making: h2 "Marielle Ashworth"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-sustainable-prop-making/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Marielle Ashworth' || t.startsWith('Marielle Ashworth'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_sustainable_prop_making: h2 "Booking details for this camp"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-sustainable-prop-making/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Booking details for this camp' || t.startsWith('Booking details for this camp'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_sustainable_prop_making: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-sustainable-prop-making/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_sustainable_prop_making: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-sustainable-prop-making/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_sustainable_prop_making: footer link "Become a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-sustainable-prop-making/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_sustainable_prop_making: footer link "Support the museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-sustainable-prop-making/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_turn_plastic_into_fabric', () => { test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_turn_plastic_into_fabric: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-turn-plastic-into-fabric/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('design camp for ages 7 to 10'); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_turn_plastic_into_fabric: h1 "Design Camp for ages 7 to 10: "', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-turn-plastic-into-fabric/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Design Camp for ages 7 to 10: Making Fabric from Plastic' || t.startsWith('Design Camp for ages 7 to 10: Making Fabric from Plastic'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_turn_plastic_into_fabric: h2 "What\'s in store"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-turn-plastic-into-fabric/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What\'s in store' || t.startsWith('What\'s in store'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_turn_plastic_into_fabric: h2 "Further details here"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-turn-plastic-into-fabric/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Further details here' || t.startsWith('Further details here'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_turn_plastic_into_fabric: h2 "What past workshop guests have"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-turn-plastic-into-fabric/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What past workshop guests have said' || t.startsWith('What past workshop guests have said'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_turn_plastic_into_fabric: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-turn-plastic-into-fabric/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_turn_plastic_into_fabric: footer link "Get advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-turn-plastic-into-fabric/'); 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 === 'Get advance tickets' || t.startsWith('Get advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_turn_plastic_into_fabric: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-turn-plastic-into-fabric/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_design_camp_for_ages_7_to_10_turn_plastic_into_fabric: footer link "Support our museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/design-camp-for-ages-7-to-10-turn-plastic-into-fabric/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_exhibitions_relaxed_opening_hours', () => { test('whats_on_talks_courses_and_workshops_exhibitions_relaxed_opening_hours: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/exhibitions-relaxed-opening-hours/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('exhibitions relaxed opening hours'); }); test('whats_on_talks_courses_and_workshops_exhibitions_relaxed_opening_hours: h1 "Relaxed Opening Hours at Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/exhibitions-relaxed-opening-hours/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Relaxed Opening Hours at Formora' || t.startsWith('Relaxed Opening Hours at Formora'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_exhibitions_relaxed_opening_hours: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/exhibitions-relaxed-opening-hours/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_exhibitions_relaxed_opening_hours: h2 "LUMA: A Life Among Objects Rel"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/exhibitions-relaxed-opening-hours/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'LUMA: A Life Among Objects Relaxed Opening' || t.startsWith('LUMA: A Life Among Objects Relaxed Opening'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_exhibitions_relaxed_opening_hours: h2 "Vera Lindqvist - Relaxed Openi"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/exhibitions-relaxed-opening-hours/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Vera Lindqvist - Relaxed Opening' || t.startsWith('Vera Lindqvist - Relaxed Opening'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_exhibitions_relaxed_opening_hours: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/exhibitions-relaxed-opening-hours/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_exhibitions_relaxed_opening_hours: footer link "Book tickets ahead"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/exhibitions-relaxed-opening-hours/'); 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 === 'Book tickets ahead' || t.startsWith('Book tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_exhibitions_relaxed_opening_hours: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/exhibitions-relaxed-opening-hours/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_exhibitions_relaxed_opening_hours: footer link "Support our mission"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/exhibitions-relaxed-opening-hours/'); 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 === 'Support our mission' || t.startsWith('Support our mission')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_summer_garden_salon', () => { test('whats_on_talks_courses_and_workshops_summer_garden_salon: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/summer-garden-salon/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('summer courtyard gathering'); }); test('whats_on_talks_courses_and_workshops_summer_garden_salon: h1 "Summer Courtyard"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/summer-garden-salon/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Summer Courtyard' || t.startsWith('Summer Courtyard'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_summer_garden_salon: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/summer-garden-salon/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_summer_garden_salon: h2 "Wren Halloway"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/summer-garden-salon/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Wren Halloway' || t.startsWith('Wren Halloway'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_summer_garden_salon: h2 "Isolde Marchetti"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/summer-garden-salon/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Isolde Marchetti' || t.startsWith('Isolde Marchetti'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_summer_garden_salon: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/summer-garden-salon/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_summer_garden_salon: footer link "Buy tickets in advance"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/summer-garden-salon/'); 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 === 'Buy tickets in advance' || t.startsWith('Buy tickets in advance')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_summer_garden_salon: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/summer-garden-salon/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_summer_garden_salon: footer link "Support our work"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/summer-garden-salon/'); 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 === 'Support our work' || t.startsWith('Support our work')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_talk_design_practice_and_motherhood', () => { test('whats_on_talks_courses_and_workshops_talk_design_practice_and_motherhood: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/talk-design-practice-and-motherhood/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('talk'); }); test('whats_on_talks_courses_and_workshops_talk_design_practice_and_motherhood: h1 "Talk: Design Practice and Moth"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/talk-design-practice-and-motherhood/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Talk: Design Practice and Motherhood' || t.startsWith('Talk: Design Practice and Motherhood'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_talk_design_practice_and_motherhood: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/talk-design-practice-and-motherhood/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_talk_design_practice_and_motherhood: h2 "Petra Lindqvist"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/talk-design-practice-and-motherhood/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Petra Lindqvist' || t.startsWith('Petra Lindqvist'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_talk_design_practice_and_motherhood: h2 "Marisol Vance"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/talk-design-practice-and-motherhood/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Marisol Vance' || t.startsWith('Marisol Vance'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_talk_design_practice_and_motherhood: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/talk-design-practice-and-motherhood/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_talk_design_practice_and_motherhood: footer link "Buy tickets ahead"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/talk-design-practice-and-motherhood/'); 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 === 'Buy tickets ahead' || t.startsWith('Buy tickets ahead')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_talk_design_practice_and_motherhood: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/talk-design-practice-and-motherhood/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_talk_design_practice_and_motherhood: footer link "Support our museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/talk-design-practice-and-motherhood/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_workshop_feature_film_storyboarding_with_jay_clarke', () => { test('whats_on_talks_courses_and_workshops_workshop_feature_film_storyboarding_with_jay_clarke: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-feature-film-storyboarding-with-jay-clarke/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('workshop'); }); test('whats_on_talks_courses_and_workshops_workshop_feature_film_storyboarding_with_jay_clarke: h1 "Workshop: Feature Film Storybo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-feature-film-storyboarding-with-jay-clarke/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Workshop: Feature Film Storyboarding with Ivo Renn' || t.startsWith('Workshop: Feature Film Storyboarding with Ivo Renn'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_feature_film_storyboarding_with_jay_clarke: h2 "Sold out"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-feature-film-storyboarding-with-jay-clarke/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Sold out' || t.startsWith('Sold out'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_feature_film_storyboarding_with_jay_clarke: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-feature-film-storyboarding-with-jay-clarke/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_feature_film_storyboarding_with_jay_clarke: h2 "Ivo Renn"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-feature-film-storyboarding-with-jay-clarke/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Ivo Renn' || t.startsWith('Ivo Renn'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_feature_film_storyboarding_with_jay_clarke: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-feature-film-storyboarding-with-jay-clarke/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_feature_film_storyboarding_with_jay_clarke: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-feature-film-storyboarding-with-jay-clarke/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_feature_film_storyboarding_with_jay_clarke: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-feature-film-storyboarding-with-jay-clarke/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_feature_film_storyboarding_with_jay_clarke: footer link "Support our museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-feature-film-storyboarding-with-jay-clarke/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_workshop_introduction_to_woodwork', () => { test('whats_on_talks_courses_and_workshops_workshop_introduction_to_woodwork: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-introduction-to-woodwork/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('workshop'); }); test('whats_on_talks_courses_and_workshops_workshop_introduction_to_woodwork: h1 "Workshop: Beginning Woodcraft "', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-introduction-to-woodwork/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Workshop: Beginning Woodcraft Basics' || t.startsWith('Workshop: Beginning Woodcraft Basics'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_introduction_to_woodwork: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-introduction-to-woodwork/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_introduction_to_woodwork: h2 "Additional information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-introduction-to-woodwork/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Additional information' || t.startsWith('Additional information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_introduction_to_woodwork: h2 "Nolan Rhys"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-introduction-to-woodwork/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Nolan Rhys' || t.startsWith('Nolan Rhys'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_introduction_to_woodwork: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-introduction-to-woodwork/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_introduction_to_woodwork: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-introduction-to-woodwork/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_introduction_to_woodwork: footer link "Become a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-introduction-to-woodwork/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_introduction_to_woodwork: footer link "Support the museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-introduction-to-woodwork/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_workshop_natural_dyes', () => { test('whats_on_talks_courses_and_workshops_workshop_natural_dyes: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-natural-dyes/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('workshop'); }); test('whats_on_talks_courses_and_workshops_workshop_natural_dyes: h1 "Workshop: Natural Dyes"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-natural-dyes/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Workshop: Natural Dyes' || t.startsWith('Workshop: Natural Dyes'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_natural_dyes: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-natural-dyes/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_natural_dyes: h2 "Additional information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-natural-dyes/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Additional information' || t.startsWith('Additional information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_natural_dyes: h2 "Testimonials"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-natural-dyes/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Testimonials' || t.startsWith('Testimonials'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_natural_dyes: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-natural-dyes/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_natural_dyes: footer link "Get advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-natural-dyes/'); 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 === 'Get advance tickets' || t.startsWith('Get advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_natural_dyes: footer link "Join as a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-natural-dyes/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_natural_dyes: footer link "Support our museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-natural-dyes/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - whats_on_talks_courses_and_workshops_workshop_the_workwear_jacket', () => { test('whats_on_talks_courses_and_workshops_workshop_the_workwear_jacket: title matches GT', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-the-workwear-jacket/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('workshop'); }); test('whats_on_talks_courses_and_workshops_workshop_the_workwear_jacket: h1 "Workshop: The Utility Jacket"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-the-workwear-jacket/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Workshop: The Utility Jacket' || t.startsWith('Workshop: The Utility Jacket'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_the_workwear_jacket: h2 "What to expect"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-the-workwear-jacket/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'What to expect' || t.startsWith('What to expect'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_the_workwear_jacket: h2 "Additional information"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-the-workwear-jacket/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Additional information' || t.startsWith('Additional information'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_the_workwear_jacket: h2 "Testimonials"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-the-workwear-jacket/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Testimonials' || t.startsWith('Testimonials'))).toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_the_workwear_jacket: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-the-workwear-jacket/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_the_workwear_jacket: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-the-workwear-jacket/'); 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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_the_workwear_jacket: footer link "Become a member"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-the-workwear-jacket/'); 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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('whats_on_talks_courses_and_workshops_workshop_the_workwear_jacket: footer link "Support the museum"', async ({ page }) => { await page.goto('/whats-on/talks-courses-and-workshops/workshop-the-workwear-jacket/'); 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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - your_membership_archive_your_membership_events_archive_exclusive_events_for_members', () => { test('your_membership_archive_your_membership_events_archive_exclusive_events_for_members: title matches GT', async ({ page }) => { await page.goto('/your-membership-archive/your-membership-events-archive/exclusive-events-for-members/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('exclusive member events'); }); test('your_membership_archive_your_membership_events_archive_exclusive_events_for_members: h1 "Special events for our members"', async ({ page }) => { await page.goto('/your-membership-archive/your-membership-events-archive/exclusive-events-for-members/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Special events for our members' || t.startsWith('Special events for our members'))).toBeTruthy(); }); test('your_membership_archive_your_membership_events_archive_exclusive_events_for_members: h2 "Upcoming events"', async ({ page }) => { await page.goto('/your-membership-archive/your-membership-events-archive/exclusive-events-for-members/'); 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('your_membership_archive_your_membership_events_archive_exclusive_events_for_members: h2 "Members\' Tour of Kestrel: Thre"', async ({ page }) => { await page.goto('/your-membership-archive/your-membership-events-archive/exclusive-events-for-members/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Members\' Tour of Kestrel: Threads of Home' || t.startsWith('Members\' Tour of Kestrel: Threads of Home'))).toBeTruthy(); }); test('your_membership_archive_your_membership_events_archive_exclusive_events_for_members: h2 "Future programme"', async ({ page }) => { await page.goto('/your-membership-archive/your-membership-events-archive/exclusive-events-for-members/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Future programme' || t.startsWith('Future programme'))).toBeTruthy(); }); test('your_membership_archive_your_membership_events_archive_exclusive_events_for_members: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/your-membership-archive/your-membership-events-archive/exclusive-events-for-members/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('your_membership_archive_your_membership_events_archive_exclusive_events_for_members: footer link "Reserve your tickets"', async ({ page }) => { await page.goto('/your-membership-archive/your-membership-events-archive/exclusive-events-for-members/'); 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 === 'Reserve your tickets' || t.startsWith('Reserve your tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('your_membership_archive_your_membership_events_archive_exclusive_events_for_members: footer link "Join as a member"', async ({ page }) => { await page.goto('/your-membership-archive/your-membership-events-archive/exclusive-events-for-members/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('your_membership_archive_your_membership_events_archive_exclusive_events_for_members: footer link "Support our museum"', async ({ page }) => { await page.goto('/your-membership-archive/your-membership-events-archive/exclusive-events-for-members/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - designers_designers_in_residence_designers_in_residence_2020_care', () => { test('designers_designers_in_residence_designers_in_residence_2020_care: title matches GT', async ({ page }) => { await page.goto('/designers/designers-in-residence/designers-in-residence-2020-care/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('residents in practice 2020'); }); test('designers_designers_in_residence_designers_in_residence_2020_care: h1 "Residents in Practice 2020: Re"', async ({ page }) => { await page.goto('/designers/designers-in-residence/designers-in-residence-2020-care/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Residents in Practice 2020: Repair' || t.startsWith('Residents in Practice 2020: Repair'))).toBeTruthy(); }); test('designers_designers_in_residence_designers_in_residence_2020_care: h2 "Theme: Repair"', async ({ page }) => { await page.goto('/designers/designers-in-residence/designers-in-residence-2020-care/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Theme: Repair' || t.startsWith('Theme: Repair'))).toBeTruthy(); }); test('designers_designers_in_residence_designers_in_residence_2020_care: h2 "Amara Delgado"', async ({ page }) => { await page.goto('/designers/designers-in-residence/designers-in-residence-2020-care/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Amara Delgado' || t.startsWith('Amara Delgado'))).toBeTruthy(); }); test('designers_designers_in_residence_designers_in_residence_2020_care: h2 "Rosalind Achterberg"', async ({ page }) => { await page.goto('/designers/designers-in-residence/designers-in-residence-2020-care/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Rosalind Achterberg' || t.startsWith('Rosalind Achterberg'))).toBeTruthy(); }); test('designers_designers_in_residence_designers_in_residence_2020_care: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/designers/designers-in-residence/designers-in-residence-2020-care/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('designers_designers_in_residence_designers_in_residence_2020_care: footer link "Book advance tickets"', async ({ page }) => { await page.goto('/designers/designers-in-residence/designers-in-residence-2020-care/'); 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 === 'Book advance tickets' || t.startsWith('Book advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('designers_designers_in_residence_designers_in_residence_2020_care: footer link "Join as a member"', async ({ page }) => { await page.goto('/designers/designers-in-residence/designers-in-residence-2020-care/'); 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 === 'Join as a member' || t.startsWith('Join as a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('designers_designers_in_residence_designers_in_residence_2020_care: footer link "Support our museum"', async ({ page }) => { await page.goto('/designers/designers-in-residence/designers-in-residence-2020-care/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_touring_exhibitions_exhibitions_for_hire', () => { test('exhibitions_touring_exhibitions_exhibitions_for_hire: title matches GT', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/exhibitions-for-hire/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('exhibitions for hire'); }); test('exhibitions_touring_exhibitions_exhibitions_for_hire: h1 "Exhibitions for Hire"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/exhibitions-for-hire/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Exhibitions for Hire' || t.startsWith('Exhibitions for Hire'))).toBeTruthy(); }); test('exhibitions_touring_exhibitions_exhibitions_for_hire: h2 "Touring Programme Overview"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/exhibitions-for-hire/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Touring Programme Overview' || t.startsWith('Touring Programme Overview'))).toBeTruthy(); }); test('exhibitions_touring_exhibitions_exhibitions_for_hire: h2 "Kairo: Threads of the City"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/exhibitions-for-hire/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Kairo: Threads of the City' || t.startsWith('Kairo: Threads of the City'))).toBeTruthy(); }); test('exhibitions_touring_exhibitions_exhibitions_for_hire: h2 "The New Craft Movement"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/exhibitions-for-hire/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The New Craft Movement' || t.startsWith('The New Craft Movement'))).toBeTruthy(); }); test('exhibitions_touring_exhibitions_exhibitions_for_hire: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/exhibitions-for-hire/'); 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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_touring_exhibitions_exhibitions_for_hire: footer link "Buy tickets online"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/exhibitions-for-hire/'); 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 === 'Buy tickets online' || t.startsWith('Buy tickets online')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_touring_exhibitions_exhibitions_for_hire: footer link "Become a patron"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/exhibitions-for-hire/'); 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 === 'Become a patron' || t.startsWith('Become a patron')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_touring_exhibitions_exhibitions_for_hire: footer link "Support our museum"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/exhibitions-for-hire/'); 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 === 'Support our museum' || t.startsWith('Support our museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - exhibitions_touring_exhibitions_see_a_touring_exhibition', () => { test('exhibitions_touring_exhibitions_see_a_touring_exhibition: title matches GT', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/see-a-touring-exhibition/'); const t = (await page.title()).toLowerCase(); expect(t).toContain('see a touring exhibition'); }); test('exhibitions_touring_exhibitions_see_a_touring_exhibition: h1 "See a Touring Exhibition"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/see-a-touring-exhibition/'); const texts = (await page.locator('h1').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'See a Touring Exhibition' || t.startsWith('See a Touring Exhibition'))).toBeTruthy(); }); test('exhibitions_touring_exhibitions_see_a_touring_exhibition: h2 "Sneaker Culture: Studio to Sid"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/see-a-touring-exhibition/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Sneaker Culture: Studio to Sidewalk' || t.startsWith('Sneaker Culture: Studio to Sidewalk'))).toBeTruthy(); }); test('exhibitions_touring_exhibitions_see_a_touring_exhibition: h2 "Beyond the Human"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/see-a-touring-exhibition/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'Beyond the Human' || t.startsWith('Beyond the Human'))).toBeTruthy(); }); test('exhibitions_touring_exhibitions_see_a_touring_exhibition: h2 "The Modern Drape"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/see-a-touring-exhibition/'); const texts = (await page.locator('h2').allTextContents()).map(s => s.replace(/\s+/g, ' ').trim()); expect(texts.some(t => t === 'The Modern Drape' || t.startsWith('The Modern Drape'))).toBeTruthy(); }); test('exhibitions_touring_exhibitions_see_a_touring_exhibition: header link "Formora LogoFormora Logo.Formo"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/see-a-touring-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 === 'Formora LogoFormora Logo.Formora' || t.startsWith('Formora LogoFormora Logo.Formora')), 'link text in header').toBeTruthy(); }); test('exhibitions_touring_exhibitions_see_a_touring_exhibition: footer link "Buy advance tickets"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/see-a-touring-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 === 'Buy advance tickets' || t.startsWith('Buy advance tickets')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('whats-on')), 'href fragment present').toBeTruthy(); }); test('exhibitions_touring_exhibitions_see_a_touring_exhibition: footer link "Become a member"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/see-a-touring-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 === 'Become a member' || t.startsWith('Become a member')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('membership')), 'href fragment present').toBeTruthy(); }); test('exhibitions_touring_exhibitions_see_a_touring_exhibition: footer link "Support the museum"', async ({ page }) => { await page.goto('/exhibitions/touring-exhibitions/see-a-touring-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 === 'Support the museum' || t.startsWith('Support the museum')), 'link text in footer').toBeTruthy(); const hrefs = await links.evaluateAll(els => els.map(e => (e.getAttribute('href') || '').toLowerCase())); expect(hrefs.some(h => h.includes('support-the-museum')), 'href fragment present').toBeTruthy(); }); }); test.describe('Functional - Routing', () => { test('navigate to exhibitions_wes_anderson_the_archives via "Book your tickets"', async ({ page }) => { await page.goto('/'); const link = page.locator('a[href*="wes-anderson-the-archives"]').first(); expect(await link.count(), 'nav link to exhibitions_wes_anderson_the_archives exists').toBeGreaterThan(0); await link.click(); await page.waitForTimeout(1200); expect(page.url().toLowerCase(), 'URL changed to destination').toContain('wes-anderson-the-archives'); const bodyText = (await page.evaluate(() => document.body.innerText)).replace(/\s+/g, ' '); expect(bodyText, 'destination distinctive content shown').toContain('Emil Thorne: The Archives'); }); test('navigate to exhibitions_nigo_from_japan_with_love via "Book your tickets"', async ({ page }) => { await page.goto('/'); const link = page.locator('a[href*="nigo-from-japan-with-love"]').first(); expect(await link.count(), 'nav link to exhibitions_nigo_from_japan_with_love exists').toBeGreaterThan(0); await link.click(); await page.waitForTimeout(1200); expect(page.url().toLowerCase(), 'URL changed to destination').toContain('nigo-from-japan-with-love'); const bodyText = (await page.evaluate(() => document.body.innerText)).replace(/\s+/g, ' '); expect(bodyText, 'destination distinctive content shown').toContain('LUMA: A Life Among Objects'); }); test('navigate to exhibitions_designer_maker_user via "Free Display"', async ({ page }) => { await page.goto('/'); const link = page.locator('a[href*="designer-maker-user"]').first(); expect(await link.count(), 'nav link to exhibitions_designer_maker_user exists').toBeGreaterThan(0); await link.click(); await page.waitForTimeout(1200); expect(page.url().toLowerCase(), 'URL changed to destination').toContain('designer-maker-user'); const bodyText = (await page.evaluate(() => document.body.innerText)).replace(/\s+/g, ' '); expect(bodyText, 'destination distinctive content shown').toContain('Vision Craft Life'); }); });