Files
AITrader/tests/landing.test.ts
T
henry 4206b93614
Copilot Setup Steps / copilot-setup-steps (push) Failing after 17s
Add Playwright configuration and initial tests for landing page
- Created playwright.config.ts for test configuration
- Added .last-run.json to store test run status
- Implemented landing.test.ts with tests for navbar visibility and navigation
- Removed unused server proxy configuration from vite.config.ts
2026-05-12 22:10:51 +02:00

21 lines
769 B
TypeScript

import { test, expect } from "@playwright/test";
test("landing page shows navbar and account info", async ({ page }) => {
await page.goto("/");
// Check navbar is visible
await expect(page.locator("nav >> text=AITrader")).toBeVisible();
await expect(page.locator("text=Stocks")).toBeVisible();
// Check account info is displayed
await expect(page.locator("text=Trading Account")).toBeVisible();
await expect(page.locator("text=Cash")).toBeVisible();
await expect(page.locator("text=Buying Power")).toBeVisible();
await expect(page.locator("text=Portfolio Value")).toBeVisible();
});
test("navigation to stocks works", async ({ page }) => {
await page.goto("/");
await page.click("text=Stocks");
await expect(page).toHaveURL("/stocks");
});