refactor: type improvements that doesn't modify functionality (#17970)
This commit is contained in:
@@ -7,10 +7,10 @@ describe('loop', () => {
|
||||
const [startNode, loopNode, ...loops] = list
|
||||
const result = format(list as any, noop)
|
||||
test('result should have no nodes in loop node', () => {
|
||||
expect((result as any).find((item: any) => !!item.execution_metadata?.loop_id)).toBeUndefined()
|
||||
expect(result.find(item => !!item.execution_metadata?.loop_id)).toBeUndefined()
|
||||
})
|
||||
test('loop should put nodes in details', () => {
|
||||
expect(result as any).toEqual([
|
||||
expect(result).toEqual([
|
||||
startNode,
|
||||
{
|
||||
...loopNode,
|
||||
|
@@ -7,7 +7,7 @@ describe('retry', () => {
|
||||
const [startNode, retryNode, ...retryDetail] = steps
|
||||
const result = format(steps as any)
|
||||
test('should have no retry status nodes', () => {
|
||||
expect(result.find(item => (item as any).status === 'retry')).toBeUndefined()
|
||||
expect(result.find(item => item.status === 'retry')).toBeUndefined()
|
||||
})
|
||||
test('should put retry nodes in retryDetail', () => {
|
||||
expect(result).toEqual([
|
||||
|
Reference in New Issue
Block a user