@@ -8,7 +8,7 @@ const LOG_OUTPUTS = false;
88
99// Generate a workflow with a fixed UUID seed
1010// Pass test context to log the result
11- const gen = ( src : string , t ?: ExecutionContext < unknown > , options = { } ) => {
11+ const gen = ( src : string , t ?: ExecutionContext < unknown > , options = { } ) : any => {
1212 const result = generateWorkflow ( src , {
1313 uuidSeed : 1 ,
1414 printErrors : false ,
@@ -444,15 +444,15 @@ test('it should generate a webhook trigger', (t) => {
444444
445445test ( 'it should generate a node with a prop' , ( t ) => {
446446 const result = gen ( 'a(expression=y)-b' , t ) ;
447- const expected = _ . cloneDeep ( fixtures . ab ) ;
447+ const expected : any = _ . cloneDeep ( fixtures . ab ) ;
448448 expected . steps [ 0 ] . expression = 'y' ;
449449
450450 t . deepEqual ( result , expected ) ;
451451} ) ;
452452
453453test ( 'it should generate a node with a prop with an underscore' , ( t ) => {
454454 const result = gen ( 'a(project_credential_id=y)-b' , t ) ;
455- const expected = _ . cloneDeep ( fixtures . ab ) ;
455+ const expected : any = _ . cloneDeep ( fixtures . ab ) ;
456456 expected . steps [ 0 ] . openfn = {
457457 uuid : 1 ,
458458 project_credential_id : 'y' ,
@@ -486,7 +486,7 @@ test('it should save unexpected props to .openfn', (t) => {
486486
487487test ( 'it should generate a node with two props' , ( t ) => {
488488 const result = gen ( 'a(adaptor=j,expression=k)-b' , t ) ;
489- const expected = _ . cloneDeep ( fixtures . ab ) ;
489+ const expected : any = _ . cloneDeep ( fixtures . ab ) ;
490490 expected . steps [ 0 ] . adaptor = 'j' ;
491491 expected . steps [ 0 ] . expression = 'k' ;
492492
@@ -623,40 +623,12 @@ a-b #zz
623623} ) ;
624624
625625test ( 'it should generate a project with seeded uuids' , ( t ) => {
626- const result = generateProject ( 'x' , [ 'a-b' ] , {
626+ const result : any = generateProject ( 'x' , [ 'a-b' ] , {
627627 openfnUuid : true ,
628628 uuidSeed : 1000 ,
629629 uuid : 123 ,
630630 } ) ;
631631
632- const expected = {
633- id : 'workflow' ,
634- name : 'Workflow' ,
635- history : [ ] ,
636- steps : [
637- {
638- id : 'a' ,
639- name : 'a' ,
640- openfn : {
641- uuid : 'A' ,
642- } ,
643- next : {
644- b : {
645- openfn : {
646- uuid : 'AB' ,
647- } ,
648- } ,
649- } ,
650- } ,
651- {
652- id : 'b' ,
653- name : 'b' ,
654- openfn : {
655- uuid : 'B' ,
656- } ,
657- } ,
658- ] ,
659- } ;
660632 t . deepEqual ( result . openfn , {
661633 uuid : 123 ,
662634 } ) ;
@@ -710,6 +682,7 @@ test('it should generate a simple workflow with mapped uuids', (t) => {
710682test ( 'it should generate a project with mapped uuids' , ( t ) => {
711683 const result = generateProject ( 'x' , [ 'a-b' ] , {
712684 openfnUuid : true ,
685+ // @ts -ignore
713686 uuidMap : [
714687 {
715688 a : 'A' ,
0 commit comments