1
0
mirror of https://github.com/kamranahmedse/developer-roadmap.git synced 2025-01-17 06:08:36 +01:00
developer-roadmap/tests/roadmap.spec.ts

14 lines
383 B
TypeScript
Raw Normal View History

import path from 'node:path';
import fs from 'node:fs';
import { test, expect } from '@playwright/test';
const roadmapIds = fs.readdirSync(path.join(process.cwd(), 'src/roadmaps'));
for (const roadmapId of roadmapIds) {
test(`roadmap ${roadmapId}`, async ({ page }) => {
await page.goto(`/${roadmapId}`);
await expect(page).toHaveScreenshot({ fullPage: true });
});
}