import { test, expect } from '@playwright/test';
import { login } from './helpers/auth';

test.describe('供應商管理模組', () => {
    test.beforeEach(async ({ page }) => {
        await login(page);
    });

    test('應能進入供應商列表頁面並顯示主要元素', async ({ page }) => {
        await page.goto('/vendors');
        await expect(page.getByRole('heading', { name: /廠商資料管理/ })).toBeVisible();
        await expect(page.locator('table')).toBeVisible();
        await expect(page.getByRole('button', { name: /新增/ })).toBeVisible();
    });
});
