Frontend addresses flows and dashboards by id: routes /flows/$flowId, /dashboards/$id and /view/$id, query keys, saves, lists, device pickers, search, brain and endpoint links and generated results dashboards go by id, while live values, issues, pauses and message names keep the key; tabs take the title from the document; creating uses POST and opens the issued id; the flow and dashboard panels show key and id with a copy button and a served HTTP or WebSocket node shows its hook URL under the flow id; specs create by POST and ids.spec.ts exercises issued ids
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
import { expect, test } from "@playwright/test"
|
||||
import { deleteAll } from "./utils/api"
|
||||
import { deleteAll, openedFlowId } from "./utils/api"
|
||||
|
||||
const flowName = `test_clip_${Date.now().toString(36)}`
|
||||
/** Issued by the server when the first test creates it in the app. */
|
||||
let flowId = ""
|
||||
const KEY = "fluksio.nodeClipboard"
|
||||
|
||||
declare global {
|
||||
@@ -17,7 +19,7 @@ test.use({
|
||||
})
|
||||
|
||||
test.afterAll(async ({ browser }) => {
|
||||
await deleteAll(browser, [`/flows/${flowName}`])
|
||||
await deleteAll(browser, [`/flows/${flowId}`])
|
||||
})
|
||||
|
||||
test("the canvas clipboard yields to the native one", async ({ page }) => {
|
||||
@@ -25,7 +27,7 @@ test("the canvas clipboard yields to the native one", async ({ page }) => {
|
||||
await page.getByTestId("new-flow").click()
|
||||
await page.getByTestId("new-flow-name").fill(flowName)
|
||||
await page.getByTestId("create-flow").click()
|
||||
await page.waitForURL(`/flows/${flowName}`)
|
||||
flowId = await openedFlowId(page)
|
||||
|
||||
await page.getByTestId("add-node").click()
|
||||
await page
|
||||
|
||||
Reference in New Issue
Block a user