This repository has no description
0

Configure Feed

Select the types of activity you want to include in your feed.

semble / src / webapp / e2e / landing-page.spec.ts
1.4 kB 39 lines
1import { test, expect } from '@playwright/test'; 2 3test.describe('Landing page', () => { 4 test.beforeEach(async ({ page }) => { 5 await page.goto('/'); 6 }); 7 8 test('renders hero section with title and subtitle', async ({ page }) => { 9 const heading = page.getByRole('heading', { level: 1 }); 10 await expect(heading).toBeVisible(); 11 await expect(heading).toContainText('A social knowledge network for'); 12 }); 13 14 test('shows sign up and log in buttons for unauthenticated users', async ({ 15 page, 16 }) => { 17 const signUp = page.getByRole('link', { name: 'Sign up' }); 18 const logIn = page.getByRole('link', { name: 'Log in' }); 19 20 await expect(signUp).toBeVisible(); 21 await expect(logIn).toBeVisible(); 22 23 await expect(signUp).toHaveAttribute('href', '/signup'); 24 await expect(logIn).toHaveAttribute('href', '/login'); 25 }); 26 27 test('renders community highlights section', async ({ page }) => { 28 await expect(page.getByText('Highlights from our community')).toBeVisible(); 29 30 await expect(page.getByRole('link', { name: 'Explore' })).toBeVisible(); 31 }); 32 33 test('renders footer with social and doc links', async ({ page }) => { 34 await expect( 35 page.getByRole('link', { name: 'Follow our blog' }), 36 ).toBeVisible(); 37 await expect(page.getByRole('link', { name: 'Semble Docs' })).toBeVisible(); 38 }); 39});