Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.
TypeScript automationchromechromiume2e-testingelectronend-to-end-testingfirefoxjavascriptplaywrighttesttest-automationtestingtesting-toolswebwebkit
chore(html): render step waterfall beside duration text (#42427)
Pavel Feldman022e90fb21e2
diff --git a/packages/html-reporter/src/testResultView.css b/packages/html-reporter/src/testResultView.cssindex fd1fb525b7..517ca805a0 100644--- a/packages/html-reporter/src/testResultView.css+++ b/packages/html-reporter/src/testResultView.css@@ -103,12 +103,16 @@flex: none;white-space: nowrap;margin-left: 4px;+ min-width: 48px;+ text-align: right;+}++.step-waterfall {+ flex: none;position: relative;width: 80px;height: 20px;- line-height: 20px;- text-align: right;- padding: 0 4px;+ margin-left: 4px;border-radius: 4px;background-color: var(--color-canvas-subtle);overflow: hidden;@@ -122,10 +126,6 @@background-color: var(--color-severe-muted);}-.step-duration-text {- position: relative;-}-:root.light-mode {.test-result-counter {background: var(--color-scale-gray-5);diff --git a/packages/html-reporter/src/testResultView.tsx b/packages/html-reporter/src/testResultView.tsxindex 867ac1d41d..cf1f8e5f27 100644--- a/packages/html-reporter/src/testResultView.tsx+++ b/packages/html-reporter/src/testResultView.tsx@@ -296,10 +296,10 @@ const StepTreeItem: React.FC<{aria-label='contains attachment'>{icons.indirectAttachment()}</span>}- <span className='step-duration'>+ <span className='step-waterfall'><span className='step-waterfall-block' style={waterfallBlockStyle(step, waterfall)}></span>- <span className='step-duration-text'>{msToString(step.duration)}</span></span>+ <span className='step-duration'>{msToString(step.duration)}</span></div>} loadChildren={step.steps.length || step.snippet ? () => {const snippet = step.snippet ? [<CodeSnippet testId='test-snippet' key='line' code={step.snippet} />] : [];const steps = step.steps.map((s, i) => <StepTreeItem key={i} step={s} depth={depth + 1} result={result} test={test} filterText={filterText} waterfall={waterfall} />);