This commit is contained in:
@@ -82,6 +82,7 @@ test("model settings, text stream, contextual query, confirmation and preserved
|
||||
await page.locator(".settings-drawer .semi-sidesheet-close").click();
|
||||
await configure(page);
|
||||
await page.getByRole("button", { name: "Alpha 管理", exact: true }).click();
|
||||
await page.getByRole("button", { name: "筛选 Alpha", exact: true }).click();
|
||||
await page.getByRole("textbox", { name: "搜索 Alpha" }).fill("TEST0001");
|
||||
await page.getByRole("button", { name: "查询", exact: true }).click();
|
||||
// Global tools sit below drawers; open the assistant before the Alpha detail.
|
||||
@@ -138,9 +139,11 @@ test("model settings, text stream, contextual query, confirmation and preserved
|
||||
chat.getByText("筛选换手率不超过 15% 的 Alpha", { exact: true }),
|
||||
).toBeVisible();
|
||||
await chat.getByRole("button", { name: "应用到列表" }).click();
|
||||
await page.getByRole("button", { name: "筛选 Alpha", exact: true }).click();
|
||||
await expect(page.getByRole("textbox", { name: "搜索 Alpha" })).toHaveValue(
|
||||
"",
|
||||
);
|
||||
await page.getByRole("button", { name: "关闭筛选", exact: true }).click();
|
||||
await page.screenshot({
|
||||
path: "../output/playwright/ai-query.png",
|
||||
fullPage: true,
|
||||
|
||||
@@ -81,6 +81,7 @@ test("submission tabs, day selection, local correlation and reload", async ({
|
||||
expect(complete.processed).toBe(103);
|
||||
await expect(page.locator(".job-panel")).toContainText("2025-02-02");
|
||||
await page.keyboard.press("Escape");
|
||||
await page.getByRole("button", { name: "筛选 Alpha", exact: true }).click();
|
||||
await page.getByRole("textbox", { name: "搜索 Alpha" }).fill("TEST0003");
|
||||
await page.getByRole("button", { name: "查询", exact: true }).click();
|
||||
await expect(page.locator(".alpha-link")).toHaveCount(1);
|
||||
@@ -96,11 +97,15 @@ test("submission tabs, day selection, local correlation and reload", async ({
|
||||
await page.getByRole("tab", { name: "待提交", exact: true }).hover();
|
||||
|
||||
await page.getByRole("tab", { name: "待提交", exact: true }).click();
|
||||
await page.getByRole("button", { name: "筛选 Alpha", exact: true }).click();
|
||||
await expect(page.getByRole("textbox", { name: "搜索 Alpha" })).toHaveValue(
|
||||
"",
|
||||
);
|
||||
await page.getByRole("button", { name: "关闭筛选", exact: true }).click();
|
||||
await page.getByRole("button", { name: "按天同步", exact: true }).click();
|
||||
await expect(page.getByRole("dialog")).toContainText("创建日期");
|
||||
await expect(
|
||||
page.getByRole("dialog", { name: "按天同步待提交 Alpha" }),
|
||||
).toContainText("创建日期");
|
||||
await page.getByLabel("同步开始日期").fill("2025-01-01");
|
||||
await page.getByLabel("同步结束日期").fill("2025-01-01");
|
||||
await page.getByRole("button", { name: "开始同步", exact: true }).click();
|
||||
@@ -115,6 +120,7 @@ test("submission tabs, day selection, local correlation and reload", async ({
|
||||
)
|
||||
.toBe(413);
|
||||
await page.keyboard.press("Escape");
|
||||
await page.getByRole("button", { name: "筛选 Alpha", exact: true }).click();
|
||||
await page.getByRole("textbox", { name: "搜索 Alpha" }).fill("TEST0004");
|
||||
await page.getByRole("button", { name: "查询", exact: true }).click();
|
||||
await page.route("**/api/v1/alphas/TEST0004", async (route) => {
|
||||
@@ -147,6 +153,7 @@ test("submission tabs, day selection, local correlation and reload", async ({
|
||||
detail.is_metrics.unavailable = null;
|
||||
await route.fulfill({ response, json: detail });
|
||||
});
|
||||
await expect(page.locator(".alpha-link")).toHaveCount(1);
|
||||
await page.locator(".alpha-link").click();
|
||||
const sheet = page.locator(".alpha-detail");
|
||||
await expect(sheet.getByRole("tab")).toHaveText([
|
||||
@@ -290,6 +297,7 @@ test("submission tabs, day selection, local correlation and reload", async ({
|
||||
});
|
||||
await page.keyboard.press("Escape");
|
||||
await page.reload();
|
||||
await page.getByRole("button", { name: "筛选 Alpha", exact: true }).click();
|
||||
await page.getByRole("textbox", { name: "搜索 Alpha" }).fill("TEST0004");
|
||||
await page.getByRole("button", { name: "查询", exact: true }).click();
|
||||
await expect(page.locator(".alpha-table:visible")).toContainText(
|
||||
|
||||
@@ -100,8 +100,9 @@ test("feature conversion, saved views and immutable evaluations", async ({
|
||||
]);
|
||||
await page.keyboard.press("Escape");
|
||||
await page.getByRole("button", { name: "Alpha 管理", exact: true }).click();
|
||||
await page.getByLabel("视图名称", { exact: true }).fill("浏览器常用队列");
|
||||
await page.getByRole("button", { name: "保存为新视图" }).click();
|
||||
await page.getByLabel("视图名称", { exact: true }).fill("浏览器常用队列");
|
||||
await page.getByRole("button", { name: "保存视图", exact: true }).click();
|
||||
await expect(page.getByText("筛选视图已保存", { exact: true })).toBeVisible();
|
||||
const views = await (
|
||||
await page.request.get("/api/v1/research/assets?kind=view&q=浏览器常用队列")
|
||||
@@ -137,6 +138,7 @@ test("feature conversion, saved views and immutable evaluations", async ({
|
||||
)
|
||||
.toBe("completed");
|
||||
await page.reload();
|
||||
await page.getByRole("button", { name: "筛选 Alpha", exact: true }).click();
|
||||
await page.getByRole("textbox", { name: "搜索 Alpha" }).fill("TEST0001");
|
||||
await page.getByRole("button", { name: "查询", exact: true }).click();
|
||||
await expect(page.locator(".alpha-link")).toHaveCount(1);
|
||||
|
||||
@@ -84,11 +84,12 @@ test("account → scoped sync → research → resync → PnL → filtered expor
|
||||
await page.keyboard.press("Escape");
|
||||
await expect(page.locator(".job-panel")).not.toBeVisible();
|
||||
await page.getByRole("tab", { name: "待提交", exact: true }).click();
|
||||
await expect(page.locator(".table-toolbar .count-pill")).toHaveText("413");
|
||||
await expect(page.locator(".alpha-table-meta .count-pill")).toHaveText("413");
|
||||
await page.screenshot({
|
||||
path: "../output/playwright/alpha-library.png",
|
||||
fullPage: true,
|
||||
});
|
||||
await page.getByRole("button", { name: "筛选 Alpha", exact: true }).click();
|
||||
await page.getByRole("textbox", { name: "搜索 Alpha" }).fill("TEST0007");
|
||||
await page.getByRole("button", { name: "查询", exact: true }).click();
|
||||
await expect(page.locator(".alpha-link")).toHaveCount(1);
|
||||
@@ -141,6 +142,7 @@ test("account → scoped sync → research → resync → PnL → filtered expor
|
||||
)
|
||||
.toBe("completed");
|
||||
await page.reload();
|
||||
await page.getByRole("button", { name: "筛选 Alpha", exact: true }).click();
|
||||
await page.getByRole("textbox", { name: "搜索 Alpha" }).fill("TEST0007");
|
||||
await page.getByRole("button", { name: "查询", exact: true }).click();
|
||||
await expect(page.locator(".alpha-link")).toHaveCount(1);
|
||||
@@ -153,6 +155,7 @@ test("account → scoped sync → research → resync → PnL → filtered expor
|
||||
page.getByRole("checkbox", { name: "收藏此 Alpha" }),
|
||||
).toBeChecked();
|
||||
await page.keyboard.press("Escape");
|
||||
await page.getByRole("button", { name: "筛选 Alpha", exact: true }).click();
|
||||
await page.getByRole("button", { name: "重置", exact: true }).click();
|
||||
await expect(page.locator(".alpha-link")).toHaveCount(25);
|
||||
const downloading = page.waitForEvent("download");
|
||||
@@ -217,6 +220,7 @@ test("batch tags, column visibility, server pagination and saved preferences", a
|
||||
)
|
||||
.toBe(620);
|
||||
}
|
||||
await page.getByRole("button", { name: "筛选 Alpha", exact: true }).click();
|
||||
await page.getByRole("textbox", { name: "搜索 Alpha" }).fill("TEST006");
|
||||
await page.getByRole("button", { name: "查询", exact: true }).click();
|
||||
await expect(page.locator(".alpha-link")).toHaveCount(6);
|
||||
@@ -258,6 +262,7 @@ test("batch tags, column visibility, server pagination and saved preferences", a
|
||||
page.getByRole("columnheader", { name: "自定义标签", exact: true }),
|
||||
).toBeVisible();
|
||||
await page.getByRole("button", { name: "显示列设置" }).click();
|
||||
await page.getByRole("button", { name: "筛选 Alpha", exact: true }).click();
|
||||
await page.getByRole("button", { name: "重置", exact: true }).click();
|
||||
await expect(page.locator(".alpha-link")).toHaveCount(25);
|
||||
const firstId = await page.locator(".alpha-link").first().innerText();
|
||||
|
||||
Reference in New Issue
Block a user