File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -25,6 +25,7 @@ import {
2525import { describe , expect , it , vi } from 'vitest'
2626import { DAGBuilder } from '@/executor/dag/builder'
2727import { Serializer } from '@/serializer/index'
28+ import type { BlockState } from '@/stores/workflows/workflow/types'
2829import { getToolMetadata , getToolParams } from '@/tools/metadata'
2930
3031vi . mocked ( getToolMetadata ) . mockImplementation ( toolsMetadataMock . getToolMetadata )
@@ -454,12 +455,15 @@ describe('Serializer', () => {
454455
455456 it . concurrent ( 'attributes a missing required field to the block that lacks it' , ( ) => {
456457 const serializer = new Serializer ( )
457- const waitBlockMissingRequired : any = {
458+ const waitBlockMissingRequired : BlockState = {
458459 id : 'wait-block' ,
459460 type : 'wait' ,
460461 name : 'Wait Block' ,
461462 position : { x : 0 , y : 0 } ,
462- subBlocks : { timeValue : { value : '' } , timeUnit : { value : 'seconds' } } ,
463+ subBlocks : {
464+ timeValue : { id : 'timeValue' , type : 'short-input' , value : '' } ,
465+ timeUnit : { id : 'timeUnit' , type : 'dropdown' , value : 'seconds' } ,
466+ } ,
463467 outputs : { } ,
464468 enabled : true ,
465469 }
You can’t perform that action at this time.
0 commit comments