parent
e4786e0154
commit
64ed6e724c
|
|
@ -27,6 +27,7 @@ const result: TestResult = {
|
||||||
errors: [],
|
errors: [],
|
||||||
steps: [{
|
steps: [{
|
||||||
title: 'Outer step',
|
title: 'Outer step',
|
||||||
|
category: 'test.step',
|
||||||
startTime: new Date(100).toUTCString(),
|
startTime: new Date(100).toUTCString(),
|
||||||
duration: 10,
|
duration: 10,
|
||||||
location: { file: 'test.spec.ts', line: 62, column: 0 },
|
location: { file: 'test.spec.ts', line: 62, column: 0 },
|
||||||
|
|
@ -34,6 +35,7 @@ const result: TestResult = {
|
||||||
steps: [{
|
steps: [{
|
||||||
title: 'Inner step',
|
title: 'Inner step',
|
||||||
startTime: new Date(200).toUTCString(),
|
startTime: new Date(200).toUTCString(),
|
||||||
|
category: 'test.step',
|
||||||
duration: 10,
|
duration: 10,
|
||||||
location: { file: 'test.spec.ts', line: 82, column: 0 },
|
location: { file: 'test.spec.ts', line: 82, column: 0 },
|
||||||
steps: [],
|
steps: [],
|
||||||
|
|
@ -136,6 +138,7 @@ const resultWithAttachment: TestResult = {
|
||||||
errors: [],
|
errors: [],
|
||||||
steps: [{
|
steps: [{
|
||||||
title: 'Outer step',
|
title: 'Outer step',
|
||||||
|
category: 'test.step',
|
||||||
startTime: new Date(100).toUTCString(),
|
startTime: new Date(100).toUTCString(),
|
||||||
duration: 10,
|
duration: 10,
|
||||||
location: { file: 'test.spec.ts', line: 62, column: 0 },
|
location: { file: 'test.spec.ts', line: 62, column: 0 },
|
||||||
|
|
|
||||||
|
|
@ -102,6 +102,7 @@ export type TestResult = {
|
||||||
|
|
||||||
export type TestStep = {
|
export type TestStep = {
|
||||||
title: string;
|
title: string;
|
||||||
|
category: 'hook' | 'fixture' | 'test.step' | 'expect' | 'attach' | string;
|
||||||
startTime: string;
|
startTime: string;
|
||||||
duration: number;
|
duration: number;
|
||||||
location?: Location;
|
location?: Location;
|
||||||
|
|
|
||||||
|
|
@ -498,6 +498,7 @@ class HtmlBuilder {
|
||||||
const { step, duration, count } = dedupedStep;
|
const { step, duration, count } = dedupedStep;
|
||||||
const testStep: TestStep = {
|
const testStep: TestStep = {
|
||||||
title: step.title,
|
title: step.title,
|
||||||
|
category: step.category,
|
||||||
startTime: step.startTime.toISOString(),
|
startTime: step.startTime.toISOString(),
|
||||||
duration,
|
duration,
|
||||||
steps: dedupeSteps(step.steps).map(s => this._createTestStep(s, result)),
|
steps: dedupeSteps(step.steps).map(s => this._createTestStep(s, result)),
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue