From e1c9e7fb2e713ca6ff1aaa2839274706f466aa7c Mon Sep 17 00:00:00 2001 From: Laila Los <44241786+ElectronicBlueberry@users.noreply.github.com> Date: Mon, 20 Jan 2025 13:58:59 +0100 Subject: [PATCH 1/2] enable cloning --- client/src/components/Workflow/Editor/Node.vue | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/client/src/components/Workflow/Editor/Node.vue b/client/src/components/Workflow/Editor/Node.vue index 1f4085242a7..5d7aaf00166 100644 --- a/client/src/components/Workflow/Editor/Node.vue +++ b/client/src/components/Workflow/Editor/Node.vue @@ -25,7 +25,7 @@ props.step.label || props.step.name); const idString = computed(() => `wf-node-step-${props.id}`); const showRule = computed(() => props.step.inputs?.length > 0 && props.step.outputs?.length > 0); const iconClass = computed(() => `icon fa fa-fw ${WorkflowIcons[props.step.type]}`); -const canClone = computed(() => props.step.type !== "subworkflow"); // Why ? const isEnabled = getGalaxyInstance().config.enable_tool_recommendations; // getGalaxyInstance is not reactive const isActive = computed(() => props.id === props.activeNodeId); From 9d0ce932ef9099b6b08c285e84b6537adac57c11 Mon Sep 17 00:00:00 2001 From: Laila Los <44241786+ElectronicBlueberry@users.noreply.github.com> Date: Mon, 20 Jan 2025 14:55:14 +0100 Subject: [PATCH 2/2] remove test counting i elements --- client/src/components/Workflow/Editor/Node.test.ts | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/client/src/components/Workflow/Editor/Node.test.ts b/client/src/components/Workflow/Editor/Node.test.ts index 8b85f647a06..0108dc7cee5 100644 --- a/client/src/components/Workflow/Editor/Node.test.ts +++ b/client/src/components/Workflow/Editor/Node.test.ts @@ -42,18 +42,17 @@ describe("Node", () => { }, }); await flushPromises(); + // fa-wrench is the tool icon ... expect(wrapper.findAll(".fa-wrench")).toHaveLength(1); - const toolLinks = wrapper.findAll("i"); - expect(toolLinks.length).toBe(3); await wrapper.setProps({ step: { label: "step label", type: "subworkflow", inputs: [], outputs: [], position: { top: 0, left: 0 } }, }); + // fa-sitemap is the subworkflow icon ... expect(wrapper.findAll(".fa-sitemap")).toHaveLength(1); expect(wrapper.findAll(".fa-wrench")).toHaveLength(0); - const subworkflowLinks = wrapper.findAll("i"); - expect(subworkflowLinks.length).toBe(2); + const workflowTitle = wrapper.find(".node-title"); expect(workflowTitle.text()).toBe("step label"); });