Files
gitea/tests/e2e
silverwindandClaude Opus 4.6 530b86e244 Add ambient type declarations for e2e env variables
Declare E2E_USER, E2E_PASSWORD and E2E_URL as string in ProcessEnv so
non-null assertions are no longer needed throughout the e2e tests.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-18 03:03:16 +01:00
..

import {env} from 'node:process';
import {test, expect} from '@playwright/test';
import {login, createRepo, deleteRepo} from './utils.ts';

test('README renders on repository page', async ({page}) => {
  const repoName = `e2e-readme-${Date.now()}`;
  await login(page);
  await createRepo(page, repoName);
  await page.goto(`/${env.E2E_USER}/${repoName}`);
  await expect(page.locator('#readme')).toContainText(repoName);
  await deleteRepo(page, env.E2E_USER, repoName);
});