Skip to content

Commit

Permalink
perf(reporters): improve table renderer
Browse files Browse the repository at this point in the history
  • Loading branch information
AriPerkkio committed Mar 14, 2023
1 parent bfbbaef commit e56db36
Showing 1 changed file with 3 additions and 3 deletions.
Expand Up @@ -101,8 +101,8 @@ function renderBenchmark(task: Benchmark, tasks: Task[]): string {
].join(' ')
}

export function renderTree(tasks: Task[], options: ListRendererOptions, level = 0) {
let output: string[] = []
export function renderTree(tasks: Task[], options: ListRendererOptions, level = 0): string {
const output: string[] = []

let idx = 0
for (const task of tasks) {
Expand Down Expand Up @@ -154,7 +154,7 @@ export function renderTree(tasks: Task[], options: ListRendererOptions, level =

if (task.type === 'suite' && task.tasks.length > 0) {
if (task.result?.state)
output = output.concat(renderTree(task.tasks, options, level + 1))
output.push(renderTree(task.tasks, options, level + 1))
}
idx++
}
Expand Down

0 comments on commit e56db36

Please sign in to comment.