✅ (tests): add zoom actions to end-to-end tests for better view control
✅ (tests): update locators in chatInputOutput.spec.ts for element accuracy ✅ (tests): import dotenv and path in end-to-end tests for environment config ✅ (tests): add control-click actions in group.spec.ts for multi-select testing ✅ (tests): update text assertions in logs.spec.ts for consistency with UI changes
This commit is contained in:
parent
b0eed97964
commit
66b7189c31
6 changed files with 37 additions and 10 deletions
|
|
@ -89,6 +89,11 @@ test("search components", async ({ page }) => {
|
|||
}
|
||||
await page.getByRole("heading", { name: "Basic Prompting" }).click();
|
||||
|
||||
await page.getByTitle("fit view").click();
|
||||
await page.getByTitle("zoom out").click();
|
||||
await page.getByTitle("zoom out").click();
|
||||
await page.getByTitle("zoom out").click();
|
||||
|
||||
await page.getByText("Chat Input").first().click();
|
||||
await page.getByTestId("more-options-modal").click();
|
||||
|
||||
|
|
@ -152,6 +157,11 @@ test("user should be able to download a flow or a component", async ({
|
|||
}
|
||||
|
||||
await page.getByRole("heading", { name: "Basic Prompting" }).click();
|
||||
await page.getByTitle("fit view").click();
|
||||
await page.getByTitle("zoom out").click();
|
||||
await page.getByTitle("zoom out").click();
|
||||
await page.getByTitle("zoom out").click();
|
||||
|
||||
await page.getByText("Chat Input", { exact: true }).click();
|
||||
await page.getByTestId("more-options-modal").click();
|
||||
|
||||
|
|
@ -224,6 +234,12 @@ test("user should be able to duplicate a flow or a component", async ({
|
|||
}
|
||||
|
||||
await page.getByRole("heading", { name: "Basic Prompting" }).click();
|
||||
|
||||
await page.getByTitle("fit view").click();
|
||||
await page.getByTitle("zoom out").click();
|
||||
await page.getByTitle("zoom out").click();
|
||||
await page.getByTitle("zoom out").click();
|
||||
|
||||
await page.getByText("Chat Input", { exact: true }).click();
|
||||
await page.getByTestId("more-options-modal").click();
|
||||
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ test("chat_io_teste", async ({ page }) => {
|
|||
// Click and hold on the first element
|
||||
await page
|
||||
.locator(
|
||||
'//*[@id="react-flow-id"]/div/div[1]/div[1]/div/div[2]/div[2]/div/div[2]/div[10]/button/div/div'
|
||||
'//*[@id="react-flow-id"]/div/div[1]/div[1]/div/div[2]/div[2]/div/div[2]/div[8]/button/div/div'
|
||||
)
|
||||
.hover();
|
||||
await page.mouse.down();
|
||||
|
|
@ -70,7 +70,7 @@ test("chat_io_teste", async ({ page }) => {
|
|||
// Move to the second element
|
||||
await page
|
||||
.locator(
|
||||
'//*[@id="react-flow-id"]/div/div[1]/div[1]/div/div[2]/div[1]/div/div[2]/div[4]/div/button/div/div'
|
||||
'//*[@id="react-flow-id"]/div/div[1]/div[1]/div/div[2]/div[1]/div/div[2]/div[3]/div/button/div/div'
|
||||
)
|
||||
.hover();
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,7 @@
|
|||
import { expect, test } from "@playwright/test";
|
||||
import * as dotenv from "dotenv";
|
||||
import { readFileSync } from "fs";
|
||||
import path from "path";
|
||||
|
||||
test("user must interact with chat with Input/Output", async ({ page }) => {
|
||||
if (!process.env.CI) {
|
||||
|
|
|
|||
|
|
@ -1,4 +1,6 @@
|
|||
import { expect, test } from "@playwright/test";
|
||||
import * as dotenv from "dotenv";
|
||||
import path from "path";
|
||||
|
||||
test("should interact with api request", async ({ page }) => {
|
||||
await page.goto("/");
|
||||
|
|
|
|||
|
|
@ -26,6 +26,10 @@ test.describe("group node test", () => {
|
|||
.click();
|
||||
await page.waitForTimeout(2000);
|
||||
await page.getByLabel("fit view").first().click();
|
||||
|
||||
await page.getByTestId("title-OpenAI").click();
|
||||
await page.getByTestId("title-OpenAI").click({ modifiers: ["Control"] });
|
||||
await page.getByTestId("title-Prompt").click({ modifiers: ["Control"] });
|
||||
await page.getByTestId("title-OpenAI").click({ modifiers: ["Control"] });
|
||||
|
||||
await page.getByRole("button", { name: "Group" }).click();
|
||||
|
|
|
|||
|
|
@ -50,13 +50,16 @@ test("should able to see and interact with logs", async ({ page }) => {
|
|||
await page.getByRole("gridcell").first().isVisible();
|
||||
|
||||
await page.getByText("Messages", { exact: true }).click();
|
||||
await page.getByText("Index").isVisible();
|
||||
await page.getByText("Timestamp").isVisible();
|
||||
await page.getByText("Flow Id", { exact: true }).isVisible();
|
||||
await page.getByText("Source").isVisible();
|
||||
await page.getByText("Target", { exact: true }).isVisible();
|
||||
await page.getByText("Target Args", { exact: true }).isVisible();
|
||||
await page.getByText("Status", { exact: true }).isVisible();
|
||||
await page.getByText("Error", { exact: true }).isVisible();
|
||||
await page.getByText("index", { exact: true }).last().isVisible();
|
||||
await page.getByText("timestamp", { exact: true }).isVisible();
|
||||
await page.getByText("flow_id", { exact: true }).isVisible();
|
||||
await page.getByText("source", { exact: true }).isVisible();
|
||||
await page.getByText("target", { exact: true }).isVisible();
|
||||
await page.getByText("vertex_id", { exact: true }).isVisible();
|
||||
await page.getByText("status", { exact: true }).isVisible();
|
||||
await page.getByText("error", { exact: true }).isVisible();
|
||||
await page.getByText("outputs", { exact: true }).isVisible();
|
||||
await page.getByText("inputs", { exact: true }).isVisible();
|
||||
|
||||
await page.getByRole("gridcell").first().isVisible();
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue