darabos commited on
Commit
9e84b13
·
1 Parent(s): 289f6da

Fix missing box ID. Use keyboard in test instead of click.

Browse files
lynxkite-app/web/src/workspace/Workspace.tsx CHANGED
@@ -243,7 +243,7 @@ function LynxKiteFlow() {
243
  state: { workspace: Workspace },
244
  nodes: Node[],
245
  ) {
246
- const title = node.title;
247
  let i = 1;
248
  node.id = `${title} ${i}`;
249
  const wnodes = state.workspace.nodes!;
 
243
  state: { workspace: Workspace },
244
  nodes: Node[],
245
  ) {
246
+ const title = node.data.title;
247
  let i = 1;
248
  node.id = `${title} ${i}`;
249
  const wnodes = state.workspace.nodes!;
lynxkite-app/web/tests/lynxkite.ts CHANGED
@@ -62,7 +62,6 @@ export class Workspace {
62
  await new Promise((resolve) => setTimeout(resolve, 200));
63
  }
64
 
65
- // Some x,y offset, otherwise the box handle may fall outside the viewport.
66
  await this.page.locator(".ws-name").click();
67
  await this.page.keyboard.press("/");
68
  await this.page
@@ -73,7 +72,8 @@ export class Workspace {
73
  }
74
 
75
  async getCatalog() {
76
- await this.page.locator(".react-flow__pane").click();
 
77
  const catalog = await this.page
78
  .locator(".node-search .matches .search-result")
79
  .allInnerTexts();
 
62
  await new Promise((resolve) => setTimeout(resolve, 200));
63
  }
64
 
 
65
  await this.page.locator(".ws-name").click();
66
  await this.page.keyboard.press("/");
67
  await this.page
 
72
  }
73
 
74
  async getCatalog() {
75
+ await this.page.locator(".ws-name").click();
76
+ await this.page.keyboard.press("/");
77
  const catalog = await this.page
78
  .locator(".node-search .matches .search-result")
79
  .allInnerTexts();