Skip to content

Commit ddaa437

Browse files
use a tabsNotLazy prop to make input/output tabs jest work
This seems to be the simplest workaround since we do not have access to the actual, clickable tab links in this component (to be able to trigger the tab display).
1 parent 39d9880 commit ddaa437

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

client/src/components/WorkflowInvocationState/WorkflowInvocationInputOutputTabs.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,7 @@ async function mountWorkflowInvocationInputOutputTabs(invocation: WorkflowInvoca
9595
propsData: {
9696
invocation,
9797
terminal,
98+
tabsNotLazy: true,
9899
},
99100
stubs: {
100101
ContentItem: true,

client/src/components/WorkflowInvocationState/WorkflowInvocationInputOutputTabs.vue

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ const OUTPUTS_NOT_AVAILABLE_YET_MSG =
1919
const props = defineProps<{
2020
invocation: WorkflowInvocationElementView;
2121
terminal?: boolean;
22+
tabsNotLazy?: boolean;
2223
}>();
2324
2425
// Fetching full workflow to get the workflow output labels (for when invocation is not terminal)
@@ -64,13 +65,13 @@ const parameters = computed(() => Object.values(props.invocation.input_step_para
6465
</script>
6566
<template>
6667
<span>
67-
<BTab title="Inputs" lazy>
68+
<BTab title="Inputs" :lazy="!props.tabsNotLazy">
6869
<div v-if="parameters.length || inputData.length">
6970
<WorkflowInvocationInputs :invocation="props.invocation" />
7071
</div>
7172
<BAlert v-else show variant="info"> No input data was provided for this workflow invocation. </BAlert>
7273
</BTab>
73-
<BTab title="Outputs" lazy>
74+
<BTab title="Outputs" :lazy="!props.tabsNotLazy">
7475
<div v-if="outputs.length">
7576
<div
7677
v-for="([key, output], index) in outputs"

0 commit comments

Comments
 (0)